Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I add the --trusted-host in pycharm package install?

I installed Pycharm community Edition 2016.1.4 on a Windows 7 machine and tried to update some packages used by the project I intend to work on. The update failed because the local repository "is not trusted or a secure host" (according to pip), so to update packages in the command-line I need to run:

pip install <package> --trusted-host <insecure-host>

Is it possible to specify in PyCharm that --trusted-host option or is Pycharm so concerned about my security that it won't allow me to do so?

like image 798
gmauch Avatar asked Jul 19 '16 20:07

gmauch


1 Answers

After some digging I found the answer. Registering it here in case someone is interested.

Go to

File --> Settings --> Project: name_of_the_project --> Project Interpreter

Choose (double click) the package you want to update and the Available Packages will pop-up. There is a checkbox Options on the lower-left part of the window. Check that and enter

--trusted-host hostname

Option and hit the Install Package button.

That way I was able to update the package from the insecure host, thus solving my problem.

like image 61
gmauch Avatar answered Oct 19 '22 02:10

gmauch