How to fix "ModuleNotFoundError: No module named _bz2"

13 views
Skip to first unread message

KEVIN THOMAS

unread,
Aug 26, 2021, 6:26:17 PMAug 26
to oppi...@googlegroups.com
Hi Oppia Devs,

Just wanted to share a fix for an issue I faced recently in case any one else is running into the same error.

If you see the error "ModuleNotFoundError: No module named _bz2":

ModuleNotFoundError_bz2.png

Do this:
1. Install bz2 headers. Use the command "sudo apt-get install libbz2-dev" on Ubuntu.
2. Install Python 3 again so that the bz2 library gets included in "~/.pyenv/versions/3.7.10/lib/python3.7/". Use the command "pyenv install 3.7.10".

Thanks,
Kevin

Sajal Asati

unread,
Aug 28, 2021, 3:53:27 PMAug 28
to oppia-dev
Thanks Kevin for sharing! I was facing this problem, and was managing with it somehow for a while, but resolved now :)
Reply all
Reply to author
Forward
0 new messages