You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(This issue has been reported in #39. More details have been reported here)
When the database has (materialised) views, setting up the database throws an error because the underlying tables do not exist.
This issue is happening for alembic_utils versions >= 0.2.16 and it gives this error message:
File ".../lib/python3.8/site-packages/sqlalchemy/engine/default.py", line 608, in do_execute
cursor.execute(statement, parameters)
sqlalchemy.exc.ProgrammingError: (psycopg2.errors.UndefinedTable) relation "transaction" does not exist
LINE 26: FROM transaction
^
....
(Background on this error at: http://sqlalche.me/e/13/f405)
I tested the same schema with versions <= 0.2.15 and it works fine.
More details:
Does this issue still exist in the latest version alembic_utils==0.5.3?
Yes, actually for any version >= 0.2.16 this issue exists.
Does this error when the migration is being generated, or when you attempt to apply the migrations to the database?
It happens when I run alembic to generate the migrations.
(This issue has been reported in #39. More details have been reported here)
When the database has (materialised) views, setting up the database throws an error because the underlying tables do not exist.
This issue is happening for
alembic_utils
versions >= 0.2.16 and it gives this error message:I tested the same schema with versions <=
0.2.15
and it works fine.More details:
Does this issue still exist in the latest version
alembic_utils==0.5.3
?Yes, actually for any version >= 0.2.16 this issue exists.
Does this error when the migration is being generated, or when you attempt to apply the migrations to the database?
It happens when I run
alembic
to generate the migrations.PostgreSQL version?
psql (PostgreSQL) 13.2 (Ubuntu 13.2-1.pgdg20.04+1)
Python version?
Python 3.8.8
An example to reproduce the error:
Table definition:
Then, in
env.py
(in alembic folder), I have put:where
my_mat_view.sql
has the SQL definition of the materialized view:The text was updated successfully, but these errors were encountered: