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

Bun process exits silently when downloading GCS files with @google-cloud/storage #7747

Open
Scalahansolo opened this issue Dec 19, 2023 · 2 comments
Labels
bug Something isn't working needs investigate Needs to be investigated to find the root cause

Comments

@Scalahansolo
Copy link

What version of Bun is running?

1.0.18

What platform is your computer?

Darwin 23.0.0 arm64 arm

What steps can reproduce the bug?

As pointed out in this thread. (#6200 (comment))

This can reproed with a setup similar to the code in #6200 (comment).

Bun will list files in GCS just fine. Downloading files however does not work at all. Whenever I've attempted to download files in various ways using this npm library, the process just exits with code 0. I've also tried to use bun inspect with no success. In ever setup I've tried the process just exits with 0.

What is the expected behavior?

I'd expect to be able to use Bun along with @google-cloud/storage to download files from GCS

What do you see instead?

No response

Additional information

If it were possible to setup a shareable repro, I would, but I think since this involves using a GCP json key it's not easy to provide a super simple repro. I could maybe put together a repo with steps for setting up a GCS account that shows this issue?

@Scalahansolo Scalahansolo added the bug Something isn't working label Dec 19, 2023
@Scalahansolo
Copy link
Author

Scalahansolo commented Dec 19, 2023

To just provide some proof of what I am seeing, here some screenshots of my code and how it executes. This bun command ultimately calls the code block seen here.

CleanShot 2023-12-19 at 14 24 06@2x

CleanShot 2023-12-19 at 14 20 59@2x

@Electroid Electroid added the needs investigate Needs to be investigated to find the root cause label Dec 19, 2023
@gusfune
Copy link

gusfune commented Jan 24, 2024

I have a similar issue with @google-cloud/storage, but in my case is saving a file to a bucket.
I've managed to track down the issue to a dependency:

TypeError: null is not an object
      at node:1:8827
      at parseKeys (node:1:8847)
      at sign (node:1:8983)
      at node:1:9127
      at sign (/usr/src/app/node_modules/jwa/index.js:152:45)
      at jwsSign (/usr/src/app/node_modules/jws/lib/sign-stream.js:32:24)
      at /usr/src/app/node_modules/gtoken/build/src/index.js:224:31
      at requestToken (/usr/src/app/node_modules/gtoken/build/src/index.js:212:26)
      at getTokenAsyncInner (/usr/src/app/node_modules/gtoken/build/src/index.js:143:30)
      at /usr/src/app/node_modules/gtoken/build/src/index.js:137:55

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs investigate Needs to be investigated to find the root cause
Projects
None yet
Development

No branches or pull requests

3 participants