Skip to content

Tighten the guardrail against serializer queries - #292

Merged
rhysyngsun merged 2 commits into
mainfrom
nl/drf-api-performance-skill-narrow-guardrails
Aug 27, 2026
Merged

Tighten the guardrail against serializer queries#292
rhysyngsun merged 2 commits into
mainfrom
nl/drf-api-performance-skill-narrow-guardrails

Conversation

@rhysyngsun

Copy link
Copy Markdown
Contributor

What are the relevant tickets?

N/A

Description (What does it do?)

This clarifies the rule about putting queries in serializers to have it be inclusive of queries made because a serializer is making a function call that does a query.

How can this be tested?

It's hard to test this because LLMs aren't deterministic, we'll just have to see if it does it less over time.

Copilot AI balanced review requested due to automatic review settings August 26, 2026 17:37

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Clarifies that serializers must avoid both direct and indirectly triggered database queries.

Changes:

  • Expands the serializer query guardrail.
  • Adds indirect function/property access guidance.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
skills/python/drf-api-performance/SKILL.md Strengthens the primary rule.
skills/python/drf-api-performance/references/serializers.md Documents indirect query risks.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread skills/python/drf-api-performance/SKILL.md Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@rhysyngsun
rhysyngsun merged commit 13b5cd9 into main Aug 27, 2026
5 checks passed
@rhysyngsun
rhysyngsun deleted the nl/drf-api-performance-skill-narrow-guardrails branch August 27, 2026 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants