-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
Add Default API Version to Get-AzResourceProvider cmdlet Resource Types array returned properties #26542
base: main
Are you sure you want to change the base?
Conversation
Add DefaultApiVersion of type string to the PSResourceProviderResourceType class to allow the Get-ResourceProvider cmdlet to return it
Set the DefaultApiVersion of the Resource Type object in method OnProcessRecord() to allow the Get-AzResourceProvider cmdlet to return Default API Version information to the user
️✔️Az.Accounts
|
Type | Title | Current Coverage | Description |
---|---|---|---|
Test Coverage Less Than 50% | 23.08 % | Test coverage for the module cannot be lower than 50%. |
⚠️ - MacOS
Type | Title | Current Coverage | Description |
---|---|---|---|
Test Coverage Less Than 50% | 23.08% | Test coverage for the module cannot be lower than 50%. |
⚠️ PowerShell Core - Windows
Type | Title | Current Coverage | Description |
---|---|---|---|
Test Coverage Less Than 50% | 23.08% | Test coverage for the module cannot be lower than 50%. |
⚠️ Windows PowerShell - Windows
Type | Title | Current Coverage | Description |
---|---|---|---|
Test Coverage Less Than 50% | 23.08% | Test coverage for the module cannot be lower than 50%. |
️✔️Az.CosmosDB
️✔️Build
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
️✔️Test
️✔️ - Linux
️✔️ - MacOS
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
️✔️Az.KeyVault
️✔️Build
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
⚠️ Az.MachineLearning
️✔️Build
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
⚠️ Test
⚠️ - Linux
Type Title Current Coverage Description ⚠️ Test Coverage Less Than 50% 0.00 % Test coverage for the module cannot be lower than 50%.
⚠️ - MacOS
Type Title Current Coverage Description ⚠️ Test Coverage Less Than 50% 0.00% Test coverage for the module cannot be lower than 50%.
⚠️ PowerShell Core - Windows
Type Title Current Coverage Description ⚠️ Test Coverage Less Than 50% 0.00% Test coverage for the module cannot be lower than 50%.
⚠️ Windows PowerShell - Windows
Type Title Current Coverage Description ⚠️ Test Coverage Less Than 50% 0.00% Test coverage for the module cannot be lower than 50%.
️✔️Az.ManagedServiceIdentity
️✔️Build
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
️✔️Az.Monitor
️✔️Build
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
️✔️Az.Network
️✔️Build
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
⚠️ Az.Resources
️✔️Build
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
️✔️Breaking Change Check
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
⚠️ Signature Check
⚠️ PowerShell Core - Windows
Type Cmdlet Description Remediation ⚠️ Get-AzADGroupOwner Get-AzADGroupOwner Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzADGroupOwner Get-AzADGroupOwner changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzADServicePrincipalAppRoleAssignment Get-AzADServicePrincipalAppRoleAssignment Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzADServicePrincipalAppRoleAssignment Get-AzADServicePrincipalAppRoleAssignment changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicyAssignment Get-AzPolicyAssignment Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicyAssignment Get-AzPolicyAssignment changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicyDefinition Get-AzPolicyDefinition Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicyDefinition Get-AzPolicyDefinition changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicyExemption Get-AzPolicyExemption Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicyExemption Get-AzPolicyExemption changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicySetDefinition Get-AzPolicySetDefinition Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicySetDefinition Get-AzPolicySetDefinition changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact.
⚠️ Windows PowerShell - Windows
Type Cmdlet Description Remediation ⚠️ Get-AzADGroupOwner Get-AzADGroupOwner Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzADGroupOwner Get-AzADGroupOwner changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzADServicePrincipalAppRoleAssignment Get-AzADServicePrincipalAppRoleAssignment Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzADServicePrincipalAppRoleAssignment Get-AzADServicePrincipalAppRoleAssignment changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicyAssignment Get-AzPolicyAssignment Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicyAssignment Get-AzPolicyAssignment changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicyDefinition Get-AzPolicyDefinition Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicyDefinition Get-AzPolicyDefinition changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicyExemption Get-AzPolicyExemption Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicyExemption Get-AzPolicyExemption changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ⚠️ Get-AzPolicySetDefinition Get-AzPolicySetDefinition Changes the ConfirmImpact but does not set the SupportsShouldProcess property to true in the cmdlet attribute. Determine if the cmdlet should implement ShouldProcess and if so determine if it should implement Force / ShouldContinue ⚠️ Get-AzPolicySetDefinition Get-AzPolicySetDefinition changes the confirm impact. Please ensure that the change in ConfirmImpact is justified Verify that ConfirmImpact is changed appropriately by the cmdlet. It is very rare for a cmdlet to change the ConfirmImpact. ️✔️Help File Existence Check
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
️✔️File Change Check
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
⚠️ UX Metadata Check
⚠️ PowerShell Core - Windows
Type Module ResourceType SubResourceType Command Description ⚠️ Az.Resources Microsoft.Resources subscriptionsResourcegroups Get-AzResourceGroup The path /subscriptions/{subscriptionId}/resourceGroups/{name} doesn't contains the right resource tpye: Microsoft.Resources ⚠️ Az.Resources Microsoft.Resources subscriptionsResourcegroups Remove-AzResourceGroup The path /subscriptions/{subscriptionId}/resourceGroups/{name} doesn't contains the right resource tpye: Microsoft.Resources
⚠️ Windows PowerShell - Windows
Type Module ResourceType SubResourceType Command Description ⚠️ Az.Resources Microsoft.Resources subscriptionsResourcegroups Get-AzResourceGroup The path /subscriptions/{subscriptionId}/resourceGroups/{name} doesn't contains the right resource tpye: Microsoft.Resources ⚠️ Az.Resources Microsoft.Resources subscriptionsResourcegroups Remove-AzResourceGroup The path /subscriptions/{subscriptionId}/resourceGroups/{name} doesn't contains the right resource tpye: Microsoft.Resources ️✔️Test
️✔️ - Linux
️✔️ - MacOS
️✔️PowerShell Core - Windows
️✔️Windows PowerShell - Windows
Thank you for your contribution efloresgil! We will review the pull request and get back to you soon. |
Made this small pull request to address: #26486 |
@microsoft-github-policy-service agree company="Microsoft" |
Appreciate the contribution :) Except for setting up json deserialization as you've done in this PR, there's extra work to use new API version for this PR, cause otherwise you still can't get the default version from the http response. @vidai-msft please contact ARM team who owns this cmdlet for assistance. Thanks. |
|
@isra-fel thanks for your answer. Quick question about this. Even in its current version, the API call the cmdlet uses does retrieve the default api version. You can test with The SDKClient appears to already have the latest api-version setup for this: azure-powershell/src/Resources/Resources.Management.Sdk/Generated/ResourceManagementClient.cs Line 339 in 90206f7
API Reference here: https://learn.microsoft.com/en-us/rest/api/resources/providers/get?view=rest-resources-2021-04-01&tabs=HTTP Was this the additional change you meant? |
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.md
and reviewed the following information:ChangeLog.md
file(s) appropriatelysrc/{{SERVICE}}/{{SERVICE}}/ChangeLog.md
.## Upcoming Release
header in the past tense.ChangeLog.md
if no new release is required, such as fixing test case only.