-
Notifications
You must be signed in to change notification settings - Fork 19
Description
Is there an existing issue for this?
- I have searched the existing issues and added correct labels.
Description
Current Behavior
The Kitsu Sync action fails during pairing checks. The code in
server/kitsu/init_pairing.py
attempts to access the result of Postgres.iterate using a tuple index (res[0]), which raises an error because the returned object is dictionary-like (likely an asyncpg.Record) and relies on column names.
Expected Behavior
The pairing process should complete successfully. To fix this, the SQL query should alias the selected column (e.g., as kitsu_project_id), and the code should access the value by this key (e.g., res["kitsu_project_id"]) instead of using a numeric index.
Steps To Reproduce:
Install/configure the Kitsu addon (version 1.2.6).
Press the sync button.
server logs report an unhandled exception:
Unhandled exception: KeyError: 0 Traceback KeyError: 0 ayon_server/api/logging.py:124 response = await call_next(request) /addons/kitsu/1.2.6beta/server/__init__.py:66 await sync_request(project_name, user) /addons/kitsu/1.2.6beta/server/kitsu/init_pairing.py:57 kitsu_project_id = res[0]
Additional context:
Version
server 1.13.6
core 1.6.9
kitsu v1.2.6
What platform were you running when you found the bug?
Windows
Relevant log output:
Unhandled exception: KeyError: 0 Traceback KeyError: 0 ayon_server/api/logging.py:124 response = await call_next(request) /addons/kitsu/1.2.6beta/server/__init__.py:66 await sync_request(project_name, user) /addons/kitsu/1.2.6beta/server/kitsu/init_pairing.py:57 kitsu_project_id = res[0]