-
Notifications
You must be signed in to change notification settings - Fork 32
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
As of 2022-02-22 Automatic detection of requesterPays buckets is failing #824
Comments
I think the underlying issue is here. Lines 963 to 975 in fc0f8a1
It always falls into the catch block which then tries to match against that changed string. I think it shouldn't be falling into the catch block and instead the call to get(bucketName) should include an option specifying the project name which should keep it from throwing an exception. It seems like a bug that was previously covered up by the catch clause. |
Ignore that. It seems that throwing the exception is necessary because it's attempting to find requester pays status without providing the user account to avoid access charges in the case where it wasn't requester pays. It seems like there needs to be a more robust mechanism of determining if this is a requester pays bucket than scraping the exception message after trying to connect. This mechanism also causes problems because it requires the somewhat unusual Is there either: |
This issue is unfortunately breaking large numbers of our production workflows. I hate to suggest this, but perhaps for now we could grit our teeth and add the missing "a" into the message it's looking for to get it working again, and open a separate ticket to research / implement a more robust mechanism for detecting requester pays status. Unless someone already knows of a more robust way? Once a patch is in for this issue, would it be possible to get a release of the library with the fix? |
* Fix the expected error message that is tested when checking for requester pays buckets. * The error message recieved when querying for requester pays status changed to include an 'a' which caused strict matching to fail. * This fixes and standardizes the error message to use the same string for both the code and the tests.
* Fix the expected error message that is tested when checking for requester pays buckets. * The error message recieved when querying for requester pays status changed to include an 'a' which caused strict matching to fail. * This fixes and standardizes the error message to use the same string for both the code and the tests.
* Fix the expected error message that is tested when checking for requester pays buckets. * The error message recieved when querying for requester pays status changed to include an 'a' which caused strict matching to fail. * This fixes and standardizes the error message to use the same string for both the code and the tests.
The error message recieved when querying for requester pays status changed to include an 'a' which caused strict matching to fail. This fixes and standardizes the error message to use the same string for both the code and the tests. Refs: googleapis#824
First observed on PR #823 and visible in the integration tests related to Requester Pays (build results)
Environment details
Code example
java-storage-nio/google-cloud-nio/src/test/java/com/google/cloud/storage/contrib/nio/it/ITGcsNio.java
Lines 310 to 316 in 417704a
External references such as API reference guides
It seems the error message response changed subtly
According to public documentation, we should expect the
reason
to beuserProjectMissing
, however it isrequired
as can be seen inRelated from NodeJS https://github.com/googleapis/nodejs-storage/pull/1791/files
The text was updated successfully, but these errors were encountered: