Search code examples
pythonsanic

How to manage migrations with gino in python


I'm trying to use gino with sanic for an experimental project. And I blocked with migrating my model.py to the database.

I used flask-migrate when I use flask and sqlalchemy (more exactly, it's flask-sqlalchemy though)

What is the common tool for managing db migration in sanic & gino stack?


Solution

  • Checkout this issue: https://github.com/fantix/gino/issues/374

    And these instructions: https://gist.github.com/omarryhan/cb7bf6d7142c154496ba6623a56326c2#file-sanic-gino-alembic-migrations-setup