-
Notifications
You must be signed in to change notification settings - Fork 33
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
NPE when creating a Path with a bucket that doesn't exist. #857
Comments
ah I see what is happening here. In CloudStorageFileSystemProvider.java L967
We try and access the value for requester pays without validating that the bucket exists. |
I am going to bring this up with the team as we should be giving a more useful error message such as an illegal state exception or perhaps just return false/null if the bucket does not exist. |
Fixes a NullPointerException when creating a Path object with a bucket that doesn't exist. This only occurred when autoDetectRequesterPays = true. Refs: googleapis#857
@sydney-munro Yeah, it's a silly bug. I opened a PR with a potential solution. |
Fixes a NullPointerException when creating a Path object with a bucket that doesn't exist. This only occurred when autoDetectRequesterPays = true. Refs: googleapis#857
Fixes a NullPointerException when creating a Path object with a bucket that doesn't exist. This only occurred when autoDetectRequesterPays = true. Refs: #857 Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [x] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/java-storage-nio/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [ ] Code coverage does not decrease (if any source code was changed) - [x] Appropriate docs were updated (if necessary) Fixes #857☕️ If you write sample code, please follow the [samples format]( https://github.com/GoogleCloudPlatform/java-docs-samples/blob/main/SAMPLE_FORMAT.md).
* The previous attempt to fix requester pays didn't fix it in many cases. This incorporates a newer version of the NIO library with several patches to fix edge cases we were hitting. * googleapis/java-storage-nio#850 * googleapis/java-storage-nio#856 * googleapis/java-storage-nio#857 * upgrade com.google.cloud:google-cloud-nio:0.123.23 ->0.123.25 * fixes #7716
* The previous attempt to fix requester pays didn't fix it in many cases. This incorporates a newer version of the NIO library with several patches to fix edge cases we were hitting. * googleapis/java-storage-nio#849 * googleapis/java-storage-nio#856 * googleapis/java-storage-nio#857 * upgrade com.google.cloud:google-cloud-nio:0.123.23 ->0.123.25 * fixes #7716
* The previous attempt to fix requester pays didn't fix it in many cases. This incorporates a newer version of the NIO library with several patches to fix edge cases we were hitting. * googleapis/java-storage-nio#849 * googleapis/java-storage-nio#856 * googleapis/java-storage-nio#857 * upgrade com.google.cloud:google-cloud-nio:0.123.23 ->0.123.25 * fixes #7716
* The previous attempt to fix requester pays didn't fix it in many cases. This incorporates a newer version of the NIO library with several patches to fix edge cases we were hitting. * googleapis/java-storage-nio#849 * googleapis/java-storage-nio#856 * googleapis/java-storage-nio#857 * upgrade com.google.cloud:google-cloud-nio:0.123.23 ->0.123.25 fixes #7716 Co-authored-by: David Roazen <droazen@broadinstitute.org>
Paths.get(new Uri(A_PATH_TO_A_BUCKET_THAT_DOESNT_EXIST))
crashes with a NullPointerException ifautoDetectRequesterPays
= true.Environment details
Steps to reproduce
Code example
Stack trace
The text was updated successfully, but these errors were encountered: