TandoorRecipes / recipes

Application for managing recipes, planning meals, building shopping lists and much much more!
https://docs.tandoor.dev
Other
5.54k stars 581 forks source link

FDC ID migration error #2894

Closed mikhail5555 closed 9 months ago

mikhail5555 commented 9 months ago

Solution in https://github.com/TandoorRecipes/recipes/issues/2894#issuecomment-1910826564

Tandoor Version

1.5.10

Setup

Unraid

Reverse Proxy

SWAG

Other

PostgresQL logs

2024-01-20 10:25:13.147 CET [5510] ERROR:  invalid input syntax for type integer: "2345232-cherry"
2024-01-20 10:25:13.147 CET [5510] STATEMENT:  ALTER TABLE "cookbook_food" ALTER COLUMN "fdc_id" TYPE integer USING "fdc_id"::integer

Multiple entries in open-tandoor-data have an non-integer fdc_id: image

So this migration will likely fail for anyone who has (at all) imported open-data

Bug description

On boot, it seems some pre-existing entry in my database is causing a startup error. Rolling back to 1.5.10 seems to 'solve' the startup error.

Please let me know if you need me to dump/share some table for ease of use debugging.

Relevant logs

Traceback (most recent call last):
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 87, in _execute
    return self.cursor.execute(sql)
