Skip to content

[finding] service-settings' route ledger has no conformance guard — the pattern every sibling ledger follows is silently missing here #17062

Description

@os-trump

Found while establishing whether the dispatcher registry exposes routes for #17041 (per-route ledger completeness). Filed unassigned, no labels — a by-product observation, not a claim on anyone's time.

What was measured

origin/main @ 041d9fdc6. Every OTHER package that owns a *-route-ledger.ts pairs it with a *-route-ledger.conformance.test.ts that enumerates the package's real mounts (a capturing IHttpServer, a driven plugin lifecycle, a source-text scan, or — for plugin-auth — the live auth.api table) and diffs it against the ledger, both directions:

packages/cli/src/utils/console-route-ledger.{ts,conformance.test.ts}
packages/cloud-connection/src/cloud-connection-route-ledger.{ts,conformance.test.ts}
packages/metadata/src/metadata-route-ledger.{ts,conformance.test.ts}
packages/plugins/plugin-auth/src/auth-route-ledger.{ts,conformance.test.ts}
packages/rest/src/rest-route-ledger.{ts,conformance.test.ts}
packages/runtime/src/route-ledger.{ts,conformance.test.ts}
packages/services/service-datasource/src/datasource-route-ledger.{ts,conformance.test.ts}
packages/services/service-i18n/src/i18n-route-ledger.{ts,conformance.test.ts}
packages/services/service-storage/src/storage-route-ledger.{ts,conformance.test.ts}
packages/triggers/trigger-api/src/trigger-api-route-ledger.{ts,conformance.test.ts}

packages/services/service-settings/src/settings-route-ledger.ts has no settings-route-ledger.conformance.test.ts anywhere in the tree:

$ grep -rln "SETTINGS_ROUTE_LEDGER" packages/
packages/qa/dogfood/test/route-ledger-live-mount-parity.dogfood.test.ts
packages/services/service-settings/src/settings-route-ledger.ts

settings-routes.test.ts (the package's route-behavior test) never references SETTINGS_ROUTE_LEDGER either — it is not a renamed equivalent.

The one thing that reads SETTINGS_ROUTE_LEDGER today, route-ledger-live-mount-parity.dogfood.test.ts (#7526), only checks that each declared row still resolves on a live boot — the direction "a route this package now mounts has no ledger row" is unchecked by anything, in either direction, for this one package.

This predates #11882 (which ledgered the six raw-app mounters that had no ledger at all — cloud-connection, metadata, cli): #11882's own measurement already lists service-settings among the seven ledgers it grepped for hits, i.e. the ledger already existed then. The missing conformance test is a separate, older gap that #11882 was not scoped to close.

Why this fits the declared pattern rather than a style nit

Every sibling's conformance-test docstring frames itself as mirroring the others ("mirroring the storage (#3636) and i18n (#3636) guards", "in the #3636 / #11863 pattern") — a declared, repeated contract that a route ledger ships with a guard. service-settings is the one file that carries the data half of that contract with none of the verification half: its SETTINGS_ROUTE_LEDGER rows can drift stale, and a new settings route can land unledgered, with every test in the repo green.

Not proposed here

Which shape fits best — a capturing-mock test like storage/i18n/datasource, or a source-scan like cli/metadata/trigger-api's second limb — is a design call depending on how settings-routes.ts registers (not traced here). The measurement is the contribution.


Generated by Claude Code

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions