-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Fix a bug with enviroment variable injection to the git repo url #2710
Conversation
By any chance we can merge this? |
I want to sit on this for a while. Generally a patch to |
Interesting issue -- I'm pretty sure we're going to un-vendor pip soon though so this might not be the best approach to solving it |
Is there a fix for installing private git repos with |
One way is to use SSH, such as GitHub deploy keys. |
Really anything that involves putting a password in a URI directly is a bad practice, and we've had similar versions of this proposed in the past and closed for various security related reasons that I can't completely recall. If someone can dig through the past issues on the topic it would be helpful |
Thank you for contributing to Pipenv!
The issue
Fix a enviroment injection issue when dealing with git repo url dependencies. The problem issued when pipenv trying to execute command similar to "git clone -q git+https://${USER}:${PASSWORD}/github.com" using python subprocess.Popen, the enviroment variable inside this command is not propely resolved.Which will cause a permission deny error or a repo not found error.
The fix
using os.path.expandvars(cmd-parts) before passing to subprocess.
The checklist
#2635
news/2365.bugfix