V
V
Vladimir Ermak2020-11-08 23:48:09
Python
Vladimir Ermak, 2020-11-08 23:48:09

How to fix SSL error in VS code in Python?

I began to switch to VS Code and, in order to properly deal with it, I decided to write a small project on it. I won’t go into details, but I’ll just say that this is a VK bot.
As a result, I wrote several lines of importing the necessary libraries, saw an error that there was no vk_api library, and without thinking twice I wrote:

pip install vk_api

Received in response:
Could not fetch URL https://pypi.python.org/simple/vk-api/ : There was a problem confirming the ssl certificate: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:661) - skipping


I looked around the sites in the search engine and did not find a suitable answer, and if I did, it did not help.

VS Code version: 1.49.2
Python version that I use in VS Code: 3.6.4
MacOs version: 10.13.6 Tell me

how to fix it, I will be very grateful

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey Karbivnichy, 2020-11-08
@Kopheek

Tried this:

brew uninstall openssl
brew update && brew upgrade && brew cleanup && brew doctor
brew install openssl

Perhaps the device still has python2, then try this:
pip3 install vk_api
Looked here - How Do I Install pip on macOS or OS X? ?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question