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

dependency cls-hooked won't resolve #66

Open
Bastianowicz opened this issue Feb 20, 2021 · 8 comments
Open

dependency cls-hooked won't resolve #66

Bastianowicz opened this issue Feb 20, 2021 · 8 comments

Comments

@Bastianowicz
Copy link
Contributor

hi. since me updating npm to version 7 i am facing serious issues with your dependency of cls-hooked.
in my local dev environment everything is fine but in CI this dependency won't be resolved since npm cannot access it without an ssh key. this is because npm resolves the dependency as git+ssh://git@github... since the update.
so my question is: what is the reason for using the unreleased version 4.3.0 of cls-hooked and not just depending on the npm released 4.2.2?

@jasperblues
Copy link
Member

jasperblues commented Apr 8, 2021

@Bastianowicz So sorry for the slow reply! I didn't see your issue until now.

The forked version of cls-hooked is to fix a number of issues with the base version. There's a pull request, I'll need to check if it is merged yet. If not we can publish a packaged fork that can be pulled (with http) from npm.

On version of node that support it async-local-storage is used in place of cls-hooked.

Alternatively we might mark it as an optional dependency. Are you still facing trouble?

@Bastianowicz
Copy link
Contributor Author

I patched it by resolving it explicitly and adding it as my dependency in package.json so I could define what protocol to use. So it doesn't bother me at the moment but it is an unused dependency 😉

@jasperblues
Copy link
Member

OK, noted. Thanks @Bastianowicz. Sorry again for the slow reply!

@Bastianowicz
Copy link
Contributor Author

Bastianowicz commented Apr 8, 2021 via email

@nartc
Copy link
Contributor

nartc commented Jul 22, 2021

Ran into the same issue here :(. Was just removing node_modules and try to reinstall it then this error happens.

@jasperblues
Copy link
Member

cls-hooked is usually not needed. A good solution would be to mark it as optional or external and listed in docs.

@dotrunghieu2151
Copy link

@jasperblues, Could you please mark cls-hooked as an optional dependency ? I intend to run my app inside a docker container so it's not possible for me to manually resolve it in package-lock.json.

@jasperblues
Copy link
Member

@dotrunghieu2151 Could you send a PR pls? I will push a new npm build as soon as received.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants