Closed linonetwo closed 4 years ago
How many times have you tried, and how long was the window between each try? I am trying to figure out if this is a transient issue. I can't reproduce.
I tried three times, because it takes so long to complete (with error), and I tried with or without VPN. It didn't take much bandwidth, network usage never go higher than 100KB/s.
Maybe you can use something like promise-retry to retry failed ones? Catching such error and retry it?
Is it possibly a firewall issue? I can't reproduce at all, I've never seen this happen.
Can you make it possible to use the global npm config?
% npm config get registry
https://registry.npm.taobao.org/
I have set npm config set registry xxxx.taobao.xxxx
to speed it up, because it is pretty slow to access npm behind the firewall.
I edit node_modules/typesync/lib/npm-client.js
and it works fine...Actually the firewall problem.
That's weird because the callstack says it fails in the type definition source, which is fetching the search index, and that does not talk to NPM at all.
Adding a timeout in #59 and the ability to read the registry url from npm config was added in #57.
And my package json is