I've encountered issues with autoreload when running a module within a package. (python -m package.module <port>)
I've written an SSCCE which demonstrates this. I expected to get the response "Hello World!", but instead I got:
<type 'exceptions.ImportError'> at /
No module named mymodule
SSCCE follows below.
myapp/init.py is empty.
return "Hello world!"
urls = (
if __name__ == "__main__":
app = web.application(urls, globals())
python -m myapp.mymodule <port>
Any of the following seem to work:
Forgot to mention (although it may be obvious to most): the error occurs not when starting the above program, but when accessing it through a browser. The error appears browser-side.