Skip to content

Fix: published-package test counts only site-event hook words past the four UI handlers - #1301

Merged
repeat98 merged 2 commits into
repeat98:mainfrom
imdantelo:fix/titled-package-hook-words
Nov 7, 2026
Merged

repeat98 merged 2 commits into
repeat98:mainfrom
imdantelo:fix/titled-package-hook-words

Conversation

@imdantelo

Copy link
Copy Markdown
  • What was wrong or hard: src/engine/elekloader/module-set.test.ts treats any hook words in a published package as site events: view.getUint32(20) > 0 must match features bit 128. Since Fix: publish an Octatrack C module with no event subscriptions over USB (ABI 8, named) #1231, npm run octatrack:module-packages repacks a C package with no events as ABI 8 (titled()). That package keeps its UI handler words (module_tick, module_draw, module_key, module_enc) and subscribes to nothing. The builder gives it features 0, which is correct: module_packages.py sets 128 only for hook words past the first four. The test then fails for the first such package, Tiempos (Tiempos 0.1.0-experimental: time left on all eight tracks (USB only) #1096: 4 hook words, features 0).
  • What this changes: the assertion counts only hook words past the four UI handlers (> 4), as the builder does, and gets a changelog entry. No package, builder or site code changes.
  • How I checked it: npx vitest run src/engine/elekloader/module-set.test.ts on this branch: 61/61 pass. Every published package on main fits the new rule: the ones with bit 128 have 5 to 37 hook words, and every other one has 0. On the Tiempos branch, with Tiempos's package added, the full suite passes this test; its only other failures are the date-dependent PageTraffic/community-activity tests and spectrum in module-doctor.test.mjs, which fail the same way on main. I did not run npm run pr:ready on this branch.
  • What the guides lacked or got wrong, and where I fixed it: nothing.

Related to #1096

🤖 Generated with Claude Code

…e four UI handlers

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@repeat98
repeat98 enabled auto-merge November 7, 2026 14:26
@repeat98

repeat98 commented Nov 7, 2026

Copy link
Copy Markdown
Owner

Thanks Diego, that's right. Since #1231, titled() drops trailing empty hook words, so a package has more than four exactly when it subscribes to a site event, which is what module_packages.py checks for bit 128. I'll merge this once its checks are green.

@repeat98
repeat98 merged commit fda8c69 into repeat98:main Nov 7, 2026
8 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.

2 participants