Skip to content

fix(app-repo): count an idempotent skill re-install as applied, not "unaccounted for" - #90

Merged
rubenvdlinde merged 2 commits into
developmentfrom
fix/adopt-skill-update-counts
Aug 2, 2026
Merged

fix(app-repo): count an idempotent skill re-install as applied, not "unaccounted for"#90
rubenvdlinde merged 2 commits into
developmentfrom
fix/adopt-skill-update-counts

Conversation

@rubenvdlinde

Copy link
Copy Markdown
Contributor

A regression I introduced with hermiq's idempotent installer (ConductionNL/hermiq#112), caught by reading the seam rather than by any failing test.

The defect

The applier read only installed from hermiq's response. Once hermiq stopped duplicating skills, a re-install of a bundle already present reports:

installed: 0   updated: 0   unchanged: 94

So the applier accounted for 0 of 94 declared items and absorbed the shortfall as not-accounted-for-by-sourcea loud failure banner on a perfectly good run, and precisely the kind of false alarm that trains people to ignore the report.

The fix

"Present as intended" is installed + updated + unchanged. The source's own breakdown is carried through unflattened in sourceCounts, so a first install and a no-op re-run stay distinguishable rather than collapsing into one total.

Mutation-checked: reverting to created: $installed turns the new test red (0 vs 2).

Also: the skills channel moved to its own delegate

Talking to another app across an optional-dependency boundary is a different responsibility from applying OpenRegister channels — and phpmd flagged the applier at 51 > 50 when the mapping was added inline. A real split, not a suppression.

The applier's tests compose the real SkillChannelDelegate rather than a mock, so the degradation and count assertions keep biting.

754 tests OK · phpstan 0 · phpcs 0 · phpmd 0.

…unaccounted for"

A regression I introduced with hermiq's idempotent installer, caught by reading
the seam rather than by any failing test.

The applier read only `installed` from hermiq's response. Once hermiq stopped
duplicating skills, a re-install of a bundle already present reports

    installed: 0   updated: 0   unchanged: 94

so the applier accounted for 0 of 94 declared items and absorbed the shortfall as
"not-accounted-for-by-source" — a loud failure banner on a perfectly good run,
and precisely the kind of false alarm that trains people to ignore the report.

"Present as intended" is installed + updated + unchanged. The source's own
breakdown is now carried through unflattened in `sourceCounts`, so a first install
and a no-op re-run stay distinguishable instead of collapsing into one total.

Mutation-checked: reverting to `created: $installed` turns the new test red
(0 vs 2).

The skills channel moved into its own SkillChannelDelegate — talking to another
app across an optional-dependency boundary is a different responsibility from
applying OpenRegister channels, and phpmd flagged the applier at 51 > 50 when the
mapping was added inline. A real split, not a suppression; the applier's tests
compose the REAL delegate so the degradation and count assertions keep biting.

754 tests OK, phpstan 0, phpcs 0, phpmd 0.
@github-actions

github-actions Bot commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/openbuild @ 4e9148f

Check PHP Vue Security License Tests
lint
phpcs
phpmd
psalm
phpstan
phpmetrics
eslint
stylelint
composer ✅ 100/100
npm
PHPUnit ⏭️
Newman ⏭️
Playwright ⏭️

Quality workflow — 2026-08-02 11:22 UTC

Download the full PDF report from the workflow artifacts.

@rubenvdlinde
rubenvdlinde merged commit bd2a8a1 into development Aug 2, 2026
20 of 25 checks passed
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