Skip to main content

Developer Guide

Welcome to the Zenzic engineering community. We build tools that bridge the gap between human documentation and executable truth. Our codebase follows rigorous standards for performance, type safety (mypy --strict), and accessibility.

This section covers everything you need to extend, adapt, or contribute to Zenzic.


In this section

  • Writing Plugin Rules — implement BaseRule subclasses, register them via entry_points, and satisfy the pickle / purity contract.
  • Writing an Adapter — implement the BaseAdapter protocol to teach Zenzic about a new documentation engine.
  • Example Projects — four self-contained runnable fixtures that demonstrate correct and incorrect Zenzic configurations.

Interactive Workflow with Just

Zenzic uses just as its interactive command runner. just is the fast day-to-day layer; nox is the reproducible CI layer underneath.

CommandDescription
just syncInstall / update all dependency groups (uv sync --all-groups)
just checkSelf-lint — run Zenzic on its own documentation (strict)
just testRun the test suite (delegates to nox -s tests, Hypothesis dev profile)
just test-fullRun the test suite with Hypothesis ci profile (500 examples)
just preflightFull CI-equivalent pipeline: lint, typecheck, tests, reuse, security
just verifyPre-push gate: preflight + build-prod
just buildBuild the documentation site (fast, no strict enforcement)
just build-prodBuild the documentation site (strict mode, mirrors CI)
just serve [port]Start the live-reload documentation server (default port 8000)
just cleanRemove generated artefacts (site/, dist/, .hypothesis/, caches, score file)

The Sentinel's self-linting duty — just check — is the first command to run after any documentation change. Run just verify before every push to main.

Hypothesis profiles

Property-based tests use Hypothesis with three profiles, controlled by the HYPOTHESIS_PROFILE environment variable:

ProfileExamples per testWhen to use
dev (default)50Day-to-day development (just test)
ci500CI pipelines and just test-full
purity1 000Pre-release exhaustive validation
just test # dev profile (fast)
just test-full # ci profile (thorough)
HYPOTHESIS_PROFILE=purity just test # pre-release
Mutation testing

Use nox -s mutation to run mutmut against src/zenzic/core/rules.py. This is deliberately not part of just verify — run it manually after working on the rule engine:

nox -s mutation

Contributing

Full contribution guidelines, code conventions, Core Laws, and the pre-PR checklist are in CONTRIBUTING.md on GitHub.

When you open a pull request, GitHub automatically loads the PR checklist — verify all items before requesting a review.