Skip to content

Spend Hardening Effort Where a Failure Can Actually Occur - #2507

Merged
ptr727 merged 5 commits into
developfrom
feature/hardening-effort-rule
Oct 8, 2026
Merged

ptr727 merged 5 commits into
developfrom
feature/hardening-effort-rule

Conversation

@ptr727

@ptr727 ptr727 commented Oct 7, 2026

Copy link
Copy Markdown
Owner

Summary

Implements #2501: a governance rule that hardening effort follows the real risk, not the theoretical one.

  • GOVERNANCE.md "Trust Boundaries and Hardening Effort", a new carried verbatim section. Input is trusted or untrusted by where it originates, not by the channel carrying it. Against trusted input the only threat is a maintainer's mistake. Untrusted input is validated once at its boundary. A hardening case earns a fix or an issue only where it can realistically occur in the code's deployment and fails silently, destructively, or at an outsider's trigger. A plain bug on the ordinary path is still fixed. A review finding asking for hardening the section rules out is declined, and a repository can name its own boundaries under OPERATIONS.md Configuration Layout.
  • Declared in spec/files.json and spec/section-model.md, and routed from the AGENTS.md "Where the Rules Live" table.
  • fleet-code-review "Review the Change" carries the section as a generated include, so every review brief (local-strict-review, Copilot) reaches it with no new trigger.
  • local-strict-review asks after coercions, races, and platform differences only where the code's deployment can produce one.
  • pr-review-conduct outcome 2 and its triage list route a ruled-out hardening finding to an evidence-backed decline. drive-pr changes only through its regenerated include.

.github/copilot-instructions.md is deliberately unchanged. Copilot already loads fleet-code-review, which now carries the rule, and that file forbids duplicating GOVERNANCE.md.

Verification

  • scripts/build_dist.py --check, spec/validate.py, spec/audit.py --selftest, the prose gate, markdownlint, cspell, and editorconfig-checker all pass.
  • tests/test_build_dist.py, test_canonical_review.py, test_carry.py, test_spec_validate.py, test_repo_gate.py, and test_release_guards.py all pass.
  • Four local-strict-review passes ran. The first three found 9, 3, and 3 defects, each fixed in its own commit, and the fourth found none and is recorded.

Refs #2501, which closes on the promotion PR.

🤖 Generated with Claude Code

ptr727 and others added 4 commits October 7, 2026 14:19
Add a GOVERNANCE.md "Trust Boundaries and Hardening Effort" section:
trusted against untrusted input, likelihood times consequence for
robustness hardening too, and a decline for a review finding asking for
hardening the section rules out. fleet-code-review "Review the Change"
carries it as a generated include, local-strict-review asks after races,
coercions, and platform differences only where the deployment can
produce one, and pr-review-conduct's decline outcome cites it.

Fixes #2501

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…g Rule

Address the local review: trust follows where data originates, every case
short of realistic and silent or destructive is declined, the
contradicting host-tool example is gone, the boundary list lives in
OPERATIONS.md, and the decline sentences are shortened.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… Untrusted

Address the second local review: a host log line recording an outside
client's request is untrusted, a failure an outsider can trigger earns a
fix, and the boundary list sits under OPERATIONS.md Configuration Layout.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…el by Origin

Address the third local review: code failing on its ordinary path is a
bug and is fixed, any channel holding outsider content is untrusted, and
pr-review-conduct's triage list routes ruled-out hardening to outcome 2.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings October 7, 2026 21:33
@coderabbitai

coderabbitai Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration
  • Configuration used: Repository: ptr727/ProjectTemplate/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 8f7710ed-e5e4-4998-a997-62a7ec45b050
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Review comments request clarification of the governance wording and alignment with the stated Copilot acceptance criterion.

1 open finding
What changed in this PR

Adds governance rules for proportionate hardening based on realistic deployment risk, and propagates them through review and triage skills.

Changes:

  • Adds and registers the new governance section.
  • Routes it through repository guidance and review workflows.
  • Regenerates GitHub, Claude, and agent skill distributions and digests.
