pip throws “TypeError: deprecated() ” error

Something got broken down in OpenSSL and no command was working with pip afterwards. I was even unable uninstall pip. I removed installation files manually (most likely not a recommended approach) with sudo rm -rf /usr/local/lib/python3.8/dist-packages/OpenSSL sudo rm -rf /usr/local/lib/python3.8/dist-packages/pyOpenSSL-22.1.0.dist-info/ and reinstalled using pip3 install pyOpenSSL==22.0.0. The other version was having some issue as described … Read more

Python 3.3 and Installing PyOpenSSL on a Mac

Here’s how you can install pyOpenSSL on OS X (or just about any other platform): Install pip Install it using a package for your operating system. For example, if you use brew, brew install pip. If there is no package for your operating system, download https://raw.github.com/pypa/pip/master/contrib/get-pip.py Run it (probably as root, unfortunately): sudo python get-pip.py … Read more

HTTPS connection Python

Python 2.x: docs.python.org/2/library/httplib.html: Note: HTTPS support is only available if the socket module was compiled with SSL support. Python 3.x: docs.python.org/3/library/http.client.html: Note HTTPS support is only available if Python was compiled with SSL support (through the ssl module). #!/usr/bin/env python import httplib c = httplib.HTTPSConnection(“ccc.de”) c.request(“GET”, “https://stackoverflow.com/”) response = c.getresponse() print response.status, response.reason data = … Read more