Flask-DbMigrant
Flask extension for working with Alembic.
It can be used as an alternative for Flask-Migrate. It depends only on Flask and Alembic.
Installation
$ pip install Flask-DbMigrant
Usage
First create the dbmigrant object:
from flask_dbmigrant import DbMigrant
dbmigrant = DbMigrant()
Then initialize it using init_app method:
dbmigrant.init_app(app) # app is your Flask app instance
The Flask app config should have CONFIG_MODULE and DB_MODULE keys.
CONFIG_MODULE is a name of the module from which DATABASE_URL is to be imported (DATABASE_URL is a connection string that tells what database to connect to).
DB_MODULE is a name of the module from which database models and metadata are to be imported.
Existing commands
-
flask db init
create a migration repository and configure the environment
-
flask db migrate
create a migration script
-
flask db upgrade
execute the script
License
Flask-DbMigrant was created by Rafal Padkowski. It is licensed under the terms
of the MIT license.
Metadata
Release files for flask-dbmigrant 1.0.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| flask_dbmigrant-1.0.3.tar.gz | 2.7 kB | Without provenance | Details for flask_dbmigrant-1.0.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| flask_dbmigrant-1.0.3-py3-none-any.whl | Python 3 | none | any | Details for flask_dbmigrant-1.0.3-py3-none-any.whl |
Total release size: 5.9 kB
Release files / flask_dbmigrant-1.0.3.tar.gz
| Download URL | flask_dbmigrant-1.0.3.tar.gz |
|---|---|
| Size | 2.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6e8a5f628757a8d4f9593a33969c9e5fa97c255c81710659de754e2221cbe19b
|
|
BLAKE2b-256 checksum How to use checksums |
dba20b966202925dc98e9d603988a67a1968a7dbf421973c5d0c8f4ceac8cdbb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.1 CPython/3.10.12 Linux/5.15.0-79-generic
|
Release files / flask_dbmigrant-1.0.3-py3-none-any.whl
| Download URL | flask_dbmigrant-1.0.3-py3-none-any.whl |
|---|---|
| Size | 3.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
da8ff1b3a7c7c6f7dc650aeb831af94d3323497abdeeccd39f4ccaaaa5845151
|
|
BLAKE2b-256 checksum How to use checksums |
1a2a38829ec5761d092da0166c5c86814ddf454f400290344adb40104f3dcba3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.1 CPython/3.10.12 Linux/5.15.0-79-generic
|
Security for flask-dbmigrant 1.0.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.