Skip to content

az snapshot delete does not delete all snapshots #19597

@mgugger

Description

@mgugger

This is autogenerated. Please review and update as needed.

Describe the bug

According to the documentation, "One or more resource IDs" can be passed with the "--ids" parameter. When deleting multiple snapshots by providing multiple ids however, only the first resource gets deleted. The "--ids" parameter is also not aligned with "--name" parameter which only accepts a single snapshot name.

Command Name
az snapshot delete --ids {}

Errors:

None, command succeeds.

To Reproduce:

Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

  • Create at least two managed disk snapshots
  • az snapshot delete --ids "$snapshot1_resource_id $snapshot2_resource_id"

Expected Behavior

Both $snapshot1_resource_id $snapshot2_resource_id are deleted.

Environment Summary

Windows-10-10.0.22000-SP0
Python 3.8.9
Installer: MSI

azure-cli 2.28.0

Additional Context

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions