Skip to content

Python package development

From the workspace root, install the Pixi environments and run the Python tests:

Terminal window
pixi install -e default
pixi install -e build
pixi run -e default pytest -c packages/qgis-sdk-python/pyproject.toml packages/qgis-sdk-python/tests

The Python development dependencies are declared in this package’s dev extra. Pixi pins its Python tools and installs Hypothesis and pytest-cov as wheels. The workspace packages are loaded from packages/qgis-sdk-runtime/src and packages/qgis-sdk-tools/src on PYTHONPATH rather than installed as Pixi path dependencies; packages/qgis-sdk-python is the code-free qgis-sdk kit that owns the shared test suite, the developer scripts and the three-output Conda recipe.

The checked contract-generation examples live in tests/contract_sample/ and are run via the workspace’s sdk:generate package script; see Contract generation (checked example). Mashumaro remains a test-only schema-export example, not a general SDK generator or public operation.