LibraryOfCongress / bagit-python

Work with BagIt packages from Python.
http://libraryofcongress.github.io/bagit-python
216 stars 85 forks source link

failed installation of bagit #114

Closed laurensorensen closed 5 years ago

laurensorensen commented 5 years ago

Hi there! I tried installing bagit using the instructions in the readme and am getting an error. I'm copy/pasting the error below... any help is appreciated.

I'm running macOS high sierra, 10.13.6, just installed Python, 2.7.13.

Here is the text from terminal: pip install bagit Collecting bagit Could not fetch URL https://pypi.python.org/simple/bagit/: There was a problem confirming the ssl certificate: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:661) - skipping Could not find a version that satisfies the requirement bagit (from versions: ) No matching distribution found for bagit

kieranjol commented 5 years ago

Can you try upgrading pip (not sure if you'll need sudo or not) pip install -U pip And see if that fixes the issue?

laurensorensen commented 5 years ago

Thanks Kieran! Unfortunately it didn't work.. getting the following, similar message about an SSL certificate. Laurens-MacBook-Air:~ laurensorensen$ pip install -U pip Could not fetch URL https://pypi.python.org/simple/pip/: There was a problem confirming the ssl certificate: [SSL: TLSV1_ALERT_PROTOCOL_VERSION] tlsv1 alert protocol version (_ssl.c:661) - skipping Requirement already up-to-date: pip in /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages`

kieranjol commented 5 years ago

Hopefully someone more knowledgeable will come along,but it looks like its less of a bagit specific issue and more to do with your python environment. Can you try installing something else via pip to see if you get the same error? Like pip install tabview or something? Also 2.7.13 sounds older than the current version of python 2, 2.7.15. I'm assuming that you didn't install via homebrew?

acdha commented 5 years ago

It sounds like your Python install hasn't been updated in long enough that it doesn't support the modern TLS settings used by pypi. I would second the recommendation of using a package manager to avoid this kind of problem in the future but you should be able to bootstrap things using curl https://bootstrap.pypa.io/get-pip.py | python with your existing install.

laurensorensen commented 5 years ago

I worked it out using homebrew package manager. Sorry, I'm rusty -- grateful for your help!