[PR #1251] [MERGED] Remove obsolete upload route #1328

Closed
opened 2026-03-03 12:34:06 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/fsouza/fake-gcs-server/pull/1251
Author: @manuteleco
Created: 7/17/2023
Status: Merged
Merged: 7/30/2023
Merged by: @fsouza

Base: mainHead: remove_obsolete_upload_route


📝 Commits (1)

  • 5154156 Remove obsolete upload route

📊 Changes

2 files changed (+4 additions, -5 deletions)

View changed files

📝 fakestorage/server.go (+0 -1)
📝 fakestorage/upload_test.go (+4 -4)

📄 Description

POSTing to /storage/v1/b/my-bucket/o to upload an object is not supposed to work. The Google Cloud Storage API returns a 400 error with a response body like this:

{
  "error": {
    "code": 400,
    "message": "Uploads must be sent to the upload URL. Re-send this request to https://storage.googleapis.com/upload/storage/v1/b/my-bucket/o?uploadType=media&name=test.txt",
    "errors": [
      {
        "message": "Uploads must be sent to the upload URL. Re-send this request to https://storage.googleapis.com/upload/storage/v1/b/my-bucket/o?uploadType=media&name=test.txt",
        "domain": "global",
        "reason": "wrongUrlForUpload"
      }
    ]
  }
}

To stay true to the GCS API, we remove support from the fake-gcs-server as well.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/fsouza/fake-gcs-server/pull/1251 **Author:** [@manuteleco](https://github.com/manuteleco) **Created:** 7/17/2023 **Status:** ✅ Merged **Merged:** 7/30/2023 **Merged by:** [@fsouza](https://github.com/fsouza) **Base:** `main` ← **Head:** `remove_obsolete_upload_route` --- ### 📝 Commits (1) - [`5154156`](https://github.com/fsouza/fake-gcs-server/commit/5154156b84a1c915856b611a3628ce6bfe7c06ab) Remove obsolete upload route ### 📊 Changes **2 files changed** (+4 additions, -5 deletions) <details> <summary>View changed files</summary> 📝 `fakestorage/server.go` (+0 -1) 📝 `fakestorage/upload_test.go` (+4 -4) </details> ### 📄 Description POSTing to `/storage/v1/b/my-bucket/o` to upload an object is not supposed to work. The Google Cloud Storage API returns a 400 error with a response body like this: ```json { "error": { "code": 400, "message": "Uploads must be sent to the upload URL. Re-send this request to https://storage.googleapis.com/upload/storage/v1/b/my-bucket/o?uploadType=media&name=test.txt", "errors": [ { "message": "Uploads must be sent to the upload URL. Re-send this request to https://storage.googleapis.com/upload/storage/v1/b/my-bucket/o?uploadType=media&name=test.txt", "domain": "global", "reason": "wrongUrlForUpload" } ] } } ``` To stay true to the GCS API, we remove support from the `fake-gcs-server` as well. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-03 12:34:06 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/fake-gcs-server#1328
No description provided.