Skip to content

chore: protect build timings insert for invalid enums - #20821

Merged
Emyrk merged 2 commits into
mainfrom
stevenmasley/invalid_timing_stage
Nov 19, 2025
Merged

Emyrk merged 2 commits into
mainfrom
stevenmasley/invalid_timing_stage

Conversation

@Emyrk

@Emyrk Emyrk commented Nov 18, 2025 •

Copy link
Copy Markdown
Member

You get this error when an insert fails:

Workspace build failed
internal provisionerserver error: complete job: commit transaction: pq: Could not complete operation in a failed transaction

Database insert errors will fail the transaction. So this error is fatal. Properly return it for a better error call stack, and not just hiding the error in the logs.

Error

I broke something in a side branch, and this was the error. Pretty opaque, debugged it down to what you see in this PR. This fixes it in prod by skipping the timing. It also makes the insert a fatal error.

Screenshot From 2025-11-18 10-27-41

@dannykopping dannykopping left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, would be interesting to see if this is expected PG behaviour or a libpq bug.

@Emyrk
Emyrk merged commit a10c5ff into main Nov 19, 2025
48 of 50 checks passed
@Emyrk
Emyrk deleted the stevenmasley/invalid_timing_stage branch November 19, 2025 15:34
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 19, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants