Migration guide for Az.Resources breaking changes#29227
Open
Celinadhh wants to merge 3 commits intoAzure:mainfrom
Open
Migration guide for Az.Resources breaking changes#29227Celinadhh wants to merge 3 commits intoAzure:mainfrom
Celinadhh wants to merge 3 commits intoAzure:mainfrom
Conversation
Co-authored-by: Celina Zhao <zhaocelina@microsoft.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
| Thanks for your contribution! The pull request validation has started. Please revisit this comment for updated status. |
Member
|
/azp run |
Contributor
|
Azure Pipelines successfully started running 3 pipeline(s). |
Contributor
There was a problem hiding this comment.
Pull request overview
Adds an Az 16.0.0 migration guide entry focused on Az.Resources policy cmdlets, documenting how scripts should be updated for the breaking removal of the legacy -BackwardCompatible behavior and .Properties.* access patterns.
Changes:
- Introduces a new
Az.16.0.0migration guide document for Az.Resources policy cmdlets. - Documents before/after script updates for flattened output property access and
Remove-*return behavior (-PassThru).
Comment on lines
+109
to
+117
| $policyExemption = Get-AzPolicyAssignment -Name MyAssignment | New-AzPolicyExemption -Name MyExemption -ExemptionCategory Mitigated -BackwardCompatible | ||
| $policyDefinitionId = $policyExemption.Properties.PolicyAssignmentId | ||
| ``` | ||
|
|
||
| #### After | ||
| ```powershell | ||
| $policyExemption = Get-AzPolicyAssignment -Name MyAssignment | New-AzPolicyExemption -Name MyExemption -ExemptionCategory Mitigated | ||
| $policyDefinitionId = $policyExemption.PolicyAssignmentId | ||
| ``` |
There was a problem hiding this comment.
In the New-AzPolicyExemption example, the variable name $policyDefinitionId doesn’t match the value being read (PolicyAssignmentId / .Properties.PolicyAssignmentId). This looks like a copy/paste mistake and could confuse readers—rename the variable to reflect that it’s the assignment id (or change the property if the intent was to show a definition id).
mentat9
approved these changes
Mar 2, 2026
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.
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.