File Summary
spec/​section-model.md Registers the carried governance section.
spec/​files.json Declares section fidelity.
GOVERNANCE.md Defines trust boundaries and hardening criteria.
AGENTS.md Routes agents to the new rule.
.github/​skills/​pr-review-conduct/​SKILL.md Updates triage guidance.
.github/​skills/​local-strict-review/​SKILL.md Scopes review checks by deployment risk.
.github/​skills/​fleet-code-review/​SKILL.md Includes the governance rule.
.github/​skills/​drive-pr/​SKILL.md Updates finding disposition guidance.
.claude-plugin/​fleet-skills/​skills/​pr-review-conduct/​SKILL.md Mirrors triage guidance.
.claude-plugin/​fleet-skills/​skills/​local-strict-review/​SKILL.md Mirrors review guidance.
.claude-plugin/​fleet-skills/​skills/​fleet-code-review/​SKILL.md Mirrors the governance include.
.claude-plugin/​fleet-skills/​skills/​drive-pr/​SKILL.md Mirrors disposition guidance.
.claude-plugin/​fleet-skills/​.source-digests/​pr-review-conduct Refreshes source digest.
.claude-plugin/​fleet-skills/​.source-digests/​local-strict-review Refreshes source digest.
.claude-plugin/​fleet-skills/​.source-digests/​fleet-code-review Refreshes source digest.
.claude-plugin/​fleet-skills/​.source-digests/​drive-pr Refreshes source digest.
.agents/​skills/​pr-review-conduct/​SKILL.md Updates canonical triage guidance.
.agents/​skills/​local-strict-review/​SKILL.md Updates canonical review guidance.
.agents/​skills/​fleet-code-review/​SKILL.md Adds the canonical governance include.
.agents/​skills/​drive-pr/​SKILL.md Updates canonical disposition guidance.

🧠 Review effort: Lite


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

Comment thread GOVERNANCE.md Outdated
@codecov

codecov Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 58.50%. Comparing base (e853b3a) to head (3f7fb71).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #2507   +/-   ##
========================================
  Coverage    58.50%   58.50%           
========================================
  Files           16       16           
  Lines         8066     8066           
========================================
  Hits          4719     4719           
  Misses        3347     3347           
Flag Coverage Δ
python-3.13 58.50% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

Resolve the Copilot acceptance-condition mismatch before approval.

0 open findings

1 resolved since last review

🧠 Review effort: Lite


Give feedback about Copilot approvals in this survey to enter a drawing for a $150 gift card.

@ptr727
ptr727 merged commit 6ccffa8 into develop Oct 8, 2026
13 checks passed
@ptr727
ptr727 deleted the feature/hardening-effort-rule branch October 8, 2026 02:26
ptr727 added a commit that referenced this pull request Oct 8, 2026
…ctually Occur (#2509)

## Summary

Promotes one change from `develop`:

- #2507: a new carried `GOVERNANCE.md` section, "Trust Boundaries and
Hardening Effort".
- Input is trusted or untrusted by where it originates. Against trusted
input the only threat is a maintainer's mistake, and untrusted input is
validated once at its boundary.
- A hardening case earns a fix or an issue only where it can
realistically occur in the code's deployment and fails silently,
destructively, or at an outsider's trigger. A plain bug is still fixed.
- `fleet-code-review` carries the section as a generated include.
`local-strict-review` asks after races, coercions, and platform
differences only where the deployment can produce one, and
`pr-review-conduct` routes a ruled-out hardening finding to an
evidence-backed decline.
- Declared in `spec/files.json` and `spec/section-model.md`, and routed
from `AGENTS.md`. The section is verbatim, so it re-vendors across the
fleet on the next resync.

Closes #2501.

## Verification

- Every check on #2507 passed. Copilot's review covered all 20 changed
files, and its one finding was fixed and resolved.
- Five `local-strict-review` passes ran. The last two found nothing.

🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants