I have a VPS running a fresh install of Ubuntu 10.04 LTS. I\'m trying to set up a live application using the Flask microframework, but it\'s giving me trouble. I took notes whil
Edit line sys.path.append
, it needs to be a string.
import sys
sys.path.append('directory/where/package/is/located')
Notice the single quotes.
Obviously, it cannot find your "myapp
" package. You should add it to the path in your myapp.wsgi
file like this:
import sys
sys.path.append(DIRECTORY_WHERE_YOUR_PACKAGE_IS_LOCATED)
from myapp import app
Also, if myapp
module is a package, you should put and empty __init__.py
file into its directory.