0
votes

I reran some test code that inserts several hundred items into my register. The code worked a few months ago. Now I'm receiving a 409 - "conflict/Another update may be in progress, please try again."

The error can happen when issuing a batch request of item DELETEs or batch request of item POSTs. It does NOT happen when each delete or post is issued as an individual request.

My process runs synchronously under a single thread so I never have more than a single request into Square at any time.

I'm guessing that this is a bug that has been introduced as part of some code change to check for concurrent updates, but which code has not been properly tested (again, just a guess).

1

1 Answers

0
votes

Thanks for pointing out this undocumented error type. It is possible to receive a 409 error from items-related endpoints when you submit a large number of simultaneous requests (as with the Submit Batch endpoint). To reduce the likelihood of this error, you can reduce the number of requests you include in each individual batch (say from 30 to 15), or send each request individually.

Even after reducing the size of a batch, it is still possible that a 409 error might occur. Your application should be prepared to encounter this error and retry any affected requests.

If the issue persists, please add a comment to this question and we will investigate further.