Skip to content

fix: send multipart encoding when using gcs_uri#278

Merged
beveradb merged 1 commit into
mainfrom
feat/sess-20260325-1130-gcs-passthrough
Mar 25, 2026
Merged

fix: send multipart encoding when using gcs_uri#278
beveradb merged 1 commit into
mainfrom
feat/sess-20260325-1130-gcs-passthrough

Conversation

@beveradb
Copy link
Copy Markdown
Collaborator

Summary

Fix 400 Bad Request when using gcs_uri parameter on the /separate endpoint.

FastAPI requires multipart/form-data for endpoints with File()/Form() params. When gcs_uri was used without a file upload, the requests library defaulted to application/x-www-form-urlencoded, which FastAPI rejected.

Fix: send a dummy empty file field to force multipart encoding.

@coderabbitai ignore

🤖 Generated with Claude Code

FastAPI requires multipart/form-data for endpoints with File()/Form()
parameters. When gcs_uri is used without a file upload, requests
defaulted to x-www-form-urlencoded, causing a 400 Bad Request.

Fix: send a dummy empty file field to force multipart encoding.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@beveradb beveradb force-pushed the feat/sess-20260325-1130-gcs-passthrough branch from 305719a to 6b3dadc Compare March 25, 2026 21:43
@beveradb beveradb merged commit 5a801f8 into main Mar 25, 2026
5 of 6 checks passed
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