Fix alembic migration to rename buylisting.longtitude to longitude
The migration was incorrectly changed to a no-op, leaving the typo in the buylisting table which caused OperationalError during scraping.
This commit is contained in:
parent
0fb4504646
commit
f465ccb8b8
1 changed files with 4 additions and 6 deletions
|
|
@ -19,12 +19,10 @@ depends_on: Union[str, Sequence[str], None] = None
|
|||
|
||||
|
||||
def upgrade() -> None:
|
||||
"""Upgrade schema - this migration is now a no-op since tables already have correct column name."""
|
||||
# The tables were created with 'longitude' (correct spelling) in the initial migration.
|
||||
# This migration was incorrectly auto-generated and has been fixed to be a no-op.
|
||||
pass
|
||||
"""Rename 'longtitude' to 'longitude' in buylisting table."""
|
||||
op.alter_column('buylisting', 'longtitude', new_column_name='longitude', existing_type=sa.Float(), existing_nullable=False)
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
"""Downgrade schema - no-op since upgrade is no-op."""
|
||||
pass
|
||||
"""Rename 'longitude' back to 'longtitude' in buylisting table."""
|
||||
op.alter_column('buylisting', 'longitude', new_column_name='longtitude', existing_type=sa.Float(), existing_nullable=False)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue