You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
How can I drill down in to the error to figure out what is going on. The API works and then all of a sudden I see this error in the logs. I'm trying to figure out if it's my code or not.
Thanks,
[2023-07-25 09:31:54 -0700] [5810] [ERROR] Error handling request /api/xstate/bulk Traceback (most recent call last): File "/opt/theFairy/env/api/lib/python3.9/site-packages/gunicorn/workers/base_async.py", line 41, in handle self.handle_request(listener_name, req, client, addr) File "/opt/theFairy/env/api/lib/python3.9/site-packages/gunicorn/workers/ggevent.py", line 127, in handle_request super().handle_request(listener_name, req, sock, addr) File "/opt/theFairy/env/api/lib/python3.9/site-packages/gunicorn/workers/base_async.py", line 108, in handle_request respiter = self.wsgi(environ, resp.start_response) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 2548, in __call__ return self.wsgi_app(environ, start_response) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 2528, in wsgi_app response = self.handle_exception(e) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask_cors/extension.py", line 165, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 2525, in wsgi_app response = self.full_dispatch_request() File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 1822, in full_dispatch_request rv = self.handle_user_exception(e) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask_cors/extension.py", line 165, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 1820, in full_dispatch_request rv = self.dispatch_request() File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 1796, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args) File "/opt/theFairy/env/api/lib/python3.9/site-packages/apifairy/decorators.py", line 96, in _response raise RuntimeError( RuntimeError: The @response decorator cannot handle Response objects.
The text was updated successfully, but these errors were encountered:
The @response decorator cannot handle Response objects.
Fix your endpoint so that it returns the object referenced in the @response decorator to address this problem. Returning a Response object from Flask is not supported because that makes it impossible to do serialization with your Marshmallow schema.
Hello,
How can I drill down in to the error to figure out what is going on. The API works and then all of a sudden I see this error in the logs. I'm trying to figure out if it's my code or not.
Thanks,
[2023-07-25 09:31:54 -0700] [5810] [ERROR] Error handling request /api/xstate/bulk Traceback (most recent call last): File "/opt/theFairy/env/api/lib/python3.9/site-packages/gunicorn/workers/base_async.py", line 41, in handle self.handle_request(listener_name, req, client, addr) File "/opt/theFairy/env/api/lib/python3.9/site-packages/gunicorn/workers/ggevent.py", line 127, in handle_request super().handle_request(listener_name, req, sock, addr) File "/opt/theFairy/env/api/lib/python3.9/site-packages/gunicorn/workers/base_async.py", line 108, in handle_request respiter = self.wsgi(environ, resp.start_response) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 2548, in __call__ return self.wsgi_app(environ, start_response) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 2528, in wsgi_app response = self.handle_exception(e) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask_cors/extension.py", line 165, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 2525, in wsgi_app response = self.full_dispatch_request() File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 1822, in full_dispatch_request rv = self.handle_user_exception(e) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask_cors/extension.py", line 165, in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 1820, in full_dispatch_request rv = self.dispatch_request() File "/opt/theFairy/env/api/lib/python3.9/site-packages/flask/app.py", line 1796, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args) File "/opt/theFairy/env/api/lib/python3.9/site-packages/apifairy/decorators.py", line 96, in _response raise RuntimeError( RuntimeError: The @response decorator cannot handle Response objects.
The text was updated successfully, but these errors were encountered: