Skip to content

Commit 1d01d88

Browse files
committed
Refactor column name to "alembic_head_revisions".
Renamed the "alembic_revision" column to "alembic_head_revisions" in both the migration environment and initialization script. This ensures consistency and better reflects the purpose of the column.
1 parent ff57007 commit 1d01d88

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/migrations/env.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ class FixtureMigration(declarative_base):
5050
bind: Mapped[str] = mapped_column(String(), primary_key=True)
5151
module_name: Mapped[str] = mapped_column(String(), primary_key=True)
5252
signature: Mapped[str] = mapped_column(String(), nullable=False)
53-
alembic_revision: Mapped[str] = mapped_column(String(), nullable=True, default=str(context.get_head_revision()))
53+
alembic_head_revisions: Mapped[str] = mapped_column(String(), nullable=True, default=str(context.get_head_revision()))
5454

5555
processed_at: Mapped[datetime] = mapped_column(
5656
DateTime(), nullable=False, default=datetime.now

src/migrations/versions/2025-01-26-212326-52b1246eda46_initialize_fixture_tables.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ def upgrade_default() -> None:
3030
sa.Column("bind", sa.String(), nullable=False),
3131
sa.Column("module_name", sa.String(), nullable=False),
3232
sa.Column("signature", sa.String(), nullable=False),
33-
sa.Column("alembic_revision", sa.String(), nullable=False),
33+
sa.Column("alembic_head_revisions", sa.String(), nullable=False),
3434
sa.Column("processed_at", sa.DateTime(timezone=True), nullable=False),
3535
sa.PrimaryKeyConstraint("bind", "module_name"),
3636
)

0 commit comments

Comments
 (0)