‘module’ object has no attribute ‘__path__’

If you’re seeing the above error, possibly during a reverse() call, and possibly involving the django.contrib.auth.views.template_detail view, make sure none of your application directories has a file named templatetags.py – Django actually requires this to be be a package/directory.

Oh, and on a more general note: Not forgetting the .pyc files when deleting modules will greatly reduce the time needed to  debug cases like this ;)

One response to “‘module’ object has no attribute ‘__path__’

  1. Thanks for reminding me to check for the templatags.pyc file. That’s exactly what was wrong in my case.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>