python-general-be-lib
Libreria backend general purpose per progetti Python: repository CRUD e spaziali su SQLAlchemy / GeoAlchemy2, eccezioni FastAPI, modelli base Pydantic e utility di logging.
- Distribuzione PyPI:
python-general-be-lib - Pacchetto importabile:
general - Python richiesto: 3.12+
pip install python-general-be-lib
from sqlalchemy import create_engine
from general.interface.repository import CrudRepository
engine = create_engine("postgresql://user:pass@localhost/db")
repo = CrudRepository(entity=User, model=UserModel, engine=engine)
repo.insert(models=[UserModel(name="Mario", email="mario@example.com")])
repo.find(active=True, order_by="name", asc=True)
Cosa contiene
| Area | Componenti |
|---|---|
| Repository ORM | CrudRepository, GeometryRepository, ManyToManyRepository, ViewRepository |
| Layer Core (senza ORM) | CrudMetadata, GeomMetadata — CRUD e query spaziali su Table riflesse |
| Motore di filtraggio | StatementManager + BaseHandler, JsonHandler, ILikeHandler, JsonILikeHandler, OrHandler, IntervalHandler |
| Basi | Base (declarative base estesa), ExtBaseModel, CamelExtBaseModel |
| Paginazione | PaginatorRequestModel, PaginatorResponseModel |
| Eccezioni | ExceptionInterface e sottoclassi HTTP (400/401/403/404/422/500/503) |
| Logging | init_logger, decorator @log |
Documentazione
| Documento | Contenuto |
|---|---|
CHANGELOG.md |
Modifiche per versione, con le note di migrazione |
general/README.md |
Panoramica della libreria: struttura, contratto sulle sessioni, handler, operazioni spaziali |
general/DOCS.md |
Riferimento completo, metodo per metodo |
Release files for python-general-be-lib 0.9.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| python_general_be_lib-0.9.0.tar.gz | 90.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| python_general_be_lib-0.9.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 145.6 kB
Release files / python_general_be_lib-0.9.0.tar.gz
| Download URL | python_general_be_lib-0.9.0.tar.gz |
|---|---|
| Size | 90.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
01139a75c41093435b231f90313acbb92dc9dcab470776e01458234cda4da478
|
|
BLAKE2b-256 checksum How to use checksums |
44cdea1103b3143850cee270d43e92db1d03cdc9ccf1eb84f6a4590345f11e8a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|
Release files / python_general_be_lib-0.9.0-py3-none-any.whl
| Download URL | python_general_be_lib-0.9.0-py3-none-any.whl |
|---|---|
| Size | 54.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3076d6e6cb54d8e8494d5a6d19d2d81c9b3a64a2a48a5b96f201c5bcd15e2f41
|
|
BLAKE2b-256 checksum How to use checksums |
ab3ae369e88c5cbc0164f0da0cf51d7b5f922cc9364eda34857f77ce348a366e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.13.5
|