slack-emojinator icon indicating copy to clipboard operation
slack-emojinator copied to clipboard

lxml 4.1.0 from Pipfile.lock not compatible with Python 3.7 or above

Open chief-tyrol opened this issue 4 years ago • 2 comments

Was scratching my head over this issue for a while, so documenting it to benefit others.

The current version of lxml in Pipfile.lock (4.1.0) was released on 2017-10-13, and doesn't appear to be compatible with Python versions 3.7 or newer.

Minimal example showing the issue

Succeeds

git clone [email protected]:smashwilson/slack-emojinator.git
cd slack-emojinator/
docker run --rm -w=/workdir -v "$(pwd)":/workdir python:3.6 sh -c 'pip install pipenv; pipenv install'

Fails

git clone [email protected]:smashwilson/slack-emojinator.git
cd slack-emojinator/
docker run --rm -w=/workdir -v "$(pwd)":/workdir python:3.7 sh -c 'pip install pipenv; pipenv install'

(I also tried with Python 3.8, and got the same error)

I've attached the output of the failing example here: error_log.txt

Suggested Remediation

Short term, just making a note in the README that Python 3.6 is required is probably sufficient, long term upgrading lxml would likely fix the issue

chief-tyrol avatar Nov 17 '19 02:11 chief-tyrol

I was able to workaround this issue by specifying the python version as a pipenv option argument:

pipenv --python 3.6.9 install

drew-beres avatar Nov 19 '19 16:11 drew-beres

Thanks guys this was helpful. I'm on 3.7.5 on Mac and don't want to mess with python versions..(even with pipenv!?) I changed the Pipfile line with the lxml version to this: lxml = ">4.4." And I ran the script and it worked.

payamazadi avatar Nov 19 '19 16:11 payamazadi