The TypeScript toolchain holds pg, mongodb and mssql, so a catalogue check can check the modules that use them (issue 385) #31

Merged
mesh-admin merged 1 commits from fix/385-an-untestable-module-fails-the-check into main 2026-10-12 10:46:07 +00:00
Contributor

Part of issue 385 (a merge check that reports NOT TESTED still passes), with mesh-catalog #231 and mesh-media-catalog #30. All three are on the same branch name, so they form one delivery group.

Why

mesh-catalog's merge-check-typescript.sh fetches nothing. It copies the toolchain image's /app/node_modules beside a module. With #231, a module that depends on a package the toolchain does not hold fails its check instead of passing with "NOT CHECKED". Today's toolchain holds only the SDK, nats, @types/node, typescript and esbuild. Without this change, four modules could never merge again: mesh-catalog and model-usage (pg), mongodb (mongodb) and mssql (mssql). Review 19 on #231 found this.

What changes

  • node-tools/package.json: pg ^8, mongodb ^6.21.0 and mssql ^11.0.2 are added as devDependencies, with the same ranges the modules declare. The lean stage (npm prune --omit=dev) drops them, so the runtime image and the /app/runtime that bundles carry stay as they are. Only the toolchain stage's /app/node_modules gains them.
  • No @types packages: mongodb ships its own types, and mesh-catalog, model-usage and mssql declare pg / mssql in their own pg.d.ts / mssql.d.ts.
  • Dockerfile: a comment on the toolchain stage says why they are there.
  • I did not touch node-tools/package-lock.json. The Dockerfile does not read it, and it was already stale (it has no esbuild). From this machine the package registry refused TLS, so I could not regenerate it.

How it was tested

I emulated the change on the current toolchain image (mesh-tools-build:4348b428, built 2026-10-12 02:30). A derived image installs the same three ranges from npm and hoists them into /app/node_modules. In it, mesh-catalog #231's merge-check-typescript.sh ran with MESH_CHECK_MODULES=mesh-catalog,model-usage,mongodb,mssql:

  • current toolchain: all four FAILED: … depends on pg|mongodb|mssql, which the toolchain does not hold, exit 1;
  • with this change: all four are type-checked; model-usage 6 pass + 1 skipped (no TEST_DATABASE_URL); mssql 4 pass; mesh-catalog and mongodb say NOT TESTED (no tests of their own); exit 0.
  • Over every TypeScript module of mesh-catalog, nothing new fails. nftables (one test about sudo, run here as root) and showcase (type errors against the current SDK) fail with and without this change. Both failures were already there, and neither is about dependencies.

I did not build the real Dockerfile here, because its deps stage needs the registry credential.

Reviewers' checklist

  • devDependencies only: the runtime stage and /app/runtime stay unchanged.
  • Ranges match the modules' own package.json.
  • After merge and the toolchain rebuild, #231's TypeScript part checks the four modules (not FAILED).
  • Checks green.

