https://pulumi.com logo
#python
Title
# python
c

chilly-hairdresser-56259

06/18/2020, 3:40 PM
Within Pulumi is there a graceful way to stop Pulumi from processing? I thought
quit()
would work, but that caused all my resources to be destroyed. Luckily that is a sandbox environment for testing before it gets released to any account which has running resources. I see pulumi has
pulumi.Error()
but havent found the docs for it yet.
f

future-barista-68134

06/18/2020, 8:45 PM
Throwing an exception is the best practice here. Also,
quit()
destroying all of your resources is unexpected, kind of scary, behavior.. would you mind creating an issue related to this if it’s reproducible?
c

chilly-hairdresser-56259

06/18/2020, 9:42 PM
yea I will open a ticket, ill see if I can reproduce it in my sandbox environment. Basically all I was doing is checking if certain OS environment variables were set and if there were
None
print something out and
quit()
. Preview just stated no changes then when I pushed it through up said 92 changes