Skip to content

fix: x-upsert on resumable PATCH so reprocess can overwrite the processed video - #90

Merged
brianle423 merged 1 commit into
mainfrom
fix/tus-upsert-on-reprocess
Sep 14, 2026
Merged

brianle423 merged 1 commit into
mainfrom
fix/tus-upsert-on-reprocess

Conversation

@brianle423

Copy link
Copy Markdown
Collaborator

Reprocessing any recording whose processed.mp4 already exists failed with 409 Conflict from the TUS endpoint on production (match e6ba4268, 2026-09-14) and was marked failed with 'The analyzed video could not be saved.' Supabase checks upsert when the upload is finalized on the last PATCH, and only the create request carried x-upsert. This adds the header to PATCH and HEAD. First-time uploads were unaffected.

Test plan

  • backend/tests/test_storage_upload.py and test_reap_stuck_processing.py pass
  • modal deploy, reprocess e6ba4268 on production, confirm done

…erwrite processed.mp4

Supabase evaluates upsert when the TUS upload is finalized, which is the PATCH that
completes the object, not the create request. Reprocessing any recording whose
processed.mp4 already existed failed with 409 Conflict on production (match e6ba4268,
2026-09-14) and was marked failed with 'The analyzed video could not be saved.'
@vercel

vercel Bot commented Sep 14, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
courtcheck Ready Ready Preview Sep 14, 2026 11:00pm UTC

@brianle423
brianle423 merged commit ddd4cfb into main Sep 14, 2026
6 of 7 checks passed

This branch was successfully deployed

1 active deployment
Preview — b789e186 Deployed Sep 14, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant