Skip to content

build: align public text reporting - #5113

Merged
jakildev merged 1 commit into
masterfrom
claude/5095-public-text-reporting
Nov 17, 2026
Merged

jakildev merged 1 commit into
masterfrom
claude/5095-public-text-reporting

Conversation

@jakildev

Copy link
Copy Markdown
Owner

Summary

  • Resolve public-text term files through one helper used by the checker and health report.
  • Report public-text lint findings with their title or body source and original line number.
  • Cover override/default resolution and source-aware diagnostics with hermetic regressions.

Test plan

  • python3 scripts/fleet/tests/test_fleet_health.py
  • python3 scripts/fleet/tests/test_fleet_pr_closes_lint.py
  • bash scripts/fleet/tests/run_all.sh --only fleet_health
  • bash scripts/fleet/tests/run_all.sh --only closes_lint
  • bash scripts/fleet/tests/run_all.sh --only public_text
  • ruff check scripts/
  • python3 scripts/light-verify.py --if-changed

Acceptance evidence

Criterion Check run Observed
Health reports the override and HOME default term paths python3 scripts/fleet/tests/test_fleet_health.py 77 tests passed; new override and default-path cases pass.
Health and checker share term-file resolution python3 scripts/fleet/tests/test_fleet_health.py Override path is reported configured through term_file_path.
Closes lint names title/body source with local line numbers python3 scripts/fleet/tests/test_fleet_pr_closes_lint.py 40 tests passed; title and body line-1 findings are asserted.
Positive controls fire on master and pass on this head fleet-positive-control for both affected suites Health: 24 of 77 assertions red on master; closes lint: source-label regression red on master, 40 tests pass on head.
Affected fleet suites pass run_all.sh --only fleet_health, --only closes_lint, --only public_text 1/1, 1/1, and 2/2 suites passed.

Notes for reviewer

fleet-pr-overlap --base master --repo engine reported clean shared paths with #5110 (scripts/fleet/fleet-health and its test).

Closes #5095

Authored with Codex (runtime: codex).

Resolve the configured term file through one helper so health exposes the same file applied by the public-text checker.\n\nReport public-text violations against independently scanned title and body text, preserving each source's own line numbering.
@jakildev jakildev added fleet:author-codex Implementation last authored by Codex; route review to Claude fleet:authored-on-macos PR was authored and smoke-tested on macOS Metal backend labels Nov 16, 2026

@jakildev jakildev left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Review — build: align public text reporting

Verdict: approve

Does what #5095 asks, and the approach is sound. term_file_path() is now the single resolver (explicit arg, then FLEET_PUBLIC_TEXT_TERM_FILE, then ~/.fleet/public-text-terms). find_public_text, the module CLI and fleet-health all call it, so the health line and the checker cannot drift. fleet-pr-closes-lint now scans title and body separately, so body line numbers match the body file and each finding names its source.

Checked on head 6bfdd8eb9:

  • python3 scripts/fleet/tests/test_fleet_health.py — 77 tests OK (1 skipped, unrelated to this diff).
  • python3 scripts/fleet/tests/test_fleet_pr_closes_lint.py — 40 tests OK.
  • run_all.sh --only public_text — 2/2 suites pass.
  • ruff check scripts/ — clean.
  • No remaining references to the removed DEFAULT_TERM_FILE in scripts/, docs/ or .claude/.
  • fleet-issue and fleet-pr-body-lint still call format_finding unchanged, so their output is unaffected.
  • The CLI's --term-file default moved from an eager env read to None plus resolution in term_file_path. Behavior is the same, and an explicit flag still wins.

CI: all completed checks are green. fleet-tests (and the all-checks gate behind it) were still pending when I read them, so I did not read them as green.

Acceptance (issue #5095)

Criterion Status Basis
Health test: override path reported, configured true met test_public_text_term_file_override_is_reported
Health test: default under the suite's temp HOME met test_public_text_term_file_is_informational now pins HOME and asserts the default path
One shared term-file resolver met term_file_path is used by fleet_public_text and fleet-health
Closes-lint reports title line 1 / body line 1 met test_public_text_findings_name_the_title_or_body_source
Positive controls red on master, green on head unverified by me the PR evidence table reports it (24/77 health assertions red on master; the closes-lint source-label case red). The assertions are shaped to fail against the old code, since the old output had neither a source label nor correct body numbering.
run_all.sh --only fleet_health / closes_lint / public_text pass met for public_text (run here); the other two are covered by the direct suite runs above

Nits (follow-up)

  • scripts/fleet/fleet-pr-closes-lint:255-262 — find_public_text now runs twice, so _ignored_creation_paths shells out to git twice per PR. This is negligible for a lint, and the two runs are needed for per-source line numbers. Mentioning it only so a future refactor can fold the loop if the cost ever matters.

Test plan the author should run before merge

  • Confirm fleet-tests goes green on the head.

Escalation: none. Safe for merge.

🤖 Reviewed by Claude Sonnet 5.5 (review-pr skill)

Opus recheck not required.

@jakildev jakildev added fleet:approved Fleet reviewer approved — ready for human merge and removed fleet:reviewing-mac-pool-4 labels Nov 16, 2026
@jakildev
jakildev merged commit f3ff5a8 into master Nov 17, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fleet:approved Fleet reviewer approved — ready for human merge fleet:author-codex Implementation last authored by Codex; route review to Claude fleet:authored-on-macos PR was authored and smoke-tested on macOS Metal backend

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fleet: health line ignores the public-text term-file override, and closes-lint numbers body findings from the title

1 participant