@google-cloud/storage version: 1.7.0HTTPS_PROXY=http://proxy... node script.js
const storage = require('@google-cloud/storage')({
projectId: 'projectid',
keyFilename: 'gcloud.json',
});
const bucketname = 'bucketname';
const bucket = storage.bucket(bucketname);
const file = bucket.file('foo');
const stream = file.createWriteStream();
stream.on('error', console.log);
stream.on('finish', console.log);
stream.end('bar');
nodejs-storage uses
which uses gcs-resumable-upload
which uses axios and the issue:
issues at axios
pullrequest (open since 1 year caused by bad weather)
It looks like the axios PR was merged. We probably just need a new release, then we'll all be updated automatically?
cc @JustinBeckwith
Working on it :)
@refextu - can you share the specific setup of your upstream proxy? I am struggling to recreate the issue, even though it's obvious there's a problem. Anything you can offer here in the way of a repro would be super helpful.
Also - if I create a patch, would you be willing to try that?
@JustinBeckwith You can use Docker ans Squid for local testing:
docker run --publish 3128:3128 sameersbn/squid:3.3.8-23
I'm happy to test a patch.
@JustinBeckwith it seems like we have more proxy probs:
Do you think these all chase back to https://github.com/axios/axios/pull/959? There's been some activity on that PR that suggests the fix was not final.
@JustinBeckwith was this fixed with the recent auth release?
Possibly, maybe, it depends. I'll be a lot more confident once we upgrade to v0.24.0 of nodejs-common.
We've upgraded! @JustinBeckwith How's the confidence level? 馃帤
@refextu can you give the 2.x release a shot and let us know if it works?
@JustinBeckwith if this is fixed, would you suspect https://github.com/googleapis/nodejs-pubsub/issues/133 is fixed as well?
will check later
tested 2.0.3 got error:
write EPROTO 140735840650112:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:../deps/openssl/openssl/ssl/s23_clnt.c:827
Test-Code was changed to:
const { Storage } = require('@google-cloud/storage');
const storage = new Storage({
projectId: 'projectId',
keyFilename: 'gcloud.json',
});
const bucketname = 'bucketname';
const bucket = storage.bucket(bucketname);
const file = bucket.file('foo');
const stream = file.createWriteStream();
stream.on('error', console.log);
stream.on('finish', console.log);
stream.end('bar');
I think https://github.com/axios/axios/issues/925#issuecomment-419357126 suggests that this will be fixed in 0.19.0 of axios. While current dependency is 0.18.0, as 0.19.0 is not released yet.
Thanks for the update @refextu.
For now, I'll mark this issue as blocked, as 0.19.0 has still not been released.
@stephenplusplus - Is this still blocked? Remember there is another issue related to it (https://github.com/googleapis/nodejs-pubsub/issues/133).
@JustinBeckwith I believe you had been working on the Axios + Proxy issues-- do you know what became of that, and if your prior work would have fixed this?
This should be fixed in the latest version of google-auth-library. We implemented a work-around that goes around Axios here:
https://github.com/googleapis/google-auth-library-nodejs/blob/master/src/transporters.ts#L102
I am not the best at setting up or testing proxies :) Would it be possible to set up a proxy server or something in long-door-651 for when we need to debug stuff like this?
If it helps, I ended up getting through the proxy by using this
https://www.npmjs.com/package/global-tunnel-ng
@refextu would you mind testing this again? I haven't been able to reproduce in my testing, but I'm not confident I can mirror your environment accurately enough to promise it has been resolved.
This appears to still be an issue as of v35.0.0. @stephenplusplus https://github.com/googleapis/nodejs-pubsub/issues/133#issuecomment-443708636
I can confirm, that this is still an issue, but different error:
{ Error: write EPROTO 4584015296:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:252:
Hello, all! @google-cloud/storage v2.4.0 was released, which hopefully fixes this issue. Would anyone mind testing?
I'm going to close, but please comment back if things are 馃憥
Thanks, I can confirm, that this is working like a breeze. 馃憤
Most helpful comment
Thanks, I can confirm, that this is working like a breeze. 馃憤