psycopg2.errors.InvalidTextRepresentation: invalid input syntax for type integer: "2345232-cherry"

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/opt/recipes/manage.py", line 15, in <module>
    execute_from_command_line(sys.argv)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 442, in execute_from_command_line
    utility.execute()
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 436, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 412, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 458, in execute
    output = self.handle(*args, **options)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 106, in wrapper
    res = handle_func(*args, **kwargs)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/commands/migrate.py", line 356, in handle
    post_migrate_state = executor.migrate(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 135, in migrate
    state = self._migrate_all_forwards(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 167, in _migrate_all_forwards
    state = self.apply_migration(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 252, in apply_migration
    state = migration.apply(state, schema_editor)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/migration.py", line 132, in apply
    operation.database_forwards(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/operations/fields.py", line 235, in database_forwards
    schema_editor.alter_field(from_model, from_field, to_field)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py", line 830, in alter_field
    self._alter_field(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/postgresql/schema.py", line 288, in _alter_field
    super()._alter_field(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py", line 1055, in _alter_field
    self.execute(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/postgresql/schema.py", line 48, in execute
    return super().execute(sql, None)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py", line 201, in execute
    cursor.execute(sql, params)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute
    return self._execute_with_wrappers(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers
    return executor(sql, params, many, context)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute
    with self.db.wrap_database_errors:
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__
    raise dj_exc_value.with_traceback(traceback) from exc_value
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 87, in _execute
    return self.cursor.execute(sql)
django.db.utils.DataError: invalid input syntax for type integer: "2345232-cherry"

[2024-01-20 10:27:49 +0100] [1] [INFO] Starting gunicorn 20.1.0
[2024-01-20 10:27:49 +0100] [1] [INFO] Listening at: http://0.0.0.0:8080 (1)
[2024-01-20 10:27:49 +0100] [1] [INFO] Using worker: gthread
[2024-01-20 10:27:49 +0100] [12] [INFO] Booting worker with pid: 12
[2024-01-20 10:27:49 +0100] [13] [INFO] Booting worker with pid: 13
[2024-01-20 10:27:49 +0100] [14] [INFO] Booting worker with pid: 14
vabene1111 commented 9 months ago

interesting I thought I had fixed this specific issue. need to look again.

vabene1111 commented 9 months ago

this is very very strange. @nicedevil007 and @Mikhail5555 you both are 100% sure that if you update to 1.5.11 this error appears and that rolling back to 1.5.10 its broken?

Because I thought 1.5.10 was broken and I fixed it in 1.5.11. And I just prepared two databases, one postgres one sqlite, added the 2345232-cherry food and migrated from 1.5.10 to 1.5.11

vabene1111 commented 9 months ago

ok so looking at this again, you should have had this issue already when you upgraded to 1.5.10 but maybe you did not notice. Can you provide the logs of the container starting up where it says "Running migrations:" (on version 1.5.10)

mikhail5555 commented 9 months ago

you are right. in version 1.5.10 the same error is happening:

Checking configuration...
Waiting for database to be ready...
Database is ready
Migrating database
Operations to perform:
  Apply all migrations: account, admin, auth, authtoken, contenttypes, cookbook, oauth2_provider, sessions, sites, socialaccount
Running migrations:
Traceback (most recent call last):
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 87, in _execute
    return self.cursor.execute(sql)
psycopg2.errors.InvalidTextRepresentation: invalid input syntax for type integer: "2345232-cherry"

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/opt/recipes/manage.py", line 15, in <module>
    execute_from_command_line(sys.argv)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 442, in execute_from_command_line
    utility.execute()
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 436, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 412, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 458, in execute
    output = self.handle(*args, **options)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 106, in wrapper
    res = handle_func(*args, **kwargs)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/commands/migrate.py", line 356, in handle
    post_migrate_state = executor.migrate(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 135, in migrate
    state = self._migrate_all_forwards(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 167, in _migrate_all_forwards
    state = self.apply_migration(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 252, in apply_migration
    state = migration.apply(state, schema_editor)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/migration.py", line 132, in apply
    operation.database_forwards(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/operations/fields.py", line 235, in database_forwards
    schema_editor.alter_field(from_model, from_field, to_field)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py", line 830, in alter_field
    self._alter_field(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/postgresql/schema.py", line 288, in _alter_field
    super()._alter_field(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py", line 1055, in _alter_field
    self.execute(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/postgresql/schema.py", line 48, in execute
    return super().execute(sql, None)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/base/schema.py", line 201, in execute
    cursor.execute(sql, params)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute
    return self._execute_with_wrappers(
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers
    return executor(sql, params, many, context)
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute
    with self.db.wrap_database_errors:
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__
    raise dj_exc_value.with_traceback(traceback) from exc_value
  File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 87, in _execute
    return self.cursor.execute(sql)
django.db.utils.DataError: invalid input syntax for type integer: "2345232-cherry"

  Applying cookbook.0205_alter_food_fdc_id_alter_propertytype_fdc_id...Generating static files
js-reverse file written to /opt/recipes/cookbook/static/django_js_reverse

1 static file copied to '/opt/recipes/staticfiles', 647 unmodified, 1396 post-processed.
Done
[2024-01-23 19:45:40 +0100] [1] [INFO] Starting gunicorn 20.1.0
[2024-01-23 19:45:40 +0100] [1] [INFO] Listening at: http://0.0.0.0:8080 (1)
[2024-01-23 19:45:40 +0100] [1] [INFO] Using worker: gthread
[2024-01-23 19:45:40 +0100] [11] [INFO] Booting worker with pid: 11
[2024-01-23 19:45:40 +0100] [12] [INFO] Booting worker with pid: 12
[2024-01-23 19:45:41 +0100] [13] [INFO] Booting worker with pid: 13

I also checked the database, and the last migration in it is 0204_propertytype_fdc_id

vabene1111 commented 9 months ago

ah ok interesting, now I understand. The fix is contained in 0204 but since that ran trough and the issue only appears in 0205 its still broken for people on your upgrade path.

You can try to manage.py migrate cookbook 0203, then upgrade to 1.5.11 and everything should run trough just fine. I will look into if I can move the fix from 0204 to 0205 so that it works for people with your migration path.

mikhail5555 commented 9 months ago
  1. Backup database
  2. Shell into tandoorRecipes docker and execute:
    /opt/recipes # source venv/bin/activate
    (venv) /opt/recipes # ./manage.py migrate cookbook 0203
    Operations to perform:
    Target specific migration: 0203_alter_unique_contstraints, from cookbook
    Running migrations:
    Rendering model states... DONE
    Unapplying cookbook.0204_propertytype_fdc_id... OK
  3. Update docker from 1.15.10 -> 1.15.11

Checking configuration... Waiting for database to be ready... Database is ready Migrating database Operations to perform: Apply all migrations: account, admin, auth, authtoken, contenttypes, cookbook, oauth2_provider, sessions, sites, socialaccount Running migrations: Applying cookbook.0204_propertytype_fdc_id... OK Applying cookbook.0205_alter_food_fdc_id_alter_propertytype_fdc_id... OK Applying cookbook.0206_rename_sticky_navbar_userpreference_nav_sticky_and_more... OK Applying cookbook.0207_space_logo_color_128_space_logo_color_144_and_more... OK Applying cookbook.0208_space_app_name_userpreference_max_owned_spaces... OK Applying socialaccount.0004_app_provider_id_settings... OK Applying socialaccount.0005_socialtoken_nullable_app... OK Applying socialaccount.0006_alter_socialaccount_extra_data... OK Generating static files js-reverse file written to /opt/recipes/cookbook/static/django_js_reverse

649 static files copied to '/opt/recipes/staticfiles', 1705 post-processed. Done [2024-01-25 20:12:37 +0100] [1] [INFO] Starting gunicorn 20.1.0 [2024-01-25 20:12:37 +0100] [1] [INFO] Listening at: http://0.0.0.0:8080 (1) [2024-01-25 20:12:37 +0100] [1] [INFO] Using worker: gthread [2024-01-25 20:12:37 +0100] [12] [INFO] Booting worker with pid: 12 [2024-01-25 20:12:37 +0100] [13] [INFO] Booting worker with pid: 13 [2024-01-25 20:12:37 +0100] [14] [INFO] Booting worker with pid: 14


Seems like everything worked. Thank you @vabene1111
nicedevil007 commented 9 months ago

Confirmed, working for me as well :)

image

wokkieman commented 9 months ago

thanks, go from 1.5.9 to 10, then shell into the container and then update the image to 11 also worked for me.

vabene1111 commented 9 months ago

perfect, thank you. Sorry for the inconvenience, I hade hoped less people would be affected by this issue.

vabene1111 commented 9 months ago

for the next version i moved the fix to migration 0205, that should work for all instances no matter on which version they were before

tugdualenligne commented 9 months ago

Thanks. I corrected issue 2911 following your guidance, and confirms it now works fine

lagset commented 9 months ago

Hey there, I just upgraded to the latest version of the docker image (1.15.2) (setup with Synology Login Portal (=nginx) as reverse proxy) and am now greeted with the same error 500 page.

Help is very much appreciated.

This is the output from the docker-compose up command: ``` ***@***:/volume1/docker/tandoor$ docker-compose up [+] Running 3/3 ⠿ Container tandoor-db_recipes-1 Recreated 3.6s ⠿ Container tandoor-web_recipes-1 Recreated 3.9s ⠿ Container tandoor-web_media-1 Recreated 4.0s Attaching to tandoor-db_recipes-1, tandoor-web_media-1, tandoor-web_recipes-1 tandoor-db_recipes-1 | tandoor-db_recipes-1 | PostgreSQL Database directory appears to contain a database; Skipping initialization tandoor-db_recipes-1 | tandoor-db_recipes-1 | 2024-02-04 11:52:45.058 UTC [1] LOG: starting PostgreSQL 15.5 on x86_64-pc-linux-musl, compiled by gcc (Alpine 13.2.1_git20231014) 13.2.1 20231014, 64-bit tandoor-db_recipes-1 | 2024-02-04 11:52:45.058 UTC [1] LOG: listening on IPv4 address "0.0.0.0", port 5432 tandoor-db_recipes-1 | 2024-02-04 11:52:45.058 UTC [1] LOG: listening on IPv6 address "::", port 5432 tandoor-db_recipes-1 | 2024-02-04 11:52:45.608 UTC [1] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432" tandoor-db_recipes-1 | 2024-02-04 11:52:46.342 UTC [23] LOG: database system was shut down at 2024-02-04 10:28:28 UTC tandoor-db_recipes-1 | 2024-02-04 11:52:46.866 UTC [1] LOG: database system is ready to accept connections tandoor-web_recipes-1 | Checking configuration... tandoor-web_recipes-1 | Waiting for database to be ready... tandoor-web_recipes-1 | Database is ready tandoor-web_recipes-1 | Migrating database tandoor-web_media-1 | /docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration tandoor-web_media-1 | /docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/ tandoor-web_media-1 | /docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh tandoor-web_media-1 | 10-listen-on-ipv6-by-default.sh: info: /etc/nginx/conf.d/default.conf is not a file or does not exist tandoor-web_media-1 | /docker-entrypoint.sh: Sourcing /docker-entrypoint.d/15-local-resolvers.envsh tandoor-web_media-1 | /docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh tandoor-web_media-1 | /docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh tandoor-web_media-1 | /docker-entrypoint.sh: Configuration complete; ready for start up tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: using the "epoll" event method tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: nginx/1.25.3 tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: built by gcc 12.2.1 20220924 (Alpine 12.2.1_git20220924-r10) tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: OS: Linux 4.4.302+ tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576 tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: start worker processes tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: start worker process 20 tandoor-web_media-1 | 2024/02/04 12:52:56 [notice] 1#1: start worker process 21 tandoor-web_recipes-1 | Operations to perform: tandoor-web_recipes-1 | Apply all migrations: account, admin, auth, authtoken, contenttypes, cookbook, oauth2_provider, sessions, sites, socialaccount tandoor-web_recipes-1 | Running migrations: tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/manage.py", line 15, in tandoor-web_recipes-1 | execute_from_command_line(sys.argv) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 442, in execute_from_command_line tandoor-web_recipes-1 | utility.execute() tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 436, in execute tandoor-web_recipes-1 | self.fetch_command(subcommand).run_from_argv(self.argv) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 412, in run_from_argv tandoor-web_recipes-1 | self.execute(*args, **cmd_options) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 458, in execute tandoor-web_recipes-1 | output = self.handle(*args, **options) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/base.py", line 106, in wrapper tandoor-web_recipes-1 | res = handle_func(*args, **kwargs) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/management/commands/migrate.py", line 356, in handle tandoor-web_recipes-1 | post_migrate_state = executor.migrate( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 135, in migrate tandoor-web_recipes-1 | state = self._migrate_all_forwards( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 167, in _migrate_all_forwards tandoor-web_recipes-1 | state = self.apply_migration( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/executor.py", line 252, in apply_migration tandoor-web_recipes-1 | state = migration.apply(state, schema_editor) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/migration.py", line 132, in apply tandoor-web_recipes-1 | operation.database_forwards( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/migrations/operations/special.py", line 193, in database_forwards tandoor-web_recipes-1 | self.code(from_state.apps, schema_editor) tandoor-web_recipes-1 | File "/opt/recipes/cookbook/migrations/0200_alter_propertytype_options_remove_keyword_icon_and_more.py", line 18, in migrate_icons tandoor-web_recipes-1 | raise RuntimeError(f'Duplicate MealTypes found, please remove/rename them and run migrations again/restart the container. {duplicate_meal_types}') tandoor-web_recipes-1 | RuntimeError: Duplicate MealTypes found, please remove/rename them and run migrations again/restart the container. tandoor-web_recipes-1 | Applying cookbook.0200_alter_propertytype_options_remove_keyword_icon_and_more...Generating static files tandoor-web_recipes-1 | js-reverse file written to /opt/recipes/cookbook/static/django_js_reverse tandoor-web_recipes-1 | tandoor-web_recipes-1 | 1 static file copied to '/opt/recipes/staticfiles', 641 unmodified, 1388 post-processed. tandoor-web_recipes-1 | Done tandoor-web_recipes-1 | [2024-02-04 12:53:19 +0100] [1] [INFO] Starting gunicorn 20.1.0 tandoor-web_recipes-1 | [2024-02-04 12:53:19 +0100] [1] [INFO] Listening at: http://[::]:8080 (1) tandoor-web_recipes-1 | [2024-02-04 12:53:19 +0100] [1] [INFO] Using worker: gthread tandoor-web_recipes-1 | [2024-02-04 12:53:19 +0100] [12] [INFO] Booting worker with pid: 12 tandoor-web_recipes-1 | [2024-02-04 12:53:19 +0100] [13] [INFO] Booting worker with pid: 13 tandoor-web_recipes-1 | [2024-02-04 12:53:19 +0100] [14] [INFO] Booting worker with pid: 14 ```
This is the traceback from the debug page when accessing tandoor recipes via browser: ``` Environment: Request Method: GET Request URL: https://tandoor.pensieve.hog.floo/ Django Version: 4.2.7 Python Version: 3.10.13 Installed Applications: ['dal', 'dal_select2', 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.sites', 'django.contrib.staticfiles', 'django.contrib.postgres', 'oauth2_provider', 'django_prometheus', 'django_tables2', 'corsheaders', 'crispy_forms', 'crispy_bootstrap4', 'rest_framework', 'rest_framework.authtoken', 'django_cleanup.apps.CleanupConfig', 'webpack_loader', 'django_js_reverse', 'hcaptcha', 'allauth', 'allauth.account', 'allauth.socialaccount', 'cookbook.apps.CookbookConfig', 'treebeard'] Installed Middleware: ['corsheaders.middleware.CorsMiddleware', 'django.middleware.security.SecurityMiddleware', 'whitenoise.middleware.WhiteNoiseMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.locale.LocaleMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', 'cookbook.helper.scope_middleware.ScopeMiddleware', 'allauth.account.middleware.AccountMiddleware'] Traceback (most recent call last): File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 218, in __get__ rel_obj = self.field.get_cached_value(instance) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/mixins.py", line 15, in get_cached_value return instance._state.fields_cache[cache_name] During handling of the above exception ('space'), another exception occurred: File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute return self.cursor.execute(sql, params) The above exception (column cookbook_space.space_theme does not exist LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... ^ ) was the direct cause of the following exception: File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner response = get_response(request) File "/opt/recipes/cookbook/helper/scope_middleware.py", line 50, in __call__ request.space = user_space.space File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 236, in __get__ rel_obj = self.get_object(instance) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 199, in get_object return qs.get(self.field.get_reverse_related_filter(instance)) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 633, in get num = len(clone) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 380, in __len__ self._fetch_all() File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 1881, in _fetch_all self._result_cache = list(self._iterable_class(self)) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 91, in __iter__ results = compiler.execute_sql( File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/sql/compiler.py", line 1562, in execute_sql cursor.execute(sql, params) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 102, in execute return super().execute(sql, params) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute return self._execute_with_wrappers( File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers return executor(sql, params, many, context) File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute with self.db.wrap_database_errors: File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__ raise dj_exc_value.with_traceback(traceback) from exc_value File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute return self.cursor.execute(sql, params) Exception Type: ProgrammingError at / Exception Value: column cookbook_space.space_theme does not exist LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... ^ ```
This is the log of the docker-compose process when accessing tandoor recipes via browser ``` tandoor-db_recipes-1 | 2024-02-04 11:57:22.063 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.063 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.135 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.135 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.137 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.137 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.139 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.139 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.140 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.140 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.141 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.141 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.143 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.143 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-web_recipes-1 | Internal Server Error: / tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 218, in __get__ tandoor-web_recipes-1 | rel_obj = self.field.get_cached_value(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/mixins.py", line 15, in get_cached_value tandoor-web_recipes-1 | return instance._state.fields_cache[cache_name] tandoor-web_recipes-1 | KeyError: 'space' tandoor-web_recipes-1 | tandoor-web_recipes-1 | During handling of the above exception, another exception occurred: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | psycopg2.errors.UndefinedColumn: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_recipes-1 | tandoor-web_recipes-1 | The above exception was the direct cause of the following exception: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner tandoor-web_recipes-1 | response = get_response(request) tandoor-web_recipes-1 | File "/opt/recipes/cookbook/helper/scope_middleware.py", line 50, in __call__ tandoor-web_recipes-1 | request.space = user_space.space tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 236, in __get__ tandoor-web_recipes-1 | rel_obj = self.get_object(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 199, in get_object tandoor-web_recipes-1 | return qs.get(self.field.get_reverse_related_filter(instance)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 633, in get tandoor-web_recipes-1 | num = len(clone) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 380, in __len__ tandoor-web_recipes-1 | self._fetch_all() tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 1881, in _fetch_all tandoor-web_recipes-1 | self._result_cache = list(self._iterable_class(self)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 91, in __iter__ tandoor-web_recipes-1 | results = compiler.execute_sql( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/sql/compiler.py", line 1562, in execute_sql tandoor-web_recipes-1 | cursor.execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 102, in execute tandoor-web_recipes-1 | return super().execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute tandoor-web_recipes-1 | return self._execute_with_wrappers( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers tandoor-web_recipes-1 | return executor(sql, params, many, context) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute tandoor-web_recipes-1 | with self.db.wrap_database_errors: tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__ tandoor-web_recipes-1 | raise dj_exc_value.with_traceback(traceback) from exc_value tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | django.db.utils.ProgrammingError: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_media-1 | 192.168.32.1 - - [04/Feb/2024:12:57:22 +0100] "GET / HTTP/1.1" 500 144718 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" "192.168.21.101" tandoor-web_recipes-1 | ::ffff:192.168.32.4 - - [04/Feb/2024:12:57:22 +0100] "GET / HTTP/1.0" 500 144718 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" tandoor-db_recipes-1 | 2024-02-04 11:57:22.537 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.537 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.558 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.558 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.560 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.560 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.562 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.562 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.563 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.563 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.565 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.565 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:22.566 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:22.566 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-web_recipes-1 | Internal Server Error: /favicon.ico tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 218, in __get__ tandoor-web_recipes-1 | rel_obj = self.field.get_cached_value(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/mixins.py", line 15, in get_cached_value tandoor-web_recipes-1 | return instance._state.fields_cache[cache_name] tandoor-web_recipes-1 | KeyError: 'space' tandoor-web_recipes-1 | tandoor-web_recipes-1 | During handling of the above exception, another exception occurred: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | psycopg2.errors.UndefinedColumn: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_recipes-1 | tandoor-web_recipes-1 | The above exception was the direct cause of the following exception: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner tandoor-web_recipes-1 | response = get_response(request) tandoor-web_recipes-1 | File "/opt/recipes/cookbook/helper/scope_middleware.py", line 50, in __call__ tandoor-web_recipes-1 | request.space = user_space.space tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 236, in __get__ tandoor-web_recipes-1 | rel_obj = self.get_object(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 199, in get_object tandoor-web_recipes-1 | return qs.get(self.field.get_reverse_related_filter(instance)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 633, in get tandoor-web_recipes-1 | num = len(clone) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 380, in __len__ tandoor-web_recipes-1 | self._fetch_all() tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 1881, in _fetch_all tandoor-web_recipes-1 | self._result_cache = list(self._iterable_class(self)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 91, in __iter__ tandoor-web_recipes-1 | results = compiler.execute_sql( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/sql/compiler.py", line 1562, in execute_sql tandoor-web_recipes-1 | cursor.execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 102, in execute tandoor-web_recipes-1 | return super().execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute tandoor-web_recipes-1 | return self._execute_with_wrappers( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers tandoor-web_recipes-1 | return executor(sql, params, many, context) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute tandoor-web_recipes-1 | with self.db.wrap_database_errors: tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__ tandoor-web_recipes-1 | raise dj_exc_value.with_traceback(traceback) from exc_value tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | django.db.utils.ProgrammingError: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_recipes-1 | ::ffff:192.168.32.4 - - [04/Feb/2024:12:57:22 +0100] "GET /favicon.ico HTTP/1.0" 500 144563 "https://tandoor.pensieve.hog.floo/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" tandoor-web_media-1 | 192.168.32.1 - - [04/Feb/2024:12:57:22 +0100] "GET /favicon.ico HTTP/1.1" 500 144563 "https://tandoor.pensieve.hog.floo/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" "192.168.21.101" tandoor-db_recipes-1 | 2024-02-04 11:57:26.570 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:26.570 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:26.590 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:26.590 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:26.592 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:26.592 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:26.593 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:26.593 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:26.595 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:26.595 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:26.596 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:26.596 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:26.598 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:26.598 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-web_recipes-1 | Internal Server Error: / tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 218, in __get__ tandoor-web_recipes-1 | rel_obj = self.field.get_cached_value(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/mixins.py", line 15, in get_cached_value tandoor-web_recipes-1 | return instance._state.fields_cache[cache_name] tandoor-web_recipes-1 | KeyError: 'space' tandoor-web_recipes-1 | tandoor-web_recipes-1 | During handling of the above exception, another exception occurred: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | psycopg2.errors.UndefinedColumn: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_recipes-1 | tandoor-web_recipes-1 | The above exception was the direct cause of the following exception: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner tandoor-web_recipes-1 | response = get_response(request) tandoor-web_recipes-1 | File "/opt/recipes/cookbook/helper/scope_middleware.py", line 50, in __call__ tandoor-web_recipes-1 | request.space = user_space.space tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 236, in __get__ tandoor-web_recipes-1 | rel_obj = self.get_object(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 199, in get_object tandoor-web_recipes-1 | return qs.get(self.field.get_reverse_related_filter(instance)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 633, in get tandoor-web_recipes-1 | num = len(clone) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 380, in __len__ tandoor-web_recipes-1 | self._fetch_all() tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 1881, in _fetch_all tandoor-web_recipes-1 | self._result_cache = list(self._iterable_class(self)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 91, in __iter__ tandoor-web_recipes-1 | results = compiler.execute_sql( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/sql/compiler.py", line 1562, in execute_sql tandoor-web_recipes-1 | cursor.execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 102, in execute tandoor-web_recipes-1 | return super().execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute tandoor-web_recipes-1 | return self._execute_with_wrappers( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers tandoor-web_recipes-1 | return executor(sql, params, many, context) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute tandoor-web_recipes-1 | with self.db.wrap_database_errors: tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__ tandoor-web_recipes-1 | raise dj_exc_value.with_traceback(traceback) from exc_value tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | django.db.utils.ProgrammingError: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_recipes-1 | ::ffff:192.168.32.4 - - [04/Feb/2024:12:57:26 +0100] "GET / HTTP/1.0" 500 144329 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" tandoor-web_media-1 | 192.168.32.1 - - [04/Feb/2024:12:57:26 +0100] "GET / HTTP/1.1" 500 144329 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" "192.168.21.101" tandoor-db_recipes-1 | 2024-02-04 11:57:27.695 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:27.695 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:27.715 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:27.715 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:27.716 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:27.716 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:27.718 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:27.718 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:27.719 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:27.719 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:27.720 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:27.720 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-db_recipes-1 | 2024-02-04 11:57:27.722 UTC [38] ERROR: column cookbook_space.space_theme does not exist at character 85 tandoor-db_recipes-1 | 2024-02-04 11:57:27.722 UTC [38] STATEMENT: SELECT "cookbook_space"."id", "cookbook_space"."name", "cookbook_space"."image_id", "cookbook_space"."space_theme", "cookbook_space"."custom_space_theme_id", "cookbook_space"."nav_logo_id", "cookbook_space"."nav_bg_color", "cookbook_space"."nav_text_color", "cookbook_space"."app_name", "cookbook_space"."logo_color_32_id", "cookbook_space"."logo_color_128_id", "cookbook_space"."logo_color_144_id", "cookbook_space"."logo_color_180_id", "cookbook_space"."logo_color_192_id", "cookbook_space"."logo_color_512_id", "cookbook_space"."logo_color_svg_id", "cookbook_space"."created_by_id", "cookbook_space"."created_at", "cookbook_space"."message", "cookbook_space"."max_recipes", "cookbook_space"."max_file_storage_mb", "cookbook_space"."max_users", "cookbook_space"."allow_sharing", "cookbook_space"."no_sharing_limit", "cookbook_space"."demo", "cookbook_space"."internal_note" FROM "cookbook_space" WHERE "cookbook_space"."id" = 1 LIMIT 21 tandoor-web_recipes-1 | Internal Server Error: /service-worker.js tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 218, in __get__ tandoor-web_recipes-1 | rel_obj = self.field.get_cached_value(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/mixins.py", line 15, in get_cached_value tandoor-web_recipes-1 | return instance._state.fields_cache[cache_name] tandoor-web_recipes-1 | KeyError: 'space' tandoor-web_recipes-1 | tandoor-web_recipes-1 | During handling of the above exception, another exception occurred: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | psycopg2.errors.UndefinedColumn: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_recipes-1 | tandoor-web_recipes-1 | The above exception was the direct cause of the following exception: tandoor-web_recipes-1 | tandoor-web_recipes-1 | Traceback (most recent call last): tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/core/handlers/exception.py", line 55, in inner tandoor-web_recipes-1 | response = get_response(request) tandoor-web_recipes-1 | File "/opt/recipes/cookbook/helper/scope_middleware.py", line 50, in __call__ tandoor-web_recipes-1 | request.space = user_space.space tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 236, in __get__ tandoor-web_recipes-1 | rel_obj = self.get_object(instance) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/fields/related_descriptors.py", line 199, in get_object tandoor-web_recipes-1 | return qs.get(self.field.get_reverse_related_filter(instance)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 633, in get tandoor-web_recipes-1 | num = len(clone) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 380, in __len__ tandoor-web_recipes-1 | self._fetch_all() tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 1881, in _fetch_all tandoor-web_recipes-1 | self._result_cache = list(self._iterable_class(self)) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/query.py", line 91, in __iter__ tandoor-web_recipes-1 | results = compiler.execute_sql( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/models/sql/compiler.py", line 1562, in execute_sql tandoor-web_recipes-1 | cursor.execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 102, in execute tandoor-web_recipes-1 | return super().execute(sql, params) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 67, in execute tandoor-web_recipes-1 | return self._execute_with_wrappers( tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 80, in _execute_with_wrappers tandoor-web_recipes-1 | return executor(sql, params, many, context) tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 84, in _execute tandoor-web_recipes-1 | with self.db.wrap_database_errors: tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/utils.py", line 91, in __exit__ tandoor-web_recipes-1 | raise dj_exc_value.with_traceback(traceback) from exc_value tandoor-web_recipes-1 | File "/opt/recipes/venv/lib/python3.10/site-packages/django/db/backends/utils.py", line 89, in _execute tandoor-web_recipes-1 | return self.cursor.execute(sql, params) tandoor-web_recipes-1 | django.db.utils.ProgrammingError: column cookbook_space.space_theme does not exist tandoor-web_recipes-1 | LINE 1: ...kbook_space"."name", "cookbook_space"."image_id", "cookbook_... tandoor-web_recipes-1 | ^ tandoor-web_recipes-1 | tandoor-web_recipes-1 | ::ffff:192.168.32.4 - - [04/Feb/2024:12:57:27 +0100] "GET /service-worker.js HTTP/1.0" 500 144696 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" tandoor-web_media-1 | 192.168.32.1 - - [04/Feb/2024:12:57:27 +0100] "GET /service-worker.js HTTP/1.1" 500 144696 "-" "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0" "192.168.21.101" tandoor-db_recipes-1 | 2024-02-04 11:57:46.393 UTC [21] LOG: checkpoint starting: time tandoor-db_recipes-1 | 2024-02-04 11:57:47.062 UTC [21] LOG: checkpoint complete: wrote 2 buffers (0.0%); 0 WAL file(s) added, 0 removed, 0 recycled; write=0.001 s, sync=0.078 s, total=0.670 s; sync files=3, longest=0.078 s, average=0.026 s; distance=0 kB, estimate=0 kB ```
vabene1111 commented 9 months ago

That's a different error, please read the message, you have some duplicates that need to be manually migrated due to a change in the data structure.

lagset commented 9 months ago

Thanks for the quick response, I will take a closer look.