sqlalchemy-migrate

alembic autogenerates creates empty migration but generates table

alembic autogenerates creates empty migration but generates table Question: I followed the documentation from Alembic to auto-generate migrations. My project structure looks like this: alembic/ versions/ env.py README script.py.mako data/ __init__.py db.py models.py alembic.ini app.db I made changes to env.py by exactly following the document: from logging.config import fileConfig from sqlalchemy import engine_from_config from sqlalchemy …

Total answers: 2

SQLAlchemy-Migrate or Alembic deletes data when renaming model

SQLAlchemy-Migrate or Alembic deletes data when renaming model Question: I am using SQLAlchemy-Migrate to manage migrations for my PostgreSQL database. I changed the __tablename__ for a model, and running the migration changed the name in the database, but all the rows in the table were deleted. How can I rename a model without deleting data? …

Total answers: 3

Is it worth using sqlalchemy-migrate ?

Is it worth using sqlalchemy-migrate ? Question: I have a web application using sqlalchemy (within Pylons). I need to effiently change the schema to be able to change the production version at least on a daily basis, maybe more, without losing the data. I have played a little bit with sqlalchemy-migrate over the week-end and …

Total answers: 3