Fixes issue 385 (with mesh-catalog #231 and mesh-media-catalog #30).

Part of issue 385 (a merge check that reports NOT TESTED still passes), with mesh-catalog #231 and mesh-media-catalog #30. All three are on the same branch name, so they form one delivery group. ## Why mesh-catalog's `merge-check-typescript.sh` fetches nothing. It copies the toolchain image's `/app/node_modules` beside a module. With #231, a module that depends on a package the toolchain does not hold fails its check instead of passing with "NOT CHECKED". Today's toolchain holds only the SDK, nats, @types/node, typescript and esbuild. Without this change, four modules could never merge again: mesh-catalog and model-usage (`pg`), mongodb (`mongodb`) and mssql (`mssql`). Review 19 on #231 found this. ## What changes - `node-tools/package.json`: `pg ^8`, `mongodb ^6.21.0` and `mssql ^11.0.2` are added as **devDependencies**, with the same ranges the modules declare. The `lean` stage (`npm prune --omit=dev`) drops them, so the runtime image and the `/app/runtime` that bundles carry stay as they are. Only the toolchain stage's `/app/node_modules` gains them. - No `@types` packages: mongodb ships its own types, and mesh-catalog, model-usage and mssql declare `pg` / `mssql` in their own `pg.d.ts` / `mssql.d.ts`. - `Dockerfile`: a comment on the toolchain stage says why they are there. - I did not touch `node-tools/package-lock.json`. The Dockerfile does not read it, and it was already stale (it has no esbuild). From this machine the package registry refused TLS, so I could not regenerate it. ## How it was tested I emulated the change on the current toolchain image (`mesh-tools-build:4348b428`, built 2026-10-12 02:30). A derived image installs the same three ranges from npm and hoists them into `/app/node_modules`. In it, mesh-catalog #231's `merge-check-typescript.sh` ran with `MESH_CHECK_MODULES=mesh-catalog,model-usage,mongodb,mssql`: - current toolchain: all four `FAILED: … depends on pg|mongodb|mssql, which the toolchain does not hold`, exit 1; - with this change: all four are type-checked; model-usage 6 pass + 1 skipped (no TEST_DATABASE_URL); mssql 4 pass; mesh-catalog and mongodb say NOT TESTED (no tests of their own); exit 0. - Over every TypeScript module of mesh-catalog, nothing new fails. nftables (one test about sudo, run here as root) and showcase (type errors against the current SDK) fail with and without this change. Both failures were already there, and neither is about dependencies. I did not build the real Dockerfile here, because its `deps` stage needs the registry credential. ## Reviewers' checklist - [ ] devDependencies only: the runtime stage and `/app/runtime` stay unchanged. - [ ] Ranges match the modules' own package.json. - [ ] After merge and the toolchain rebuild, #231's TypeScript part checks the four modules (not FAILED). - [ ] Checks green. Fixes issue 385 (with mesh-catalog #231 and mesh-media-catalog #30).
mesh-admin added 1 commit 2026-10-12 10:28:25 +00:00
Give the TypeScript toolchain pg, mongodb and mssql, so a catalogue check can type-check the modules that use them (issue 385)
mesh/merge-gate pass: builds mesh-tools, sent nowhere; no bus step; every machine composes with the change as it did without (4 of 4 compose)
mesh/repo-check pass: its merge-check.sh passed
mesh/delivery delivered
mesh/delivery-group group fix/385-an-untestable-module-fails-the-check merged: every member is merged
847055c758
A catalogue's TypeScript check fetches nothing and reads this image's
node_modules. Once a module it cannot check fails rather than passing with a
note, mesh-catalog, model-usage, mongodb and mssql could never merge again.
They are development dependencies, so the runtime image stays as it is.
Author
Contributor

Delivery novox/mesh-tools@847055c7588a — delivered since 2026-10-12T10:50:10Z

Delivery plan — builds mesh-tools, sent nowhere; no bus step

  • tier 0: mesh-tools

Group fix/385-an-untestable-module-fails-the-check, in order: novox/mesh-catalog@de8a866189 → novox/mesh-media-catalog@8441a50e41 → novox/mesh-tools@847055c758

  • composed together: pass — every machine composes with the change as it did without (4 of 4 compose)

Machines

  • mesh-tools on every machine running it: sent

Transitions

  • 2026-10-12 10:28 (new) → proposed (announced): novox/mesh-tools#31's head announced
  • 2026-10-12 10:31 proposed → checked (checked): the verdict names this commit
  • 2026-10-12 10:31 checked → ready (accepted): the gate passed or warned, and the repository's own check did not fail
  • 2026-10-12 10:47 ready → published (merged): on the trunk its modules follow: merged there, and its walk opened — or nothing for a walk to move
  • 2026-10-12 10:48 published → delivering (go): its walk started: let go by this owner in its group's order, by a person, or on the controller's own path — not a failed walk that carried a later commit for it, after which it waits for a walk of its own commit
  • 2026-10-12 10:50 delivering → delivered (done): its walk is done, carrying its own commit: every machine of its deploy plan passed, or was left as its policy says

The commit's note under refs/notes/mesh-plan keeps every transition: git log --notes=mesh-plan.

<!-- mesh-delivery:view --> **Delivery** `novox/mesh-tools@847055c7588a` — **delivered** since 2026-10-12T10:50:10Z **Delivery plan** — builds mesh-tools, sent nowhere; no bus step - tier 0: mesh-tools **Group** `fix/385-an-untestable-module-fails-the-check`, in order: novox/mesh-catalog@de8a8661890e → novox/mesh-media-catalog@8441a50e41c2 → novox/mesh-tools@847055c7588a - composed together: pass — every machine composes with the change as it did without (4 of 4 compose) **Machines** - mesh-tools on every machine running it: sent **Transitions** - 2026-10-12 10:28 (new) → proposed (announced): novox/mesh-tools#31's head announced - 2026-10-12 10:31 proposed → checked (checked): the verdict names this commit - 2026-10-12 10:31 checked → ready (accepted): the gate passed or warned, and the repository's own check did not fail - 2026-10-12 10:47 ready → published (merged): on the trunk its modules follow: merged there, and its walk opened — or nothing for a walk to move - 2026-10-12 10:48 published → delivering (go): its walk started: let go by this owner in its group's order, by a person, or on the controller's own path — not a failed walk that carried a later commit for it, after which it waits for a walk of its own commit - 2026-10-12 10:50 delivering → delivered (done): its walk is done, carrying its own commit: every machine of its deploy plan passed, or was left as its policy says The commit's note under `refs/notes/mesh-plan` keeps every transition: `git log --notes=mesh-plan`.
Author
Contributor

Merge check at 847055c7

  • mesh/merge-gate: PASS — every machine composes with the change as it did without (4 of 4 compose) (modules: mesh-tools)
  • mesh/repo-check: PASS — its merge-check.sh passed

Delivery plan — builds mesh-tools, sent nowhere; no bus step

  • tier 0: mesh-tools

Run by the build seat on shanks as build-1791800933517015291 (builds --log build-1791800933517015291).

--- the gate: mesh-tools
mesh-tools: ok
long-running resources without health: 0
files asking for a setting without saying whether it is trusted: 0
1 manifest(s) checked. Judged against the seats this binary carries; a claim on one of the mesh's own seats is judged fully at registration, and a seat declared by a module not given here reads as unknown. Identities judged on a 6-character machine name, against the bounds of the providers given here
judging 0 module(s) changed against 4 machine(s), as the snapshot of 2026-10-12T10:23:58Z says they run
composing every machine as the mesh is
the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued
the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued
composing every machine with the change
the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued
the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued
merge gate: PASS — every machine composes with the change as it did without (4 of 4 compose)
judged by controller development build against the facts of 2026-10-12T10:23:58Z

machines:
  - a machine (f35): composes
  - holds mesh-dns-resolver (idt): composes
  - holds git, holds mesh-artifact-store, holds mesh-broker, holds mesh-catalog, holds mesh-delivery, holds mesh-dns-resolver, holds mesh-store, holds mesh-vault, holds npm-package-registry, the control node, the hub (ygcyr): composes
  - a machine (yvbpsm): composes

a merge would rebuild 1 module(s) in 1 tier(s): mesh-tools
--- its merge-check.sh (go toolchain)
NOT TESTED HERE: internal/runtime and internal/console launch bundles that need node and @novox/mesh-sdk
?   	github.com/novox/mesh-tools/node-tools/cmd/node-tools	[no test files]
ok  	github.com/novox/mesh-tools/node-tools/internal/alive	1.191s
ok  	github.com/novox/mesh-tools/node-tools/internal/announce	4.371s
ok  	github.com/novox/mesh-tools/node-tools/internal/bus	12.921s
ok  	github.com/novox/mesh-tools/node-tools/internal/launch	1.075s
ok  	github.com/novox/mesh-tools/node-tools/internal/meshtest	1.142s
?   	github.com/novox/mesh-tools/node-tools/internal/wire	[no test files]
ok  	github.com/novox/mesh-tools/node-tools/internal/console	0.005s
ok  	github.com/novox/mesh-tools/node-tools/internal/runtime	2.016s
NOT TESTED HERE: node-tools/src (TypeScript) needs @novox/mesh-sdk from the package registry
**Merge check** at `847055c7` - `mesh/merge-gate`: **PASS** — every machine composes with the change as it did without (4 of 4 compose) (modules: mesh-tools) - `mesh/repo-check`: **PASS** — its merge-check.sh passed **Delivery plan** — builds mesh-tools, sent nowhere; no bus step - tier 0: mesh-tools Run by the build seat on shanks as `build-1791800933517015291` (`builds --log build-1791800933517015291`). ``` --- the gate: mesh-tools mesh-tools: ok long-running resources without health: 0 files asking for a setting without saying whether it is trusted: 0 1 manifest(s) checked. Judged against the seats this binary carries; a claim on one of the mesh's own seats is judged fully at registration, and a seat declared by a module not given here reads as unknown. Identities judged on a 6-character machine name, against the bounds of the providers given here judging 0 module(s) changed against 4 machine(s), as the snapshot of 2026-10-12T10:23:58Z says they run composing every machine as the mesh is the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued composing every machine with the change the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued the bus's user list leaves out 5 user(s) the mesh has minted no credential for: controller, node.f35, node.idt, node.ygcyr, node.yvbpsm. Each is a user that cannot connect until one is issued merge gate: PASS — every machine composes with the change as it did without (4 of 4 compose) judged by controller development build against the facts of 2026-10-12T10:23:58Z machines: - a machine (f35): composes - holds mesh-dns-resolver (idt): composes - holds git, holds mesh-artifact-store, holds mesh-broker, holds mesh-catalog, holds mesh-delivery, holds mesh-dns-resolver, holds mesh-store, holds mesh-vault, holds npm-package-registry, the control node, the hub (ygcyr): composes - a machine (yvbpsm): composes a merge would rebuild 1 module(s) in 1 tier(s): mesh-tools --- its merge-check.sh (go toolchain) NOT TESTED HERE: internal/runtime and internal/console launch bundles that need node and @novox/mesh-sdk ? github.com/novox/mesh-tools/node-tools/cmd/node-tools [no test files] ok github.com/novox/mesh-tools/node-tools/internal/alive 1.191s ok github.com/novox/mesh-tools/node-tools/internal/announce 4.371s ok github.com/novox/mesh-tools/node-tools/internal/bus 12.921s ok github.com/novox/mesh-tools/node-tools/internal/launch 1.075s ok github.com/novox/mesh-tools/node-tools/internal/meshtest 1.142s ? github.com/novox/mesh-tools/node-tools/internal/wire [no test files] ok github.com/novox/mesh-tools/node-tools/internal/console 0.005s ok github.com/novox/mesh-tools/node-tools/internal/runtime 2.016s NOT TESTED HERE: node-tools/src (TypeScript) needs @novox/mesh-sdk from the package registry ```
mesh-admin left a comment
Author
Contributor

Verdict: approve at 847055c758

Independent review for issue 385 (an untestable module fails the check). This resolves the blocking finding of review 19 on mesh-catalog#231.

Checklist

  1. Versions match the modules. pg ^8 (mesh-catalog, model-usage), mongodb ^6.21.0 (mongodb), mssql ^11.0.2 (mssql) are exactly the ranges the four catalogue modules' package.json declare. They resolved to pg 8.23.1, mongodb 6.21.0, mssql 11.0.2 (tedious 18.6.2).
  2. The stale package-lock.json is not read. The deps and compiling stages copy node-tools/package.json only; nothing copies node-tools/package-lock.json, so npm install resolves from package.json.
  3. The image builds. I built the toolchain and runtime targets of this head's Dockerfile with docker. The only emulation: the deps stage cannot reach the mesh's registry without the builder's credential, so I removed @novox/mesh-sdk from the install and copied it (0.1.13) from the current toolchain image (mesh-tools-build:4348b428). Everything else ran as written, including npm run build and npm prune --omit=dev.
  4. The runtime stage prunes them. In the runtime image /app/node_modules and in the toolchain image /app/runtime/node_modules hold 233 files and 2.2 MB, the same as the current toolchain's /app/runtime/node_modules; pg, mongodb, mssql and tedious are absent. The only difference is six empty scope directories that prune leaves behind (@azure, @azure-rest, @js-joda, @mongodb-js, @tediousjs, @typespec), as it already leaves @esbuild and @types. They carry no file.
  5. The toolchain holds them at /app/node_modules. In that image, mesh-catalog#231's merge-check-typescript.sh with MESH_CHECK_MODULES=mesh-catalog,model-usage,mongodb,mssql, without a network, type-checked all four, ran model-usage's tests (6 pass, 1 skipped without TEST_DATABASE_URL) and mssql's (4 pass), and exited 0. In the current toolchain it fails all four by name and exits 1.
  6. Checks on this head: merge-gate pass (builds mesh-tools, sent nowhere, 4 of 4 compose), repo-check pass, delivery ready, delivery-group ready.

Cost, not blocking: the toolchain image grows from 368 MB to 426 MB (its /app/node_modules from 38 MB to 120 MB, mostly mssql's Azure dependencies). No machine runs it; only the build seat pulls it.

Merge order: this must be merged, and its build published, before mesh-catalog#231. A check runs in the toolchain the mesh holds (the one built from main), never in a pull request's head, and the group's composed check runs only the gate, not each repository's check. See the review on #231.

Verdict: approve at 847055c7588af1bac62fb5355a347c335c9c23b9 Independent review for issue 385 (an untestable module fails the check). This resolves the blocking finding of review 19 on mesh-catalog#231. **Checklist** 1. **Versions match the modules.** `pg ^8` (mesh-catalog, model-usage), `mongodb ^6.21.0` (mongodb), `mssql ^11.0.2` (mssql) are exactly the ranges the four catalogue modules' package.json declare. They resolved to pg 8.23.1, mongodb 6.21.0, mssql 11.0.2 (tedious 18.6.2). 2. **The stale package-lock.json is not read.** The deps and compiling stages copy `node-tools/package.json` only; nothing copies `node-tools/package-lock.json`, so `npm install` resolves from package.json. 3. **The image builds.** I built the `toolchain` and `runtime` targets of this head's Dockerfile with docker. The only emulation: the deps stage cannot reach the mesh's registry without the builder's credential, so I removed `@novox/mesh-sdk` from the install and copied it (0.1.13) from the current toolchain image (`mesh-tools-build:4348b428`). Everything else ran as written, including `npm run build` and `npm prune --omit=dev`. 4. **The runtime stage prunes them.** In the runtime image `/app/node_modules` and in the toolchain image `/app/runtime/node_modules` hold 233 files and 2.2 MB, the same as the current toolchain's `/app/runtime/node_modules`; pg, mongodb, mssql and tedious are absent. The only difference is six empty scope directories that prune leaves behind (`@azure`, `@azure-rest`, `@js-joda`, `@mongodb-js`, `@tediousjs`, `@typespec`), as it already leaves `@esbuild` and `@types`. They carry no file. 5. **The toolchain holds them** at `/app/node_modules`. In that image, mesh-catalog#231's `merge-check-typescript.sh` with `MESH_CHECK_MODULES=mesh-catalog,model-usage,mongodb,mssql`, without a network, type-checked all four, ran model-usage's tests (6 pass, 1 skipped without TEST_DATABASE_URL) and mssql's (4 pass), and exited 0. In the current toolchain it fails all four by name and exits 1. 6. Checks on this head: merge-gate pass (builds mesh-tools, sent nowhere, 4 of 4 compose), repo-check pass, delivery ready, delivery-group ready. **Cost, not blocking:** the toolchain image grows from 368 MB to 426 MB (its `/app/node_modules` from 38 MB to 120 MB, mostly mssql's Azure dependencies). No machine runs it; only the build seat pulls it. **Merge order:** this must be merged, and its build published, before mesh-catalog#231. A check runs in the toolchain the mesh holds (the one built from main), never in a pull request's head, and the group's composed check runs only the gate, not each repository's check. See the review on #231.
mesh-admin merged commit 09c5f809cb into main 2026-10-12 10:46:07 +00:00
mesh-admin deleted branch fix/385-an-untestable-module-fails-the-check 2026-10-12 10:46:08 +00:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: novox/mesh-tools#31