getsentry / raven-python

Raven is the legacy Python client for Sentry (getsentry.com) — replaced by sentry-python
https://sentry.io
BSD 3-Clause "New" or "Revised" License
1.68k stars 657 forks source link

Issues with namespace packages #422

Open dcramer opened 10 years ago

dcramer commented 10 years ago

Quoting a user here:

I have a Pyramid web app which is inside a namespace package. If I add this package to include_paths, I get the following error in case of an exception:

return get_versions(self.include_paths) 
File "/.../raven-4.0.4-py2.7.egg/raven/utils/__init__.py", line 99, in get_versions 
__import__(module_name) 
ValueError: Empty module name

If I leave include_paths empty no exception from that module is logged. Exceptions raised in other modules are send to Sentry, so it looks to me as namespace packages are ignored or cannot be handled.

AvnerCohen commented 6 years ago

4 years later.. Setting empty include_paths seems to resolve this issue. It's not perfect and might bring some other noise, but atleast it does not hide exception stack.