-
Notifications
You must be signed in to change notification settings - Fork 3k
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
az lock create|delete --resource <rg-id> fails with cli.azure.cli.core.azclierror: 'NoneType' object has no attribute 'strip' #18862
Comments
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @armleads-azure. Issue DetailsDescribe the bugaz lock create or delete fails with error Command Name Errors:
To Reproduce:Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
Expected Behaviorresource lock created or deleted respectively. Environment Summary
Additional Context
Command with
|
route to service team |
@hayorov Hi, in fact, the parameter |
@zhoxing-ms |
@hayorov In fact, in CLI, the group name/id cannot be passed into |
Describe the bug
az lock create or delete fails with error
code = 2
with parameter--resource=/subscriptions/XXX/resourceGroups/YYY
Command Name
az lock create --name <name> --resource /subscriptions/XXX/resourceGroups/YYY
`az lock delete --name --resource /subscriptions/XXX/resourceGroups/YYY``
Errors:
To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
az lock delete --name {} --resource /subscriptions/XXX/resourceGroups/YYY --debug
Expected Behavior
resource lock created or deleted respectively.
Environment Summary
Additional Context
Command with
--resource-name <rg-name>
works as expected.The text was updated successfully, but these errors were encountered: