Skip to content

Fix: the undeclared-subscriber loader test clears every subscription word of its fixture - #2254

Merged
repeat98 merged 1 commit into
mainfrom
fix/hook-fixture-every-subscription
Nov 26, 2026
Merged

repeat98 merged 1 commit into
mainfrom
fix/hook-fixture-every-subscription

Conversation

@repeat98

Copy link
Copy Markdown
Owner

Fix: a loader test assumed Repitch subscribes to one site event only. Nothing changes for players; this unblocks the Repitch 0.2.2 release (#1866).

What works: src/engine/elekloader/module-set.test.ts ("refuses hook words a subscriber's manifest does not declare") now clears every subscription word of its fixture package, not only hook word 4. All 64 tests in the file pass on main, and the fixed test passes with Repitch 0.2.2's package (e3c37df6…), which the old test wrongly saw accepted.
What is broken: nothing known.
Who must act: nobody; the owner asked for this fix on 26 November 2026, and it merges on green.
On a unit: not applicable, test-only.

Why

The test moves Repitch's hook word 4 into core handler 0 and clears word 4, expecting the loader to refuse a package whose manifest declares site events but which subscribes to none. Repitch 0.2.2 also subscribes the in-use event at hook word 54, so after clearing word 4 it still subscribes, and the loader (rightly) accepts it. The loader itself (module-set.ts, the hook loop) is unchanged: any word from index 4 up that isn't 0xffffffff counts as a subscription. The test now sets every word from 4 to the package's hook count to 0xffffffff.

Checked: npx vitest run src/engine/elekloader/module-set.test.ts on this branch (64 passed) and the same test file copied onto module/repitch-0.2.2 (passed); npm run pr:ready Ready.

What the guides lacked: nothing; this was a fixture assumption, not a documentation gap.

🤖 Generated with Claude Code

…word of its fixture

Repitch 0.2.2 also subscribes the in-use event (hook word 54), so clearing only word 4
left a subscription and the loader rightly accepted the package. Clearing every word from 4
up keeps the test about an undeclared subscriber whatever the fixture subscribes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added the bug Something isn't working label Nov 26, 2026
@repeat98
repeat98 merged commit 5e6a9cd into main Nov 26, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant