Skip to content

Fix #6177 custom ID filter input override - #9232

Merged
michaelstaib merged 6 commits into
mainfrom
mst/issue-6177
Jul 10, 2026
Merged

Fix #6177 custom ID filter input override#9232
michaelstaib merged 6 commits into
mainfrom
mst/issue-6177

Conversation

@michaelstaib

@michaelstaib michaelstaib commented Feb 25, 2026

Copy link
Copy Markdown
Member

Fixes #6177

Copilot AI review requested due to automatic review settings April 7, 2026 19:31

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

Fixes HotChocolate filtering behavior for [ID]-annotated fields so that explicitly configured custom IdOperationFilterInputType derivatives are not overwritten during type discovery, and adds a regression test for #6177.

Changes:

  • Added a regression test ensuring an explicitly configured custom ID operation filter input type is used for an [ID] field.
  • Updated FilterTypeInterceptor.ApplyIdAttributesToFields to keep explicitly configured custom ID operation filter input types instead of always forcing IdOperationFilterInputType.

Reviewed changes

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

File Description
src/HotChocolate/Data/test/Data.Filters.Tests/Issue6177ReproTests.cs Adds regression coverage for custom ID operation filter input types on [ID] fields.
src/HotChocolate/Data/src/Data/Filters/Convention/FilterTypeInterceptor.cs Adjusts ID attribute handling to respect explicitly configured custom ID filter input types.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/HotChocolate/Data/src/Data/Filters/Convention/FilterTypeInterceptor.cs Outdated
- Remove accidental self-referential graphql-platform submodule
- Add comment explaining SyntaxTypeReference limitation in
  ApplyIdAttributesToFields (SDL-only, no runtime type info)
- Convert Issue6177ReproTests to CookieCrumble snapshot style
  with .MatchSnapshot() and generated .graphql snapshot files

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

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

@michaelstaib
michaelstaib merged commit 3cab5e2 into main Jul 10, 2026
145 of 147 checks passed
@michaelstaib
michaelstaib deleted the mst/issue-6177 branch July 10, 2026 12:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Custom OperationFilterInputType for ID fields not working

2 participants