diff --git a/.agents/skills/diffprowl/SKILL.md b/.agents/skills/diffprowl/SKILL.md new file mode 100644 index 0000000..31fe688 --- /dev/null +++ b/.agents/skills/diffprowl/SKILL.md @@ -0,0 +1,20 @@ +--- +name: diffprowl +description: Observe and qualify DiffProwl test selection for pytest, diagnose full-suite fallbacks, and replay historical failures using a pinned engine and a full control run. +--- + +# DiffProwl + +Start from the application's Git root and the DiffProwl revision used by that application. Check its pin, platform asset, published SHA-256, and CLI version. Legacy integrations may still use the Panthera name, a different adapter, or an older receipt schema. Use the README and CLI help from the matching revision. + +## Observe a CI run + +Follow “Observe an existing pytest CI job” in the engine README for the exact invocation of `adapter/pytest_observer.py`. Keep the job's pytest arguments, coverage file, parallel workers, and exit status. Run all scoped tests. Keep application baselines, inventories, node IDs, and dependency maps in private application-controlled storage. Keep release credentials outside the pytest process. + +Match the run and report to the same head SHA. Check which ancestor baseline the observer actually loaded, its engine digest and scope, the collection on each worker, and the reported expansion reason. A published profile can exist even when CI could not load it. When diagnostics are incomplete, record the last confirmed step. A null omitted-failure count means the comparison was unavailable. + +## Check a change against a failure + +Use the change's own base and head. For a historical replay, see “Bounded historical replay” in the pinned README and read the checked-in scope and manifest. For a seeded fault, use the pinned engine's `qualify` command with the reviewed scope, campaign, and a fresh output directory. Compare selected and full runs from equivalent clean inputs. Check the failing node and phase, including new parametrized cases, and distinguish assertion failures from collection errors. Record when the planner expanded to every test. + +Report the selected and total case counts, observed misses, and scope. For timing claims, compare against ordinary full pytest and account for profiling, planning, and fallback costs. Identify any runtime fingerprints held fixed in an offline plan. Observation alone does not authorize skipping tests in CI. diff --git a/.agents/skills/diffprowl/agents/openai.yaml b/.agents/skills/diffprowl/agents/openai.yaml new file mode 100644 index 0000000..8a7030b --- /dev/null +++ b/.agents/skills/diffprowl/agents/openai.yaml @@ -0,0 +1,4 @@ +interface: + display_name: "DiffProwl" + short_description: "Observe pytest plans and diagnose full-suite fallbacks" + default_prompt: "Use $diffprowl to explain why the pytest observer selected the full suite for this change." diff --git a/README.md b/README.md index 5e423e8..586249b 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,33 @@ the resulting executable runs offline. This is a **bounded in-process fixture**, not a QualityMax production integration or a safe-to-skip recommendation for the repository's existing CI gates. +## Codex prompts for pytest + +Open this checkout in Codex to use the [DiffProwl skill](.agents/skills/diffprowl/SKILL.md). When working in another repository, install the skill there or in your personal skills directory. Paste a prompt and replace the placeholders with a PR, test ID, or CI run. + +**Explain a full-suite run** + +```text +Use $diffprowl to explain why the pytest observer selected the full suite for . +Which baseline did CI load? Show the reported reason and the evidence for it. +``` + +**Check whether a plan catches a known failure** + +```text +Use $diffprowl to replay against its own base commit. The known failure is +. Run the full scoped suite as a control and tell me whether +the plan caught the same failing case and phase, and how many tests it selected. +``` + +**Measure CI time** + +```text +Use $diffprowl to compare with ordinary full pytest on the same revision +and scope. Report elapsed time for each, including profiling and planning costs. +If timings are missing, tell me which measurement would settle the comparison. +``` + ## Run From the repository root (tested with Rust/Cargo 1.94.1):