I am trying to deploy my Twisted application using .tac files and twistd
I tried to deploy it with the command line:
twistd -y service.tac
I have the error:
...
application = getApplication(self.config, passphrase)
--- <exception caught here> ---
File "/usr/local/lib/python2.7/dist-packages/twisted/application/app.py", line 450, in getApplication
application = service.loadApplication(filename, style, passphrase)
File "/usr/local/lib/python2.7/dist-packages/twisted/application/service.py", line 411, in loadApplication
passphrase)
File "/usr/local/lib/python2.7/dist-packages/twisted/persisted/sob.py", line 224, in loadValueFromFile
eval(codeObj, d, d)
File "service.tac", line 54, in <module>
File "/usr/lib/python2.7/posixpath.py", line 61, in isabs
return s.startswith('/')
exceptions.AttributeError: 'NoneType' object has no attribute 'startswith'
Failed to load application: 'NoneType' object has no attribute 'startswith'
My service.tac file is:
from flask import Flask
app = Flask(__name__)