post-step event returned an error Hello, I have a ...
# typescript
t
post-step event returned an error Hello, I have a pulumi stack written in Typescript and running on Azure. Over the past few days I have been suddenly getting the error below. I find if I retry my deployment the issue goes away. Is there any way to understand what is causing this and how to debug? I've had this stack for about 4 months and this started coming up just in the past week.
Copy code
error: post-step event returned an error: failed to verify snapshot: duplicate resource urn:pulumi:staging::repository::kubernetes:apps/v1:Deployment::fe01-pg-bastion-deployment (not marked for deletion)
c
It's in the error message:
duplicate resource
. You have another
Deployment
resource somewhere with the name
fe01-pg-bastion-deployment
.
t
That's the point - I don't. So this error seems erroneous. If I try again to deploy the stack it goes through. So it's somehow detecting duplication where none exists.
I am regularly deploying this stack once a day if not more and I am getting this error intermittently. The first time was last week, now it seems to happen about 30% of the time. Would appreciate any suggestions for how to debug this.
c
That is odd. When you see the duplicate error, what do you see in your state with that URN?
t
Next time this happens I will check.
👍 1
I ran
pulumi stack export
and captured the result. Is that what you meant by "what do you see in your state"?
c
Hi Sebastian, yes that's what I meant. Sorry I wasn't very clear with my message. Can you please look for that urn in your state file? You should only see one resource whose
urn
value is the one from your original message. Also, are you passing any additional flags when you run
pulumi up
? Just trying to understand how you operate this stack and why this started happening suddenly.
r
I'm getting this intermittently too, is there any workaround?