feat(celilo)!: move to @celilo/capabilities 2.0.0, drop the on_uninstall hook #51

Merged
forgejo-admin merged 1 commit from caps2-lunacycle into main 2026-08-17 21:28:14 +00:00

celilo v1.0.0 ships @celilo/capabilities 2.0.0, which takes withdrawal off the
consumer-facing capability surface. Removing a module now dispatches
on_consumer_removed to every provider of every capability it declared, and each
provider withdraws what it minted. PublicWebCapability.unregister_routes is gone.

This repo was pinned to ^0.5.0, several majors behind.

What changed

  • celilo/scripts/package.json: @celilo/capabilities ^0.5.0^2.0.0, lockfile refreshed.
  • Deleted teardown-web.ts and teardown-web.test.ts. The whole on_uninstall hook existed only to call unregister_routes; caddy withdraws lunacycle's routes itself now.
  • Removed the on_uninstall entry from manifest.yml. A hook entry pointing at a deleted script fails the whole module load.
  • Removed the stale unregister_routes spy from setup-web.test.ts.
  • No alias, no shim, no compatibility fallback.

New gate

manifest-cd.test.ts asserted that on_backup and on_restore point at real
files. It now asserts that every declared hook does. Deleting a script and
forgetting its manifest entry is the easy half of this mistake to make, and the
consequence is a module that will not load at all.

Proved the check fails: re-added the on_uninstall entry pointing at the deleted
teardown-web.ts and the run went red on on_uninstall script exists on disk,
then restored.

Not changed, deliberately

requires.capabilities.public_web stays at 3.0.0. capabilities 2.0.0 declares
the contract at 3.1.0 — same major, and nothing lunacycle calls moved. The
deployed caddy (2.3.0) satisfies it.

The other 2.0.0 breaking changes (FirewallCapability, RegisterTrustedSourceRequest.subnets,
IssueRunnerTokenRequest.runnerName, PortForward.registeredBy) do not appear
anywhere in celilo/ — grepped.

Version

Changeset says minor. It removes a declared hook from the manifest and raises
the module's floor to celilo 1.0.0, which is more than a bug fix. Not major: the
fleet is already on celilo 1.0.0 with caddy redeployed at 2.3.0, so the provider
side of on_consumer_removed is live.

Gates

  • test:hooks — 62 pass, 0 fail
  • test:unit — 117 pass, 0 fail, 3 todo
  • typecheck — 0 errors
  • lint — 0 errors

Scope is celilo/ plus the manifest and the changeset. The lunacycle application
itself is untouched.

🤖 Generated with Claude Code

celilo v1.0.0 ships `@celilo/capabilities` 2.0.0, which takes withdrawal off the consumer-facing capability surface. Removing a module now dispatches `on_consumer_removed` to every provider of every capability it declared, and each provider withdraws what it minted. `PublicWebCapability.unregister_routes` is gone. This repo was pinned to `^0.5.0`, several majors behind. ## What changed - `celilo/scripts/package.json`: `@celilo/capabilities` `^0.5.0` → `^2.0.0`, lockfile refreshed. - Deleted `teardown-web.ts` and `teardown-web.test.ts`. The whole `on_uninstall` hook existed only to call `unregister_routes`; caddy withdraws lunacycle's routes itself now. - Removed the `on_uninstall` entry from `manifest.yml`. A hook entry pointing at a deleted script fails the whole module load. - Removed the stale `unregister_routes` spy from `setup-web.test.ts`. - No alias, no shim, no compatibility fallback. ## New gate `manifest-cd.test.ts` asserted that `on_backup` and `on_restore` point at real files. It now asserts that **every** declared hook does. Deleting a script and forgetting its manifest entry is the easy half of this mistake to make, and the consequence is a module that will not load at all. Proved the check fails: re-added the `on_uninstall` entry pointing at the deleted `teardown-web.ts` and the run went red on `on_uninstall script exists on disk`, then restored. ## Not changed, deliberately `requires.capabilities.public_web` stays at `3.0.0`. capabilities 2.0.0 declares the contract at `3.1.0` — same major, and nothing lunacycle calls moved. The deployed caddy (2.3.0) satisfies it. The other 2.0.0 breaking changes (`FirewallCapability`, `RegisterTrustedSourceRequest.subnets`, `IssueRunnerTokenRequest.runnerName`, `PortForward.registeredBy`) do not appear anywhere in `celilo/` — grepped. ## Version Changeset says **minor**. It removes a declared hook from the manifest and raises the module's floor to celilo 1.0.0, which is more than a bug fix. Not major: the fleet is already on celilo 1.0.0 with caddy redeployed at 2.3.0, so the provider side of `on_consumer_removed` is live. ## Gates - `test:hooks` — 62 pass, 0 fail - `test:unit` — 117 pass, 0 fail, 3 todo - `typecheck` — 0 errors - `lint` — 0 errors Scope is `celilo/` plus the manifest and the changeset. The lunacycle application itself is untouched. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
feat(celilo)!: move to @celilo/capabilities 2.0.0, drop the on_uninstall hook
All checks were successful
pr-validate / validate (pull_request) Successful in 42s
e2225918a6
capabilities 2.0.0 deletes the consumer-facing withdrawal methods. Removing a
module now dispatches on_consumer_removed to every provider it declared, and
each provider withdraws what it minted — so PublicWebCapability.unregister_routes
is gone, and the on_uninstall hook that called it has nothing left to do. caddy
withdraws lunacycle's routes itself.

Deleted rather than stubbed: teardown-web.ts, teardown-web.test.ts, the manifest
hook entry, and the stale unregister_routes spy in setup-web.test.ts. No alias,
no shim.

manifest-cd.test.ts now asserts that EVERY declared hook's script exists on disk,
not just on_backup/on_restore. A hook entry pointing at a deleted file fails the
whole module load, and deleting the script while leaving the entry is the easy
half of the mistake to make. Verified the check goes red by re-adding the entry.

public_web stays pinned at 3.0.0: the contract is 3.1.0 in capabilities 2.0.0,
same major, and nothing lunacycle calls moved.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Sign in to join this conversation.
No description provided.