#1
by
Stefano
When I create a room in OTAI, I get the error below when I put the labels. OTAI indicates "this is a bug in the oTree server version running on your site. It's not something in your app code I can fix. Could you please ask Otai Jr (click the link beneath the text input) about this error — it's an IT/deployment issue related to the oTree version on your server. They may need to update the server or apply a patch."
TypeError: Argument 'query_params' has incorrect type (expected dict, got QueryParams)
https://stefano.on.otree.org/room/Room?participant_label=Stefano
Traceback (most recent call last):
File "otree/errorpage.py", line 276, in otree.errorpage.OTreeServerErrorMiddleware.__call__
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/middleware/base.py", line 25, in __call__
response = await self.dispatch_func(request, self.call_next)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "otree/middleware.py", line 59, in dispatch
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/middleware/base.py", line 45, in call_next
task.result()
~~~~~~~~~~~^^
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/middleware/base.py", line 38, in coro
await self.app(scope, receive, send)
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/middleware/sessions.py", line 75, in __call__
await self.app(scope, receive, send_wrapper)
File "otree/patch.py", line 44, in __call__
File "otree/patch.py", line 32, in otree.patch.ExceptionMiddleware.__call__
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/routing.py", line 582, in __call__
await route.handle(scope, receive, send)
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/routing.py", line 243, in handle
await self.app(scope, receive, send)
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/endpoints.py", line 32, in dispatch
response = await run_in_threadpool(handler, request)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/otree-envs/otree-6.0.78/lib/python3.13/site-packages/starlette/concurrency.py", line 40, in run_in_threadpool
return await loop.run_in_executor(None, func, *args)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.13/concurrent/futures/thread.py", line 59, in run
result = self.fn(*self.args, **self.kwargs)
File "otree/views/participant.py", line 336, in otree.views.participant.AssignVisitorToRoom.get
TypeError: Argument 'query_params' has incorrect type (expected dict, got QueryParams)