Skip to content

undo_conflict

This code is an undo action’s execution.errorcode (the action is failed), not an HTTP answer: inside its one transaction the undo found a row that changed after the plan was made, a row locked…

HTTP 409 · invalid_request_error · not retryable

This code is an undo action’s execution.error_code (the action is failed), not an HTTP answer: inside its one transaction the undo found a row that changed after the plan was made, a row locked longer than undo.lock_timeout, or a step that didn’t change exactly one row. Postgres rolled the whole undo back, so nothing was changed.

Preview the undo again; the new plan follows the rows as they are now. For a lock, try again in a moment.

HTTP 409 · undo_conflict
{
"error": {
"type": "invalid_request_error",
"code": "undo_conflict",
"message": "Row public.orders id=42 changed after the plan was made (status is now 'cancelled'). Nothing was changed. Preview the undo again.",
"param": null,
"request_id": "req_01j9zr3m5k8q2w7x4t6v0b1c9d",
"doc_url": "https://docs.deedglass.com/errors/undo_conflict"
}
}

The message is for a person and can get more exact over time: branch on type and code, never on the message.

SDK Raised as
TypeScript (@deedglass/sdk) InvalidRequestError with code === "undo_conflict"
Python (deedglass) deedglass.InvalidRequestError with .code == "undo_conflict"