python - Can't install packages (in venv via Powershell)
I am trying to get a repository from github to work on my Windows 10 machine. This repository requires a large number of packages. The IDE I use is Pycharm. Within pycharm, one is automatically prompted to install any packages via pip. However, when I press "install packages" or try to install any package individually via pip, the following error appears:
Could not fetch URL https://pypi.org/simple/numpy/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/numpy/ (Caused by SSLError(SSLError(1, '_ssl.c:503: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version'),)) - skipping
When trying to find a solution, I came across this solution. I succesfully opened the venv in PowerShell. The solution then proposes to use the following line:
https://bootstrap.pypa.io/get-pip.py | python
This, however, gives me another error as follows:
curl : The request was aborted: Could not create SSL/TLS secure channel.
At line:1 char:1
+ curl https://bootstrap.pypa.io/get-pip.py | python
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
eption
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
I can not find any further solutions that can help me with this. If someone can help with a next step, that would be greatly appreciated. Thanks in advance.
Update
I reinstalled python and everything fixed itself. I guess something broke when installing it the first time.
python curl pycharm ssl-certificate python-venv
New contributor
add a comment |
I am trying to get a repository from github to work on my Windows 10 machine. This repository requires a large number of packages. The IDE I use is Pycharm. Within pycharm, one is automatically prompted to install any packages via pip. However, when I press "install packages" or try to install any package individually via pip, the following error appears:
Could not fetch URL https://pypi.org/simple/numpy/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/numpy/ (Caused by SSLError(SSLError(1, '_ssl.c:503: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version'),)) - skipping
When trying to find a solution, I came across this solution. I succesfully opened the venv in PowerShell. The solution then proposes to use the following line:
https://bootstrap.pypa.io/get-pip.py | python
This, however, gives me another error as follows:
curl : The request was aborted: Could not create SSL/TLS secure channel.
At line:1 char:1
+ curl https://bootstrap.pypa.io/get-pip.py | python
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
eption
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
I can not find any further solutions that can help me with this. If someone can help with a next step, that would be greatly appreciated. Thanks in advance.
Update
I reinstalled python and everything fixed itself. I guess something broke when installing it the first time.
python curl pycharm ssl-certificate python-venv
New contributor
This is not a powershell issue. It's a curl issue based on the error message you're receiving. No where are powershell features being used in your messages.
– TheIncorrigible1
Dec 27 at 16:02
I understand that, but I have no idea how to fix this curl issue
– Mark Marketing
Dec 27 at 16:16
Just commenting to point you in a better direction and explain the corrected tags.
– TheIncorrigible1
Dec 27 at 16:17
add a comment |
I am trying to get a repository from github to work on my Windows 10 machine. This repository requires a large number of packages. The IDE I use is Pycharm. Within pycharm, one is automatically prompted to install any packages via pip. However, when I press "install packages" or try to install any package individually via pip, the following error appears:
Could not fetch URL https://pypi.org/simple/numpy/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/numpy/ (Caused by SSLError(SSLError(1, '_ssl.c:503: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version'),)) - skipping
When trying to find a solution, I came across this solution. I succesfully opened the venv in PowerShell. The solution then proposes to use the following line:
https://bootstrap.pypa.io/get-pip.py | python
This, however, gives me another error as follows:
curl : The request was aborted: Could not create SSL/TLS secure channel.
At line:1 char:1
+ curl https://bootstrap.pypa.io/get-pip.py | python
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
eption
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
I can not find any further solutions that can help me with this. If someone can help with a next step, that would be greatly appreciated. Thanks in advance.
Update
I reinstalled python and everything fixed itself. I guess something broke when installing it the first time.
python curl pycharm ssl-certificate python-venv
New contributor
I am trying to get a repository from github to work on my Windows 10 machine. This repository requires a large number of packages. The IDE I use is Pycharm. Within pycharm, one is automatically prompted to install any packages via pip. However, when I press "install packages" or try to install any package individually via pip, the following error appears:
Could not fetch URL https://pypi.org/simple/numpy/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/numpy/ (Caused by SSLError(SSLError(1, '_ssl.c:503: error:1407742E:SSL routines:SSL23_GET_SERVER_HELLO:tlsv1 alert protocol version'),)) - skipping
When trying to find a solution, I came across this solution. I succesfully opened the venv in PowerShell. The solution then proposes to use the following line:
https://bootstrap.pypa.io/get-pip.py | python
This, however, gives me another error as follows:
curl : The request was aborted: Could not create SSL/TLS secure channel.
At line:1 char:1
+ curl https://bootstrap.pypa.io/get-pip.py | python
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
eption
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
I can not find any further solutions that can help me with this. If someone can help with a next step, that would be greatly appreciated. Thanks in advance.
Update
I reinstalled python and everything fixed itself. I guess something broke when installing it the first time.
python curl pycharm ssl-certificate python-venv
python curl pycharm ssl-certificate python-venv
New contributor
New contributor
edited Dec 27 at 19:20
New contributor
asked Dec 27 at 13:22
Mark Marketing
203
203
New contributor
New contributor
This is not a powershell issue. It's a curl issue based on the error message you're receiving. No where are powershell features being used in your messages.
– TheIncorrigible1
Dec 27 at 16:02
I understand that, but I have no idea how to fix this curl issue
– Mark Marketing
Dec 27 at 16:16
Just commenting to point you in a better direction and explain the corrected tags.
– TheIncorrigible1
Dec 27 at 16:17
add a comment |
This is not a powershell issue. It's a curl issue based on the error message you're receiving. No where are powershell features being used in your messages.
– TheIncorrigible1
Dec 27 at 16:02
I understand that, but I have no idea how to fix this curl issue
– Mark Marketing
Dec 27 at 16:16
Just commenting to point you in a better direction and explain the corrected tags.
– TheIncorrigible1
Dec 27 at 16:17
This is not a powershell issue. It's a curl issue based on the error message you're receiving. No where are powershell features being used in your messages.
– TheIncorrigible1
Dec 27 at 16:02
This is not a powershell issue. It's a curl issue based on the error message you're receiving. No where are powershell features being used in your messages.
– TheIncorrigible1
Dec 27 at 16:02
I understand that, but I have no idea how to fix this curl issue
– Mark Marketing
Dec 27 at 16:16
I understand that, but I have no idea how to fix this curl issue
– Mark Marketing
Dec 27 at 16:16
Just commenting to point you in a better direction and explain the corrected tags.
– TheIncorrigible1
Dec 27 at 16:17
Just commenting to point you in a better direction and explain the corrected tags.
– TheIncorrigible1
Dec 27 at 16:17
add a comment |
1 Answer
1
active
oldest
votes
This seems like it is an issue with Powershell downloading the package.
Try:
- downloading get-pip.py via your web browser
- navigating in Powershell to the directory you downloaded get-pip.py to
running;
python get-pip.py
This should install pip. If you can't download packages via pip once installed it is likely there is either a connection issue between you and pypi.org or between powershell and your outgoing connection.
I will look into this right now
– Mark Marketing
Dec 27 at 13:35
Do you by any chance know where exactly this should be downloaded?
– Mark Marketing
Dec 27 at 13:37
bootstrap.pypa.io/get-pip.py - you had the link in your question :)
– M. Davis
Dec 27 at 13:38
Ok, I downloaded the file by just copy pasting the text into a python file. However, when I execute it from powershell, I get the following error (repeated 5-6 times): c:usersmarket~1appdatalocaltemptmpclgooopip.zippip_vendorurllib3utilssl_.py:160: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see urllib3.readthedocs.io/en/latest/…
– Mark Marketing
Dec 27 at 13:49
I am using python 2.7, by the way. As the repository has not been updated to work with python 3.
– Mark Marketing
Dec 27 at 13:50
|
show 4 more comments
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Mark Marketing is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53945806%2fpython-cant-install-packages-in-venv-via-powershell%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
This seems like it is an issue with Powershell downloading the package.
Try:
- downloading get-pip.py via your web browser
- navigating in Powershell to the directory you downloaded get-pip.py to
running;
python get-pip.py
This should install pip. If you can't download packages via pip once installed it is likely there is either a connection issue between you and pypi.org or between powershell and your outgoing connection.
I will look into this right now
– Mark Marketing
Dec 27 at 13:35
Do you by any chance know where exactly this should be downloaded?
– Mark Marketing
Dec 27 at 13:37
bootstrap.pypa.io/get-pip.py - you had the link in your question :)
– M. Davis
Dec 27 at 13:38
Ok, I downloaded the file by just copy pasting the text into a python file. However, when I execute it from powershell, I get the following error (repeated 5-6 times): c:usersmarket~1appdatalocaltemptmpclgooopip.zippip_vendorurllib3utilssl_.py:160: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see urllib3.readthedocs.io/en/latest/…
– Mark Marketing
Dec 27 at 13:49
I am using python 2.7, by the way. As the repository has not been updated to work with python 3.
– Mark Marketing
Dec 27 at 13:50
|
show 4 more comments
This seems like it is an issue with Powershell downloading the package.
Try:
- downloading get-pip.py via your web browser
- navigating in Powershell to the directory you downloaded get-pip.py to
running;
python get-pip.py
This should install pip. If you can't download packages via pip once installed it is likely there is either a connection issue between you and pypi.org or between powershell and your outgoing connection.
I will look into this right now
– Mark Marketing
Dec 27 at 13:35
Do you by any chance know where exactly this should be downloaded?
– Mark Marketing
Dec 27 at 13:37
bootstrap.pypa.io/get-pip.py - you had the link in your question :)
– M. Davis
Dec 27 at 13:38
Ok, I downloaded the file by just copy pasting the text into a python file. However, when I execute it from powershell, I get the following error (repeated 5-6 times): c:usersmarket~1appdatalocaltemptmpclgooopip.zippip_vendorurllib3utilssl_.py:160: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see urllib3.readthedocs.io/en/latest/…
– Mark Marketing
Dec 27 at 13:49
I am using python 2.7, by the way. As the repository has not been updated to work with python 3.
– Mark Marketing
Dec 27 at 13:50
|
show 4 more comments
This seems like it is an issue with Powershell downloading the package.
Try:
- downloading get-pip.py via your web browser
- navigating in Powershell to the directory you downloaded get-pip.py to
running;
python get-pip.py
This should install pip. If you can't download packages via pip once installed it is likely there is either a connection issue between you and pypi.org or between powershell and your outgoing connection.
This seems like it is an issue with Powershell downloading the package.
Try:
- downloading get-pip.py via your web browser
- navigating in Powershell to the directory you downloaded get-pip.py to
running;
python get-pip.py
This should install pip. If you can't download packages via pip once installed it is likely there is either a connection issue between you and pypi.org or between powershell and your outgoing connection.
answered Dec 27 at 13:28
M. Davis
567
567
I will look into this right now
– Mark Marketing
Dec 27 at 13:35
Do you by any chance know where exactly this should be downloaded?
– Mark Marketing
Dec 27 at 13:37
bootstrap.pypa.io/get-pip.py - you had the link in your question :)
– M. Davis
Dec 27 at 13:38
Ok, I downloaded the file by just copy pasting the text into a python file. However, when I execute it from powershell, I get the following error (repeated 5-6 times): c:usersmarket~1appdatalocaltemptmpclgooopip.zippip_vendorurllib3utilssl_.py:160: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see urllib3.readthedocs.io/en/latest/…
– Mark Marketing
Dec 27 at 13:49
I am using python 2.7, by the way. As the repository has not been updated to work with python 3.
– Mark Marketing
Dec 27 at 13:50
|
show 4 more comments
I will look into this right now
– Mark Marketing
Dec 27 at 13:35
Do you by any chance know where exactly this should be downloaded?
– Mark Marketing
Dec 27 at 13:37
bootstrap.pypa.io/get-pip.py - you had the link in your question :)
– M. Davis
Dec 27 at 13:38
Ok, I downloaded the file by just copy pasting the text into a python file. However, when I execute it from powershell, I get the following error (repeated 5-6 times): c:usersmarket~1appdatalocaltemptmpclgooopip.zippip_vendorurllib3utilssl_.py:160: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see urllib3.readthedocs.io/en/latest/…
– Mark Marketing
Dec 27 at 13:49
I am using python 2.7, by the way. As the repository has not been updated to work with python 3.
– Mark Marketing
Dec 27 at 13:50
I will look into this right now
– Mark Marketing
Dec 27 at 13:35
I will look into this right now
– Mark Marketing
Dec 27 at 13:35
Do you by any chance know where exactly this should be downloaded?
– Mark Marketing
Dec 27 at 13:37
Do you by any chance know where exactly this should be downloaded?
– Mark Marketing
Dec 27 at 13:37
bootstrap.pypa.io/get-pip.py - you had the link in your question :)
– M. Davis
Dec 27 at 13:38
bootstrap.pypa.io/get-pip.py - you had the link in your question :)
– M. Davis
Dec 27 at 13:38
Ok, I downloaded the file by just copy pasting the text into a python file. However, when I execute it from powershell, I get the following error (repeated 5-6 times): c:usersmarket~1appdatalocaltemptmpclgooopip.zippip_vendorurllib3utilssl_.py:160: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see urllib3.readthedocs.io/en/latest/…
– Mark Marketing
Dec 27 at 13:49
Ok, I downloaded the file by just copy pasting the text into a python file. However, when I execute it from powershell, I get the following error (repeated 5-6 times): c:usersmarket~1appdatalocaltemptmpclgooopip.zippip_vendorurllib3utilssl_.py:160: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. You can upgrade to a newer version of Python to solve this. For more information, see urllib3.readthedocs.io/en/latest/…
– Mark Marketing
Dec 27 at 13:49
I am using python 2.7, by the way. As the repository has not been updated to work with python 3.
– Mark Marketing
Dec 27 at 13:50
I am using python 2.7, by the way. As the repository has not been updated to work with python 3.
– Mark Marketing
Dec 27 at 13:50
|
show 4 more comments
Mark Marketing is a new contributor. Be nice, and check out our Code of Conduct.
Mark Marketing is a new contributor. Be nice, and check out our Code of Conduct.
Mark Marketing is a new contributor. Be nice, and check out our Code of Conduct.
Mark Marketing is a new contributor. Be nice, and check out our Code of Conduct.
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53945806%2fpython-cant-install-packages-in-venv-via-powershell%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
This is not a powershell issue. It's a curl issue based on the error message you're receiving. No where are powershell features being used in your messages.
– TheIncorrigible1
Dec 27 at 16:02
I understand that, but I have no idea how to fix this curl issue
– Mark Marketing
Dec 27 at 16:16
Just commenting to point you in a better direction and explain the corrected tags.
– TheIncorrigible1
Dec 27 at 16:17