【发布时间】:2020-08-04 15:09:32
【问题描述】:
我正在尝试在我的应用程序中实现自动迁移。 Procfile 包括:
release: python manage.py migrate
...
2020-08-04T15:01:34.924211+00:00 heroku[run.4178]: State changed from starting to up
2020-08-04T15:01:35.269081+00:00 heroku[run.4178]: Awaiting client
2020-08-04T15:01:35.326202+00:00 heroku[run.4178]: Starting process with command `python manage.py migrate`
2020-08-04T15:01:44.905287+00:00 heroku[run.4178]: Process exited with status 0
2020-08-04T15:01:44.945348+00:00 heroku[run.4178]: State changed from up to complete
但是,如果我尝试将数据加载到数据库中,它会打印:No such table: <> 错误。如果我重新运行 migrate 命令,它会起作用。这里有什么问题?
【问题讨论】:
标签: python database heroku migration heroku-postgres