No description
Find a file
2024-07-02 15:31:49 +02:00
src/pretix_model add linting, use python3.12 2024-07-02 15:22:12 +02:00
tests first commit 2024-02-20 16:55:07 +01:00
.gitignore Revert "added egg-info" 2024-05-19 16:37:37 +02:00
.pre-commit-config.yaml add linting, use python3.12 2024-07-02 15:22:12 +02:00
pdm.lock add pdm lockfile 2024-07-02 15:29:11 +02:00
pyproject.toml update version 2024-07-02 15:30:21 +02:00
README.md add pre commit docs 2024-07-02 15:31:49 +02:00

Pretix Model

This is a simple model for a pretix event system used to parse the pretix API. All object-collections inherit from the ModelEntity(ABC) class which handles the caching.

Object-collections are the plural form of the object they represent, e.g. Event and Events.

The update(...) method is used to update the object-collection from the pretix API.

All objects are pydantic BaseModel objects which get created from the pretix API response.

For usage see the SaunaTable repo which uses this model.

Logging

Use utils/logging_setup.py to set up the logging for the model. This also affects the logging for your main application.

Linting

Use ruff and pre-commit to lint the code.

# install pre-commit, and ruff
pip3 install -U pre-commit ruff

# install pre-commit hooks
pre-commit install