Closed Ngoakor12 closed 6 months ago
Looking good, but I'm failing to run tests, not sure where the issue is, here is the error I get:
Traceback (most recent call last):
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/utils.py", line 84, in _execute
return self.cursor.execute(sql, params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
psycopg2.errors.UndefinedTable: relation "core_user" does not exist
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/Users/kingraphaii/Dev/Tilde/backend/manage.py", line 31, in <module>
main()
File "/Users/kingraphaii/Dev/Tilde/backend/manage.py", line 27, in main
execute_from_command_line(sys.argv)
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/__init__.py", line 401, in execute_from_command_line
utility.execute()
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/__init__.py", line 395, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/commands/test.py", line 23, in run_from_argv
super().run_from_argv(argv)
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/base.py", line 330, in run_from_argv
self.execute(*args, **cmd_options)
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/base.py", line 371, in execute
output = self.handle(*args, **options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/commands/test.py", line 53, in handle
failures = test_runner.run_tests(test_labels)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/test/runner.py", line 695, in run_tests
old_config = self.setup_databases(aliases=databases)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/test/runner.py", line 614, in setup_databases
return _setup_databases(
^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/test/utils.py", line 170, in setup_databases
connection.creation.create_test_db(
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/base/creation.py", line 72, in create_test_db
call_command(
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/__init__.py", line 168, in call_command
return command.execute(*args, **defaults)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/base.py", line 371, in execute
output = self.handle(*args, **options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/base.py", line 85, in wrapped
res = handle_func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/commands/migrate.py", line 214, in handle
self.sync_apps(connection, executor.loader.unmigrated_apps)
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/core/management/commands/migrate.py", line 336, in sync_apps
with connection.schema_editor() as editor:
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/base/schema.py", line 115, in __exit__
self.execute(sql)
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/base/schema.py", line 142, in execute
cursor.execute(sql, params)
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/utils.py", line 66, in execute
return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/utils.py", line 75, in _execute_with_wrappers
return executor(sql, params, many, context)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/utils.py", line 79, in _execute
with self.db.wrap_database_errors:
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/utils.py", line 90, in __exit__
raise dj_exc_value.with_traceback(traceback) from exc_value
File "/Users/kingraphaii/Dev/Tilde/backend/venv/lib/python3.11/site-packages/django/db/backends/utils.py", line 84, in _execute
return self.cursor.execute(sql, params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
django.db.utils.ProgrammingError: relation "core_user" does not exist
Same issue and solution mentioned here because the other PR has not been merged yet.
Same issue and solution mentioned here because the other PR has not been merged yet.
Seems to be coming from a recent PR merged into develop, the one on review claims
Related issues: [please specify]
Description:
What are you up to? Fill us in :)
Screenshots/videos
I solemnly swear that: