-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Az.Advisor update generation tool version: autorest.powershell v3->v4 #28036
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| Thanks for your contribution! The pull request validation has started. Please revisit this comment for updated status. |
|
|
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
… jinpei/main/Advisor-update-v4
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
|
To the author of the pull request, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR updates the Az.Advisor module to use AutoRest PowerShell v4 instead of v3, which involves regenerating the module with the newer generation tool. The update primarily affects type signatures and parameter types while maintaining the same functionality.
Key changes:
- Updates AutoRest PowerShell generation tool from v3 to v4
- Changes parameter types from strongly-typed enums to strings (e.g.,
CpuThresholdtoString) - Updates output type signatures to use simplified namespaces
- Adds breaking change exceptions for backward compatibility
Reviewed Changes
Copilot reviewed 21 out of 21 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tools/StaticAnalysis/Exceptions/Az.Advisor/BreakingChangeIssues.csv | Adds breaking change exceptions for type changes from v3 to v4 generation |
| src/Advisor/Advisor/help/*.md | Updates help documentation to reflect new parameter and output types |
| src/Advisor/Advisor/Az.Advisor.psd1 | Updates module generation date and Az.Accounts dependency version |
| src/Advisor/Advisor.sln | Updates project GUID references for regenerated components |
| src/Advisor/Advisor.Autorest/generate-info.json | Updates generation ID for new AutoRest run |
| src/Advisor/Advisor.Autorest/docs/*.md | Updates AutoRest documentation with new type signatures |
| src/Advisor/Advisor.Autorest/custom/*.ps1 | Removes breaking change attributes and updates parameter types |
| src/Advisor/Advisor.Autorest/README.md | Removes v3-specific configuration and simplifies directive patterns |
| src/Advisor/Advisor.Autorest/Properties/AssemblyInfo.cs | Removes trailing whitespace |
src/Advisor/Advisor/Az.Advisor.psd1
Outdated
| # Generated by: Microsoft Corporation | ||
| # | ||
| # Generated on: 2025-07-27 | ||
| # Generated on: 2025-06-27 |
Copilot
AI
Aug 22, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The generation date has moved backward from 2025-07-27 to 2025-06-27, which suggests an incorrect timestamp. Generation dates should typically move forward when modules are regenerated.
| # Generated on: 2025-06-27 | |
| # Generated on: 2025-07-28 |
| # 2. For New-* cmdlets, ViaIdentity is not required, so CreateViaIdentityExpanded is removed as well | ||
| - where: | ||
| variant: ^Create$|^CreateViaIdentity$|^CreateViaIdentityExpanded$|^Update$|^UpdateViaIdentity$ | ||
| variant: ^(Create|Update)(?!.*?Expanded) |
Copilot
AI
Aug 22, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The regex pattern ^(Create|Update)(?!.*?Expanded) uses a negative lookahead that may not work as intended. Consider using ^Create$|^CreateViaIdentity$|^Update$|^UpdateViaIdentity$ for clearer intent and better maintainability.
| variant: ^(Create|Update)(?!.*?Expanded) | |
| variant: ^Create$|^Update$ |
| Enable recommendation by resource Id | ||
|
|
||
| ### Example 2: Enable recommendation by recommendation name | ||
| ### Example 2: Enable recommendation byrecommendation name |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
by recommendation (let's not remove this space in between)
| ``` | ||
|
|
||
| Enable recommendation by recommendation name | ||
| Enable recommendation byrecommendation name |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
by recommendation (let's not remove this space in between)
… jinpei/main/Advisor-update-v4
isra-fel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Description
Mandatory Checklist
Please choose the target release of Azure PowerShell. (⚠️ Target release is a different concept from API readiness. Please click below links for details.)
Check this box to confirm: I have read the Submitting Changes section of
CONTRIBUTING.mdand reviewed the following information:ChangeLog.mdfile(s) appropriatelysrc/{{SERVICE}}/{{SERVICE}}/ChangeLog.md.## Upcoming Releaseheader in the past tense.ChangeLog.mdif no new release is required, such as fixing test case only.