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

打开样例项目报错 #210

Closed
goulin2k opened this issue Nov 14, 2023 · 0 comments
Closed

打开样例项目报错 #210

goulin2k opened this issue Nov 14, 2023 · 0 comments
Labels

Comments

@goulin2k
Copy link

goulin2k commented Nov 14, 2023

终端错误信息如下:
Traceback (most recent call last):
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/_exception_handler.py", line 44, in wrapped_app
await app(scope, receive, sender)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/swagger_ui.py", line 220, in call
await self.router(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/routing.py", line 746, in call
await route.handle(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/routing.py", line 459, in handle
await self.app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/routing.py", line 775, in call
await self.default(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/swagger_ui.py", line 233, in default_fn
await self.app(original_scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/routing.py", line 153, in call
await self.router(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/routing.py", line 746, in call
await route.handle(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/routing.py", line 459, in handle
await self.app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/routing.py", line 746, in call
await route.handle(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/routing.py", line 288, in handle
await self.app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/routing.py", line 47, in call
await self.next_app(original_scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/abstract.py", line 268, in call
return await operation(scope, receive, send)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/security.py", line 95, in call
await self.next_app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/abstract.py", line 268, in call
return await operation(scope, receive, send)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/request_validation.py", line 142, in call
await self.next_app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/abstract.py", line 268, in call
return await operation(scope, receive, send)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/lifespan.py", line 26, in call
await self.next_app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/abstract.py", line 268, in call
return await operation(scope, receive, send)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/context.py", line 25, in call
await self.next_app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/apps/flask.py", line 151, in call
return await self.asgi_app(scope, receive, send)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/a2wsgi/wsgi.py", line 157, in call
return await responder(scope, receive, send)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/a2wsgi/wsgi.py", line 191, in call
await self.loop.run_in_executor(
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/concurrent/futures/thread.py", line 58, in run
result = self.fn(*self.args, **self.kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/a2wsgi/wsgi.py", line 244, in wsgi
for chunk in self.app(environ, start_response):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/flask/app.py", line 2531, in wsgi_app
response = self.handle_exception(e)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/flask_cors/extension.py", line 176, in wrapped_function
return cors_after_request(app.make_response(f(*args, **kwargs)))
^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/flask/app.py", line 2528, in wsgi_app
response = self.full_dispatch_request()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/flask/app.py", line 1825, in full_dispatch_request
rv = self.handle_user_exception(e)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/flask_cors/extension.py", line 176, in wrapped_function
return cors_after_request(app.make_response(f(*args, **kwargs)))
^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/flask/app.py", line 1823, in full_dispatch_request
rv = self.dispatch_request()
^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/flask/app.py", line 1799, in dispatch_request
return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/apps/flask.py", line 68, in call
return self.fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/decorators/main.py", line 134, in wrapper
return decorated_function(request)
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/decorators/response.py", line 171, in wrapper
handler_response = function(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/decorators/parameter.py", line 87, in wrapper
return function(**kwargs)
^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/decorators/main.py", line 123, in wrapper
return function(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/AI-2023/train-tool/PaddleLabel/paddlelabel/api/controller/sample.py", line 167, in load_sample
task_category_id = connexion.request.json.get("task_category_id")
^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'function' object has no attribute 'get'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
result = await app( # type: ignore[func-returns-value]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/uvicorn/middleware/proxy_headers.py", line 78, in call
return await self.app(scope, receive, send)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/main.py", line 483, in call
await self.app(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/connexion/middleware/exceptions.py", line 101, in call
await super().call(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/middleware/exceptions.py", line 62, in call
await wrap_app_handling_exceptions(self.app, conn)(scope, receive, send)
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/starlette/_exception_handler.py", line 63, in wrapped_app
response = await handler(conn, exc)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 2106, in run_sync_in_worker_thread
return await future
^^^^^^^^^^^^
File "/Users/goning/anaconda3/envs/paddlelabel/lib/python3.11/site-packages/anyio/_backends/_asyncio.py", line 833, in run
result = context.run(func, *args)
^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: backend_error() takes 1 positional argument but 2 were given
INFO: 127.0.0.1:51587 - "POST /samples HTTP/1.1" 500 Internal Server Error

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

No branches or pull requests

1 participant