I’m outgrowing the Flask development server for my new Dash project and working on getting it going on a WSGI server. Gunicorn is out since I’m on a Windows machine, so trying to get Gevent working. Here is what I have so far to work with:
app = dash.Dash(__name__) app.title='Runtime Information' app.scripts.config.serve_locally=True app.config['suppress_callback_exceptions'] = True app.layout= #some stuff
And I’m trying to call it with
from gevent.pywsgi import WSGIServer from testerApp import app as application http_server=WSGIServer(('0.0.0.0',80),application) http_server.serve_forever()
Getting the following traceback:
Traceback (most recent call last): File "C:\Python27\lib\site-packages\gevent\pywsgi.py", line 975, in handle_one_response self.run_application() File "C:\Python27\lib\site-packages\gevent\pywsgi.py", line 922, in run_application self.result = self.application(self.environ, self.start_response) TypeError: 'Dash' object is not callable
Running this from Python 2.7.15 as some of the modules referenced by my program have not been update to Python 3 yet. Can anybody give me some advice on where I’m going wrong?