amis icon indicating copy to clipboard operation
amis copied to clipboard

smoke_test: --cancel still tries to launch an instance?

Open colemickens opened this issue 11 months ago • 2 comments

Hm. --cancel doesn't really behave the way I'd expect. The codepath around it seem to ... still try to boot an instance, rather than short-circuiting to the cancellation as I was expecting to see.

colemickens avatar Mar 28 '25 13:03 colemickens

Actually even worse, it seems like it tries to launch the instance (which fortunately fails due to the client token), and then... short-circuit exits before the termination code is called...

colemickens avatar Mar 28 '25 13:03 colemickens

Yeh it used to rely on the behaviour that a terminated instance returns the instance id. But this isn't true anymore (AWS sometimes throws Idempotent instance terminated exception) . We probably need to update the logic by storing the instance id and passing it explicitly to cancel instead of relying on RunInstances idempotency

arianvp avatar Mar 28 '25 17:03 arianvp