skip to navigation
skip to content

Flask-Alembic 2.0.1

Flask extension to integrate Alembic migrations

This Flask extension provides a configurable Alembic migration environment around a Flask-SQLAlchemy database.

Full documentation


Install releases from PyPI:

pip install Flask-Alembic

Install the latest code from BitBucket:

pip install

Basic Usage

You’ve created a Flask application and some models with Flask-SQLAlchemy. Now start using Flask-Alembic:

from flask_alembic import Alembic

# Intialize the extension
alembic = Alembic()

# Auto-generate a migration
alembic.revision('making changes')

# Upgrade the database

# Access the internals
environment_context = alembic.env

Commands are included for Click (Flask 0.11, or Flask-CLI):

$ flask db revision "making changes"
$ flask db upgrade

and Flask-Script:

$ python db --help
File Type Py Version Uploaded on Size
Flask-Alembic-2.0.1.tar.gz (md5) Source 2016-09-01 16KB
Flask_Alembic-2.0.1-py2.py3-none-any.whl (md5) Python Wheel 3.5 2016-09-01 10KB