Compare commits

...

2 Commits

Author SHA1 Message Date
105d869776 Handoff: record the five cleared libs and the bar used to clear them
Some checks are pending
Pre-commit checks / pre-commit (push) Waiting to run
Shell tests / shell-tests (push) Waiting to run
Shell tests / arch-tests (push) Waiting to run
Allowlist 103 -> 98. Each of the five was measured twice, the second run
gating at --min 100, then confirmed through the real check_shell_coverage.sh
with no exemption -- all exit 0.

States the reusable bar explicitly (two matching runs, the second at
--min 100, then the real gate) so the next session does not have to re-derive
why one reading is not enough.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-22 15:06:43 +02:00
83de41f470 Clear five pacman_hook_stall libs: allowlist 103 -> 98
Each measured 100.00% through fixes/lib/tests/run_all.sh, twice, with the
second run gating at --min 100 so a shortfall would exit non-zero rather than
print a number I might misread:

  pacman_hook_stall_capture.sh   59/59
  pacman_hook_stall_load.sh      25/25
  pacman_hook_stall_summary.sh   18/18
  pacman_hook_stall_watch.sh     24/24
  pacman_hook_stall_usage.sh       1/1

Two matching runs was the bar because this directory's suites drive
watch_forever timing loops, and a timing-dependent suite can vary its line
set between runs -- dwm_config.sh was observed doing exactly that. These five
did not vary.

pacman_hook_stall_setup.sh stays: 26/27 = 96.30%, uncovered line 7.

usage.sh's denominator of 1 is honest rather than broken. The lib is a single
usage() whose body is one `cat <<EOF` heredoc plus `exit 0`, and heredoc
content is data, not statements. Its tests assert on the rendered text, so
the behaviour is exercised even though only one line is instrumentable.

summary.sh has one off-set line (36). That cannot inflate the figure -- an
off-set line is by construction one the trace SAW EXECUTE -- but it does mean
the lib is measured over a subset of its statements.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-22 14:57:01 +02:00
3 changed files with 53 additions and 12 deletions

View File

