Error message from GraphQL Admin API: { "message":"Another staff member may be editing...}

tws117
New Member
1 0 0

Hello, I am trying to write a script that will loop through a collection orders and update their item quantities using GraphQL Admin API. I'm basing my script off this documentation https://shopify.dev/tutorials/edit-an-existing-order-with-admin-api.

I basically wrap each one of these steps in a setTimeout with a 4 second buffer as to avoid the throttling issues. And everything works perfectly, however a handful of orders seem to return this message when I try and execute the commit order step. 

 {"field":["id"],"message":"Another staff member may be editing this order. Try again."}

Not sure why or how this error is being generated? I'm the only one working on the store and I'm not in the store or doing anything to the item while the process is running. 

Any advice on how to debug this error or actually learn more about it is great appreciated.

Thank you,

Peter

0 Likes