bz2 ModuleNotFoundError
This error means that you have missing bz2
headers (probably because you’ve built python from sources without this option enabled), so you need to install them first (for Ubuntu/Debian):
1 | $ sudo apt-get install libbz2-dev |
Now we need to reconfigure your python and reinstall it once again (version 3.6.5
for example below)
1 | $ tar -xvf Python-3.6.5.tar.xz |
Check whether it works properly now
1 | $ python3.6 -c "import bz2" |
should return without any errors. And make sure to recreate your virtual environment which will use new python executable
1 | $ pipenv --python 3.6.5 |
You should be all set up now, continue the adventure!