Change pip package dependency lists and install from local source with Python 3.6

When installing a Python 3 package with Pip, if the package to be installed calls for a dependency that is outdated or otherwise not available, you can get a local copy of the module, change its dependency lists, then install it from the local source.

This will likely be no big deal for the Python wizards out there, but it was a pretty nice victory for me, so I thought I'd better share in case someone else has the same trouble.

I was attempting to install the lastpass-python module:

pip install lastpass-python

This was failing, due to a requirement for the PyCrypto module as a dependency for lastpass-python.

pip failed building wheel for pycrypto

A quick Google search pointed out that the PyCrypto project is dead, with PyCryptodome available as a new, drop-in replacement.

I cloned the lastpass-python code to a local folder, and then modified both the setup.py and requirements.txt files (Change pycrypto==2.6.1 to pycryptodome==3.4.5 in both places).

I chose version 3.4.5, because it appears that's the most current release version of pycryptodome.

With those changes in place, I pointed pip to my local lastpass-python folder.

pip install -e /c/pythonmodules/lastpass-python

Everything installed without error this time!

Tags

Comments

Filtered HTML

  • Web page addresses and email addresses turn into links automatically.
  • Allowed HTML tags: <a href hreflang> <em> <strong> <cite> <blockquote cite> <code> <ul type> <ol start type> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.