Skip to main content

guardana-reference-pack

A Guardana extension pack that uses all six extension points and imports nothing outside the supported surface. It has its own version (0.1.3), depends on guardana-core>=0.41 with no upper bound, and declares the extension_api and output_api ranges it runs on in its manifest. guardana pack validate checks those ranges; installing the pack or running a scan does not. A CI job that depends on the pack therefore runs guardana pack validate and guardana pack lock --check. Install it from PyPI with pip install guardana-cli guardana-reference-pack, or use the wheel and sdist attached to each GitHub Release. The pack depends only on guardana-core>=0.41, so installing it alone gives no guardana command. Guardana refuses installed third-party packs by default. Admit this pack with --plugins allowlist --allow-plugin guardana-reference-pack or plugins: in a profile.

custom_rule and output_pack teach one idea each. This pack is an example a third party can copy: everything in it is checked by the commands and the conformance kit Guardana ships, from an isolated install.

What it ships

Extension point What File
guardana.rules reference.prompt.codename_disclosure, a YAML rule graded by the pack's own evaluator src/guardana_reference_pack/rules/codename_disclosure.yaml
guardana.rules reference.supply_chain.unpinned_requirement, a Python rule over pip requirement files src/guardana_reference_pack/unpinned.py
guardana.evaluators reference.marker: a reply fails when it repeats a configured marker src/guardana_reference_pack/evaluator.py
guardana.targets reference-requirements://<dir>: the requirement files under a directory src/guardana_reference_pack/target.py
guardana.taxonomies REFERENCE-CONTROLS, the pack's own control catalogue (REF-1, REF-2) src/guardana_reference_pack/controls.py
guardana.renderers --format reference-summary: the run as Markdown src/guardana_reference_pack/summary.py
guardana.reporters --reporter reference-file://<dir>: that Markdown, written to <dir>/guardana-<run id>.md src/guardana_reference_pack/file_reporter.py

Both rules declare a finding, a clean and an inconclusive sample, so guardana rule test 'reference.*' proves each one fires, stays silent and declines. The manifest, src/guardana_reference_pack/guardana-pack.yaml, is schema 3, and guardana-lock.yaml pins what the pack registers.

The reporter's prepare only checks the locator. deliver writes through a temporary file, fsyncs it and moves it into place, then reports delivered; a directory that does not exist is unreachable, and an OSError while writing is rejected. The file is readable by its owner only.

Try it

From the repository root:

uv pip install ./examples/reference_pack
ADMIT="--plugins allowlist --allow-plugin guardana-reference-pack"
uv run guardana rule test 'reference.*' $ADMIT
uv run guardana pack validate $ADMIT
mkdir -p summaries
uv run guardana scan --target reference-requirements://. $ADMIT \
  --format reference-summary --reporter reference-file://summaries

Its own suite

tests/ runs from an isolated install, the way CI and scripts/ci_local.sh run it:

uv run --isolated --no-cache \
  --with ./packages/guardana-core --with ./packages/guardana-rules \
  --with ./packages/guardana-cli --with ./packages/guardana-report \
  --with ./examples/reference_pack --with pytest pytest examples/reference_pack/tests

tests/test_reference_surface.py walks every import in src/ and tests/ and refuses a guardana.* name outside the supported surface, computed from the installed build: __all__ of guardana.core (less Runner), guardana.core.verify, guardana.core.doubles, guardana.core.target.protocols, guardana.core.output, guardana.testing and guardana.core.testing, plus guardana.core.target.WireProtocol and the public names of guardana.core.rule.fixture.

guardana-lock.yaml holds the pack's own entry only: the built-in pack's entry moves with every Guardana release, so the lock test takes it from the installed build and runs pack lock --check over both. After changing a rule, regenerate the lock from an isolated install:

uv run --isolated --no-cache \
  --with ./packages/guardana-core --with ./packages/guardana-rules \
  --with ./packages/guardana-cli --with ./packages/guardana-report \
  --with ./examples/reference_pack \
  guardana pack lock examples/reference_pack/guardana-lock.yaml \
  --plugins allowlist --allow-plugin guardana-reference-pack

Then delete every entry but guardana-reference-pack under packs:.

Metadata

Release files for guardana-reference-pack 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for guardana-reference-pack 0.1.3
File Size Uploaded
guardana_reference_pack-0.1.3.tar.gz 20.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for guardana-reference-pack 0.1.3
File Interpreter ABI Platform
guardana_reference_pack-0.1.3-py3-none-any.whl Python 3 none any Details

Total release size: 39.8 kB

Release files / guardana_reference_pack-0.1.3.tar.gz

Download URL guardana_reference_pack-0.1.3.tar.gz
Size 20.8 kB
Tags Source
SHA-256 checksum
How to use checksums
2305b03df19bd2502c437e8db484b5f367ad3cb801d7da3f2b00b06488c61306
BLAKE2b-256 checksum
How to use checksums
ab2703d228c4438fa276502b238a7d2a429b6dc4c3894cc64dde95b3fc1ce902
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 17, 2026.

Transparency log

Release files / guardana_reference_pack-0.1.3-py3-none-any.whl

Download URL guardana_reference_pack-0.1.3-py3-none-any.whl
Size 19.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8f464f70b19992a8aec569579bdbe480675e95b2f34df1150547dc4da3081245
BLAKE2b-256 checksum
How to use checksums
0390eabc70481346c8998decff7a8faed9c4172b9189d1d7f61adc23ee342f36
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 17, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.3 This release

2 release files

0.1.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page