我正在尝试使用--autogenerate
标志让 alembic 工作自动生成迁移。
当我跑步时,alembic -n mydbname --autogenerate -m "my message"
我得到类似的东西:
INFO [alembic.migration] Context impl MySQLImpl.
INFO [alembic.migration] Will assume non-transactional DDL.
INFO [alembic.autogenerate] Detected removed table u'some_table'
INFO [alembic.autogenerate] Detected NULL on column 'table_a.column_a'
INFO [alembic.autogenerate] Detected added column 'table_b.column_b'
.......
但是当我查看生成的迁移文件时,upgrade
两者downgrade
都简单地说pass
.
这是怎么回事?!