Install, Test, Build¶
This page covers the full setup flow for users and contributors.
Requirements¶
- Python 3.12
- Git
Install¶
git clone https://github.com/gaia-x4plc-aad/ontology-management-base.git
cd ontology-management-base
git submodule update --init --recursive
python3 -m venv .venv
source .venv/bin/activate
python3 -m pip install --upgrade pip
python3 -m pip install -e .
For development:
VS Code: Auto-activate virtual environment¶
Install the Python extension, then select the interpreter for this workspace so terminals auto-activate it.
- Command Palette → "Python: Select Interpreter" → choose
.venv. - Ensure these settings are enabled:
Test¶
Run the full validation suite:
Run a single domain:
Build Documentation¶
Install docs extras first:
Build the site:
To preview locally (auto-generates docs assets):
Notes:
Hook flow (via hooks/copy_artifacts.py):
- The hook runs
properties_updaterandclass_page_generator(DOCS_SITE_URL is optional and only affects local diagram links). properties_updaterwrites trackedartifacts/<domain>/PROPERTIES.md, generatesdocs/ontologies/properties/<domain>.md(ignored by git), builds thedocs/ontologies/properties.mddomains overview, and refreshesdocs/ontologies/catalog.md.class_page_generatorwritesdocs/ontologies/classes/<domain>/*.mdand usesDOCS_SITE_URLto build local diagram links.- The hook copies
artifacts/<domain>/intodocs/artifacts/<domain>/<versionInfo>/and adds example instances fromtests/data/.
Common Troubleshooting¶
- If
pyshaclis missing, install dev dependencies. - If catalogs are missing, run the registry updater: