Skip to content

Conversation

Copy link

Copilot AI commented Sep 9, 2025

  • Explore repository structure and understand the codebase
  • Set up test environment and fix warnings.deprecated issue in websockets.py
  • Run existing tests to understand current behavior
  • Reproduce the curl upload issues described in the problem statement
  • Identify root causes of the upload failures:
    • Missing Content-Length header causes silent failures/timeouts
    • Missing Content-Type header causes 400 "Invalid file metadata"
    • Zero/invalid Content-Length causes 400 "Invalid file metadata"
    • Short filenames cause 400 "Invalid file metadata"
  • Fix FileMetadata.get_from_http_headers() to handle missing/invalid headers gracefully
  • Update validation to be more permissive for legitimate curl use cases
  • Add defensive defaults for missing headers
  • Test fix with curl command simulation
  • Run all tests to ensure no regressions

The issue is in the FileMetadata.get_from_http_headers() method which doesn't handle missing or invalid HTTP headers gracefully, causing legitimate curl uploads to fail.

Fixes #10.


💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.

Repository owner deleted a comment from Copilot AI Sep 9, 2025
Copilot AI requested a review from codeSamuraii September 9, 2025 13:12
@codeSamuraii codeSamuraii deleted the copilot/fix-http-upload-issues branch September 9, 2025 13:12
Repository owner locked and limited conversation to collaborators Sep 22, 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.

HTTP uploads with curl fail silently or with a 400

2 participants