ModuleNotFoundError: No module named 'better_exceptions.integrations'
sumanthratna opened this issue · 3 comments
sumanthratna commented
Hi @Qix-, sorry to bother you again.
The Django middleware integration still doesn't work because of an error I didn't catch earlier.
Reproduction
Local Editable Install
git clone --depth 1 https://github.com/Qix-/better-exceptions.git
cd better-exceptions
python3 -m pip install -e .
python3 -c "import better_exceptions.integrations"
raises no error!
VCS Install
python3 -m pip install git+https://github.com/Qix-/better-exceptions.git
python3 -c "import better_exceptions.integrations"
raises aModuleNotFoundError
PyPI Install
python3 -m pip install better-exceptions==0.3.1
python3 -c "import better_exceptions.integrations"
raises aModuleNotFoundError
so my guess is that somewhere in setup.py
, package subdirectories are not copied into the wheel (and the source .tar.gz
file on PyPI contains the integrations
directory while the .whl
doesn't)
I think using setuptools.find_packages()
will fix this (or we could hard-code the packages
kwarg). I can try creating a PR but I want to make sure this won't break anything with the PTH file
Environment
- reproduced with Python 3.8.6 (pip version 20.2.1) and Python 3.9.1 (pip version 20.2.3)
- macOS Big Sur version 11.0.1 (20B29)
Qix- commented
Ah yeah this is my fault, I forgot about this.
Python package management is a huge pain :/
Qix- commented
Okay released as 0.3.2, let me know if that fixes it :)
sumanthratna commented
Yup, 97c0b20 fixed the issue. Thanks again!