Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flask does not run in bjoern server #57

Closed
linychuo opened this issue Feb 23, 2012 · 3 comments
Closed

flask does not run in bjoern server #57

linychuo opened this issue Feb 23, 2012 · 3 comments
Milestone

Comments

@linychuo
Copy link

hi,when I test app on the bjoern server,console displays below errors

Traceback (most recent call last):
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/app.py", line 1506, in wsgi_app
    response = self.make_response(self.handle_exception(e))
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/app.py", line 1504, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/app.py", line 1264, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/app.py", line 1262, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/app.py", line 1248, in dispatch_request
    return self.view_functionsrule.endpoint
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/helpers.py", line 623, in send_static_file
    return send_from_directory(self.static_folder, filename)
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/helpers.py", line 473, in send_from_directory
    return send_file(filename, conditional=True, **options)
  File "/usr/local/lib/python2.6/dist-packages/Flask-0.8-py2.6.egg/flask/helpers.py", line 385, in send_file
    data = wrap_file(request.environ, file)
  File "/usr/local/lib/python2.6/dist-packages/Werkzeug-0.8.3-py2.6.egg/werkzeug/wsgi.py", line 536, in wrap_file
    return environ.get('wsgi.file_wrapper', FileWrapper)(file, buffer_size)
TypeError: FileWrapper() takes exactly 1 argument (2 given)
@jonashaag
Copy link
Owner

Thanks for the report @linychuo! Apparently bjoern violates the WSGI spec in terms of file_wrapper arguments. I'm working on a fix.

@jonashaag
Copy link
Owner

Note to myself: We can probably re-add bjoern support to klaus once this bug is fixed (posativ/klaus@b1ef0c3)

@jonashaag jonashaag mentioned this issue Jul 1, 2012
@dmr
Copy link

dmr commented Nov 11, 2012

Is there any progress on this?
The simple Flask app works fine on my computer, the error only occurs with static files?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants