-
Notifications
You must be signed in to change notification settings - Fork 20
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
Typesync fails with 401 using 0.8.0 when using a private registry but 0.7.0 succeeds #67
Comments
0.8 reads the registry URL using |
@jeffijoe Thanks for the quick response! I am using a custom registry. Is there other setup I could/should be doing in order to get my configuration to work with 0.8.0? |
Currently, a public registry is expected. Would either need to add a way to authenticate a private one or a config option to use the official npm registry. I never used a private registry before so I don't know how they work. |
I have auth setup to use my private repository already and that works for normal installing of npm packages. The only setup is I have a |
If I take the |
I also looked briefly for a npm package registry SDK/API but I couldn't find one. It's really hard to search for |
Would using the public registry not work? Or do you require using the private one? |
@jeffijoe no I can't use the public registry directly. I'm using a private registry for our company. This is because of at least two reasons I know of. First our private code is in the private registry. Second, it ensures that we proxy all calls from developers/CI at the company against our own registry to cut down on traffic to the public registry. I think a reasonable thing that would be nice is to use the auth in Another solution could be to not use the configured custom registry at all (use the public one only) but I'm guessing that change in 0.8.0 was made for a good reason so this might not be an option. Thanks for all the help! Much appreciate this really nice tool! |
I would prefer not to have to read the user's |
I also encountered this issue, I think it would be better if we support a |
The npm cli uses the npm-registry-fetch package which looks like it abstracts the details of fetching from the registry, including authentication. It also uses @npmcli/config for reading configuration which may be useful. |
Oh that's neat @deongroenewald ! I've been really swamped at work, but I would be open to a PR that uses that package! |
|
I have a private registry with auth configured via
~/.npmrc
.Forcing the version to 0.7.0 and running typesync I'm able to successfully run.
The text was updated successfully, but these errors were encountered: