Skip to content

Fix schema filtering for parameter references - #470

Open
CompuGeniusCode wants to merge 1 commit into
Carapacik:mainfrom
ShulertInc:main
Open

Fix schema filtering for parameter references#470
CompuGeniusCode wants to merge 1 commit into
Carapacik:mainfrom
ShulertInc:main

Conversation

@CompuGeniusCode

Copy link
Copy Markdown

When include_tags or exclude_tags is configured, schemas referenced only by query, path, or header parameters are incorrectly treated as unused and omitted from generated output.

This causes generated clients to reference missing model files, for example:

Target of URI doesn't exist: '../models/unit.dart'
Undefined class 'Unit'

Changes:

  • Track $ref schemas used by OpenAPI 3 parameters before type generation.
  • Track $ref schemas used by OpenAPI 2 parameters as well.
  • Preserve parameter-referenced enums and models during tag-based schema filtering.
  • Add a regression test covering an enum referenced only by a filtered endpoint’s query parameter.

Copilot AI lite review requested due to automatic review settings August 9, 2026 03:51

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@CompuGeniusCode

Copy link
Copy Markdown
Author

Uh, I didn't ask you to review, stupid bot.

@Carapacik
Carapacik self-requested a review August 17, 2026 12:26
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.

2 participants