Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

storage: HTTP 416 on GET request of 0 length file #2076

Closed
weichungwen opened this issue Nov 8, 2021 · 3 comments
Closed

storage: HTTP 416 on GET request of 0 length file #2076

weichungwen opened this issue Nov 8, 2021 · 3 comments
Assignees
Labels
priority: p3 Desirable enhancement or fix. May not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@weichungwen
Copy link

Environment details

  • Programming language: Java
  • OS: Debian 11
  • Language runtime version: OpenJDK 17
  • Package version: google-api-services-storage v1-rev20211018-1.32.1

Steps to reproduce

  1. Create an empty file on Cloud Storage
  2. Create a service account and download its JSON key
  3. Decompress the attached my-app.tar.gz and substitute constants PRIVATE_KEY, SERVICE_ACCOUNT, GCS_BUCKET and GCS_OBJECT in src/main/java/com/example/App.java
  4. Compile with mvn compile then run with mvn exec:java -Dexec.mainClass=com.example.App -Djava.util.logging.config.file=logging.properties

Similar issue

It seems Storage.Objects.Get.executeMediaAndDownloadTo() adds Range: bytes=0-33554431 which leads to 416 Requested range not satisfiable. A similar report can be found in golang client library.

@weichungwen weichungwen added priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Nov 8, 2021
@product-auto-label product-auto-label bot added the api: storage Issues related to the Cloud Storage API. label Nov 8, 2021
@yoshi-automation yoshi-automation added 🚨 This issue needs some love. and removed 🚨 This issue needs some love. labels Feb 6, 2022
@yoshi-automation yoshi-automation added the 🚨 This issue needs some love. label May 7, 2022
@andrewsg andrewsg transferred this issue from googleapis/google-api-java-client-services May 20, 2022
@BenWhitehead BenWhitehead removed 🚨 This issue needs some love. api: storage Issues related to the Cloud Storage API. labels May 25, 2022
@BenWhitehead
Copy link
Contributor

"internal"note: This is not unique to Storage, it applies to the api client which in turn is used by all apiary generated clients.

@yoshi-automation yoshi-automation added the 🚨 This issue needs some love. label May 25, 2022
@blakeli0 blakeli0 removed the 🚨 This issue needs some love. label May 27, 2022
@yoshi-automation yoshi-automation added the 🚨 This issue needs some love. label May 27, 2022
@blakeli0 blakeli0 self-assigned this May 27, 2022
@Neenu1995 Neenu1995 added priority: p3 Desirable enhancement or fix. May not be included in next release. and removed priority: p2 Moderately-important priority. Fix may not be included in next release. 🚨 This issue needs some love. labels Jun 9, 2022
@Neenu1995
Copy link
Contributor

Reducing priority since this is not blocking.

@blakeli0
Copy link
Contributor

blakeli0 commented Aug 2, 2023

Closing since this is a rare use case that it only happens with empty files.

@blakeli0 blakeli0 closed this as completed Aug 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p3 Desirable enhancement or fix. May not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

No branches or pull requests

5 participants