Flask SQLAlchemy backend supporting the Python 3.7 version of Flask SQLAlchemy compat.
Project description
Flask SQLAlchemy backend supporting the Python 3.7 version of Flask SQLAlchemy compat.
This package is forked from an unofficial version of Flask SQLAlchemy. The motication of uploading this fork to PyPI includes:
1. Bring the DeclarativeBase feature to Python 3.7. The official version is up to 3.0.5 which is not compatible with the sqlalchemy2 style.
2. Serve as a backend support of the package flask-sqlalchemy-compat when using Python 3.7
If you are using Pyhon<3.7, you should not use flask-sqlalchemy-compat, the only available choice is flask-sqlalchemy.
If you are using Python>=3.8, you do not need this package, because flask-sqlalchemy is already compatible with Python>=3.8.
Reference |
|---|
Flask-SQLAlchemy
The following part is from the original README file.
Flask-SQLAlchemy is an extension for Flask that adds support for SQLAlchemy to your application. It aims to simplify using SQLAlchemy with Flask by providing useful defaults and extra helpers that make it easier to accomplish common tasks.
Installing
Install and update using pip:
$ pip install -U Flask-SQLAlchemy
A Simple Example
from flask import Flask
from flask_sqlalchemy import SQLAlchemy
from sqlalchemy.orm import DeclarativeBase, Mapped, mapped_column
app = Flask(__name__)
app.config["SQLALCHEMY_DATABASE_URI"] = "sqlite:///example.sqlite"
class Base(DeclarativeBase):
pass
db = SQLAlchemy(app, model_class=Base)
class User(db.Model):
id: Mapped[int] = mapped_column(db.Integer, primary_key=True)
username: Mapped[str] = mapped_column(db.String, unique=True, nullable=False)
with app.app_context():
db.create_all()
db.session.add(User(username="example"))
db.session.commit()
users = db.session.execute(db.select(User)).scalars()
Contributing
For guidance on setting up a development environment and how to make a contribution to Flask-SQLAlchemy, see the contributing guidelines.
Donate
The Pallets organization develops and supports Flask-SQLAlchemy and other popular packages. In order to grow the community of contributors and users, and allow the maintainers to devote more time to the projects, please donate today.
Links
Documentation: https://flask-sqlalchemy.palletsprojects.com/
Changes: https://flask-sqlalchemy.palletsprojects.com/changes/
PyPI Releases: https://pypi.org/project/Flask-SQLAlchemy/
Source Code: https://github.com/pallets-eco/flask-sqlalchemy/
Issue Tracker: https://github.com/pallets-eco/flask-sqlalchemy/issues/
Website: https://palletsprojects.com/
Twitter: https://twitter.com/PalletsTeam
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file flask_sqlalchemy_compat_backend_py37-3.1.0.dev3.tar.gz.
File metadata
- Download URL: flask_sqlalchemy_compat_backend_py37-3.1.0.dev3.tar.gz
- Upload date:
- Size: 105.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8ed0dcb2236e595a03c8bf9adbf4651380504159febffc8af66fe3d3b2ef4b21
|
|
| MD5 |
70d7672d85255fc78305171f53bc11c2
|
|
| BLAKE2b-256 |
c5e9dfe2ab1134016ea370c9b778b62e308d658f2d1ef34de6b6c06bdd9316fb
|
Provenance
The following attestation bundles were made for flask_sqlalchemy_compat_backend_py37-3.1.0.dev3.tar.gz:
Publisher:
publish.yaml on cainmagi/flask-sqlalchemy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
flask_sqlalchemy_compat_backend_py37-3.1.0.dev3.tar.gz -
Subject digest:
8ed0dcb2236e595a03c8bf9adbf4651380504159febffc8af66fe3d3b2ef4b21 - Sigstore transparency entry: 154571591
- Sigstore integration time:
-
Permalink:
cainmagi/flask-sqlalchemy@5522625b3c7ff85c3cdb23fd9d0b07362cb2f4e4 -
Branch / Tag:
refs/tags/v3.1.0.dev3-py37 - Owner: https://github.com/cainmagi
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yaml@5522625b3c7ff85c3cdb23fd9d0b07362cb2f4e4 -
Trigger Event:
release
-
Statement type:
File details
Details for the file Flask_SQLAlchemy_compat_backend_py37-3.1.0.dev3-py3-none-any.whl.
File metadata
- Download URL: Flask_SQLAlchemy_compat_backend_py37-3.1.0.dev3-py3-none-any.whl
- Upload date:
- Size: 48.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
28365044728be1af1ea70ae56e04b55cfbb983f87d029404f63c4f328e8cc0d2
|
|
| MD5 |
561898b3da17750c938a501994181409
|
|
| BLAKE2b-256 |
0ca51aa0a2d4938102a61cf24ecbcc29555d413bc3092c8daa47673fea4d095a
|
Provenance
The following attestation bundles were made for Flask_SQLAlchemy_compat_backend_py37-3.1.0.dev3-py3-none-any.whl:
Publisher:
publish.yaml on cainmagi/flask-sqlalchemy
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
flask_sqlalchemy_compat_backend_py37-3.1.0.dev3-py3-none-any.whl -
Subject digest:
28365044728be1af1ea70ae56e04b55cfbb983f87d029404f63c4f328e8cc0d2 - Sigstore transparency entry: 154571592
- Sigstore integration time:
-
Permalink:
cainmagi/flask-sqlalchemy@5522625b3c7ff85c3cdb23fd9d0b07362cb2f4e4 -
Branch / Tag:
refs/tags/v3.1.0.dev3-py37 - Owner: https://github.com/cainmagi
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yaml@5522625b3c7ff85c3cdb23fd9d0b07362cb2f4e4 -
Trigger Event:
release
-
Statement type: