Skip to content

Fix: use binary content type for file source uploads#10

Closed
jason-rl wants to merge 1 commit intomainfrom
fix/file-upload-content-type
Closed

Fix: use binary content type for file source uploads#10
jason-rl wants to merge 1 commit intomainfrom
fix/file-upload-content-type

Conversation

@jason-rl
Copy link
Copy Markdown
Contributor

Summary

  • uploadSingleFile was auto-detecting content type from file extension — .tgz files were tagged as tgz, causing rage to extract them as archives instead of placing them as single files
  • Hardcode binary content type for file uploads so the file is placed as-is on the devbox
  • Export determineContentType so it remains available for future use

Context

This broke source-type: file for npm package tarballs — the tarball was extracted instead of being kept whole for npm install -g ./file.tgz at mount time.

Test plan

  • Deploy a file-type agent with a .tgz file and verify it's placed as a single file (not extracted)
  • Verify npm install -g ./agent.tgz works in setup commands

🤖 Generated with Claude Code

uploadSingleFile was auto-detecting content type from the file
extension, causing .tgz files to be marked as tgz. Rage then
extracts tgz objects as archives instead of placing them as single
files, breaking npm install from the tarball at mount time.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@jason-rl jason-rl closed this Apr 10, 2026
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