curlconverter / curlconverter

Transpile curl commands into Python, JavaScript and 27 other languages
https://curlconverter.com
MIT License
7.18k stars 871 forks source link

can't install dependency yargs in docker #261

Closed prabak closed 2 years ago

prabak commented 3 years ago

Why did the yargs dependency change from "yargs": "github:NickCarneiro/yargs" to "yargs": "git@github.com:NickCarneiro/yargs-ansi.git"? My docker is erroring out now:

#20 20.53 npm ERR! prepareGitDep npm ERR! Error while executing:
#20 20.53 npm ERR! prepareGitDep npm ERR! /usr/bin/git ls-remote -h -t ssh://git@github.com/NickCarneiro/yargs-parser-ansi.git
#20 20.53 npm ERR! prepareGitDep npm ERR!
#20 20.53 npm ERR! prepareGitDep npm ERR! Host key verification failed.
#20 20.53 npm ERR! prepareGitDep npm ERR! fatal: Could not read from remote repository.
LucaGambaro commented 3 years ago

Same problem, for now, i solved by deleting the dependency

npm uninstall yargs and then npm i --save yargs

after this, i linked the library with npm link and relinked in the new project npm link curlconverter

And seems to work

gregsifr commented 3 years ago

@LucaGambaro That didn't help at all, I tried different versions as well and it still resulted in the same error.

mustafafrw commented 3 years ago

Same problem, I could not solve

arshxyz commented 2 years ago

Same problem, the issue seems to arise from yargs being pulled from a a git repo instead of npm.

verhovsky commented 2 years ago

According to https://stackoverflow.com/a/29380765 , this can be solved by saving GitHub's SSH key, like this

ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts

before running npm install curlconverter.

verhovsky commented 2 years ago

We published our fork of yargs on npm as @curlconverter/yargs, so it should no longer be possible for you to get this error if you upgrade to curlconverter 3.21.0+