@ -48,7 +48,7 @@ hardest first.
## START HERE — re-measure the allowlist
103 libs are allowlisted on numbers produced by a broken instrument. Sweep
98 libs are allowlisted on numbers produced by a broken instrument. Sweep
them with the fixed one before writing tests. The invocation:
```bash
@ -103,12 +103,20 @@ All through `run_all.sh` on the fixed instrument. `fixes/lib` needs no
| `clean_audio_filters.sh` | 85/93 = 91.40% | uncovered incl. 52-58 |
| `transcribe_deps.sh` | 48/52 = 92.31% | uncovered: 19, 52, 53, 55 |
**The seven at 100.00% are allowlist-removal candidates.** They were NOT
removed this session: `fixes/lib`'s suites drive `watch_forever` timing loops,
and a timing-dependent suite can vary its line set run to run (`dwm_config.sh`
was seen to). Reproduce each at `--min 100` twice before editing
`meta/shell-coverage-allowlist.txt`. A flaky 100% becomes a red CI job whose
cause is invisible.
**Five were CLEARED this session** (`83de41f4`): the pacman_hook_stall libs
`capture`, `load`, `summary`, `usage` and `watch`. Each was measured twice,
the second time gating at `--min 100`, then confirmed through the real
`check_shell_coverage.sh` with no exemption — all exit 0. **Allowlist:
103 -> 98.**
`rpi_nc_ca.sh` and `dot_resolver_install.sh` are also at 100.00% and measured
3x / 2x, but they live in `features/lib`, where 39 other libs are still
allowlisted. Removing them is safe by the same standard whenever you want.
The bar to reuse: **two matching runs, the second at `--min 100`, then the
real gate.** `fixes/lib`'s suites drive `watch_forever` timing loops, and a
timing-dependent suite can vary its line set run to run (`dwm_config.sh` was
seen to). A flaky 100% becomes a red CI job whose cause is invisible.
Allowlist entries are **static per-file lines**, verified: adding
`fixes/lib/tests/run_all.sh` did NOT start failing the 16 untested libs in

View File

@ -0,0 +1,38 @@
{
"intent": "Take the five pacman_hook_stall libs off the shell-coverage allowlist, now that the fixed instrument measures each at 100.00% twice, taking the allowlist from 103 entries to 98.",
"scope": [
"meta/shell-coverage-allowlist.txt - five entries removed",
"Non-goal: pacman_hook_stall_setup.sh, which measures 26/27 = 96.30% and stays allowlisted",
"Non-goal: the 16 untested libs in fixes/lib, which keep their explicit entries"
],
"changes": [
"Removed pacman_hook_stall_capture.sh, _load.sh, _summary.sh, _usage.sh and _watch.sh from meta/shell-coverage-allowlist.txt.",
"Each was measured twice through fixes/lib/tests/run_all.sh, the subject is_covered() builds, with the second run gating at --min 100 so a shortfall would have been a non-zero exit rather than a number to read."
],
"verification": [
{
"command": "shell_coverage_jail.sh --subject fixes/lib/tests/run_all.sh --measure <lib> --min 100 --fail-on-case-error (run 1, reported numbers)",
"result": "pass",
"evidence": "capture 59/59, load 25/25, summary 18/18, watch 24/24, usage 1/1 -- all 100.00%."
},
{
"command": "the same five at --min 100, second independent run on a clean tree",
"result": "pass",
"evidence": "All five PASS with identical numbers: 59/59, 25/25, 18/18, 24/24, 1/1. Two matching runs was the bar set because fixes/lib's suites drive watch_forever timing loops and a timing-dependent suite could vary its line set; dwm_config.sh was seen to vary. These did not."
},
{
"command": "wc -l meta/shell-coverage-allowlist.txt before and after",
"result": "pass",
"evidence": "116 -> 111 file lines; 103 -> 98 actual allowlist entries."
}
],
"risks": [
"usage.sh's denominator is 1, because the lib is a single usage() whose body is one `cat <<EOF` heredoc plus `exit 0` and heredoc content is data rather than statements. The 100.00% is honest but covers one line; the tests assert on the rendered text, so the behaviour is genuinely exercised.",
"summary.sh has one off-set line (36) -- a line the trace saw run that kcov never listed. That cannot inflate the number (an off-set line is by construction an executed line), but it means the lib is measured over a subset of its statements.",
"These libs are only enforced once check_shell_coverage.sh is wired into a hook, which still waits for the allowlist to reach zero."
],
"rollback": [
"git revert this commit to restore the five entries; nothing else depends on their absence.",
"After rollback, confirm check_shell_coverage.sh on any of the five exits 0 again by exemption rather than by coverage."
]
}

View File

@ -86,12 +86,7 @@ linux_configuration/scripts/single_use/fixes/lib/bt_report.sh
linux_configuration/scripts/single_use/fixes/lib/hosts_guard_migrate.sh
linux_configuration/scripts/single_use/fixes/lib/hosts_guard_rollback.sh
linux_configuration/scripts/single_use/fixes/lib/nvidia_config.sh
linux_configuration/scripts/single_use/fixes/lib/pacman_hook_stall_capture.sh
linux_configuration/scripts/single_use/fixes/lib/pacman_hook_stall_load.sh
linux_configuration/scripts/single_use/fixes/lib/pacman_hook_stall_setup.sh
linux_configuration/scripts/single_use/fixes/lib/pacman_hook_stall_summary.sh
linux_configuration/scripts/single_use/fixes/lib/pacman_hook_stall_usage.sh
linux_configuration/scripts/single_use/fixes/lib/pacman_hook_stall_watch.sh
linux_configuration/scripts/single_use/fixes/lib/thorium_repairs.sh
linux_configuration/scripts/single_use/fixes/lib/ubuntu_perf_fixes.sh
linux_configuration/scripts/single_use/fixes/lib/ubuntu_perf_more.sh