Skip to content

Change parameter key from 'version' to 'properties.version' - #34027

Open
Mohammed AB (moabuham) wants to merge 1 commit into
Azure:devfrom
moabuham:patch-1
Open

Change parameter key from 'version' to 'properties.version'#34027
Mohammed AB (moabuham) wants to merge 1 commit into
Azure:devfrom
moabuham:patch-1

Conversation

@moabuham

@moabuham Mohammed AB (moabuham) commented Sep 3, 2026

Copy link
Copy Markdown

🤖 PR Validation — ️✔️ All clear

Breaking Changes Tests
️✔️ None ️✔️ 130/130

Passing yes to command will cause below error

az mysql flexible-server upgrade --name meru8upto --resource-group lab --version 8.4 --yes (InvalidRequestContent) The request content was invalid and could not be deserialized: 'Could not find member 'version' on object of type 'ResourceDefinition'. Path 'version', line 1, position 16.'. Code: InvalidRequestContent
Message: The request content was invalid and could not be deserialized: 'Could not find member 'version' on object of type 'ResourceDefinition'. Path 'version', line 1, position 16.'.

Related command

Description

Testing Guide

History Notes

[Component Name 1] BREAKING CHANGE: az command a: Make some customer-facing breaking change
[Component Name 2] az command b: Add some customer-facing feature


This checklist is used to make sure that common guidelines for a pull request are followed.

Passing yes to command will cause below error 

az mysql flexible-server upgrade --name meru8upto --resource-group lab --version 8.4 --yes
(InvalidRequestContent) The request content was invalid and could not be deserialized: 'Could not find member 'version' on object of type 'ResourceDefinition'. Path 'version', line 1, position 16.'.
Code: InvalidRequestContent
Message: The request content was invalid and could not be deserialized: 'Could not find member 'version' on object of type 'ResourceDefinition'. Path 'version', line 1, position 16.'.
Copilot AI lite review requested due to automatic review settings September 3, 2026 11:27
@moabuham
Mohammed AB (moabuham) requested a review from a team as a code owner September 3, 2026 11:27
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

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.

🟡 Changes recommended

The fix changes a critical request payload shape but lacks a non-live/unit test to prevent regressions since the existing upgrade scenario test is @live_only.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

Fixes the az mysql flexible-server upgrade request payload so the service can deserialize the requested version correctly, addressing the InvalidRequestContent error reported when running the command with --yes.

Changes:

  • Update the upgrade PATCH payload to send version under properties (i.e., properties.version) instead of at the request root.
File summaries
File Description
src/azure-cli/azure/cli/command_modules/mysql/custom.py Adjusts the update payload structure for flexible-server major version upgrade requests to match the service contract.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Lite

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

Comment on lines 323 to 325
parameters = {
'version': version_mapped
'properties': {'version': version_mapped}
}
@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).

@yonzhan

Copy link
Copy Markdown
Collaborator

mysql

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.

5 participants