Fix apiVersion clientDefaultValue missing for multi-service operation groups#3887
Open
Fix apiVersion clientDefaultValue missing for multi-service operation groups#3887
Conversation
…groups When an operation group mixes operations from different services, the apiVersion parameter at the operation level should still have the correct clientDefaultValue from the operation's specific service. The fix modifies updateWithApiVersionInformation to accept an optional operation parameter. For multi-service clients/operation groups, it now determines the operation's service and retrieves the api version default from that service's versions. Co-authored-by: tadelesh <[email protected]>
Co-authored-by: tadelesh <[email protected]>
Copilot
AI
changed the title
[WIP] Fix missing clientDefaultValue for apiVersion in operation groups
Fix apiVersion clientDefaultValue missing for multi-service operation groups
Feb 4, 2026
commit: |
Collaborator
|
All changed packages have been documented.
Show changes
|
Collaborator
|
You can try these changes here
|
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.
When an operation group contains operations from different services, the
clientDefaultValueforapiVersionparameters was incorrectlyundefinedfor all operations. Each operation should get its default from its own service's api version.Changes
internal-utils.ts: AddedfindServiceForOperationhelper and modifiedupdateWithApiVersionInformationto accept an optionaloperationparametertypes.ts: Pass operation toupdateWithApiVersionInformationcall sitestructure.test.ts: Added assertions verifying operation-level api version defaults in multi-service scenariosBefore/After
Note: Client-level
apiVersionparameters for multi-service clients remainundefinedby design since there's no single default across services.Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.