If the code breaks in (4), while
starting the vm (receive an exception), how would you remove the
vms created above (1)(2) ? I asked myself this.
The option I could think know is to add try/except in the code,
but, the with/rollback was implemented exactly for this (or to
avoid this).
I also tried to split with/rollback, but this does not work.
One solution would be to remove the VMs by their UUIDs instead of by
their names. The UUID is a unique value and it never changes, so the
deferred commands would always work, even if the VM name changes.