fix: preserve project route model inheritance - #3029
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Why
Project settings are stored as sparse overrides. Route provider maps were replacing inherited entries atomically during resolution, so a project-only thinking override discarded the system route model. The route then fell back to the provider instance's base model, and unsupported thinking values could also be sanitized away.
With this change, provider IDs still define the narrower scope's pool, but each retained provider entry inherits its model, thinking mode, enabled state, and weight independently. Existing sparse overrides recover automatically without a database migration or re-save.
Validation
pnpm run cigit diff --check/healthand/readychecksRisk and rollback
Risk is limited to scoped route-resolution behavior. Existing tests retain the intentional provider-pool replacement semantics. Rollback is the single commit in this PR; no schema or data migration is involved.