Database traceback on official server
The following traceback was in the server logs.
It was likely related to when an admin reset a user's password, and that user then tried and failed to log in using the game client using the new password. Logging in through the web interface worked.
trosnoth_1 | 2021-04-21 10:42:06,613 [3] Error in queued database function
trosnoth_1 | Traceback (most recent call last):
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/backends/utils.py", line 84, in _execute
trosnoth_1 | return self.cursor.execute(sql, params)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/backends/sqlite3/base.py", line 383, in execute
trosnoth_1 | return Database.Cursor.execute(self, query, params)
trosnoth_1 | sqlite3.IntegrityError: UNIQUE constraint failed: trosnoth_trosnothuser.nick
trosnoth_1 |
trosnoth_1 | The above exception was the direct cause of the following exception:
trosnoth_1 |
trosnoth_1 | Traceback (most recent call last):
trosnoth_1 | File "/opt/trosnoth/trosnoth/server/../../trosnoth/dbqueue.py", line 36, in init
trosnoth_1 | yield fn()
trosnoth_1 | File "/opt/trosnoth/trosnoth/server/../../trosnoth/djangoapp/models.py", line 170, in writeNickToDB
trosnoth_1 | user.save()
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/models/base.py", line 743, in save
trosnoth_1 | self.save_base(using=using, force_insert=force_insert,
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/models/base.py", line 780, in save_base
trosnoth_1 | updated = self._save_table(
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/models/base.py", line 853, in _save_table
trosnoth_1 | updated = self._do_update(base_qs, using, pk_val, values, update_fields,
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/models/base.py", line 903, in _do_update
trosnoth_1 | return filtered._update(values) > 0
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/models/query.py", line 760, in _update
trosnoth_1 | return query.get_compiler(self.db).execute_sql(CURSOR)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/models/sql/compiler.py", line 1471, in execute_sql
trosnoth_1 | cursor = super().execute_sql(result_type)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/models/sql/compiler.py", line 1142, in execute_sql
trosnoth_1 | cursor.execute(sql, params)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/backends/utils.py", line 67, in execute
trosnoth_1 | return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/backends/utils.py", line 76, in _execute_with_wrappers
trosnoth_1 | return executor(sql, params, many, context)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/backends/utils.py", line 84, in _execute
trosnoth_1 | return self.cursor.execute(sql, params)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/utils.py", line 89, in __exit__
trosnoth_1 | raise dj_exc_value.with_traceback(traceback) from exc_value
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/backends/utils.py", line 84, in _execute
trosnoth_1 | return self.cursor.execute(sql, params)
trosnoth_1 | File "/usr/local/lib/python3.9/site-packages/django/db/backends/sqlite3/base.py", line 383, in execute
trosnoth_1 | return Database.Cursor.execute(self, query, params)
trosnoth_1 | django.db.utils.IntegrityError: UNIQUE constraint failed: trosnoth_trosnothuser.nick
trosnoth_1 | 2021-04-21 10:44:02,072 [3] Player 'JohnBot-1' did not notice death