Skip to content

S0001-config-owns-shared-process: term-10 successor, the stderr version line - #74

Merged
NSchatz merged 1 commit into
mainfrom
sdd/S0001-config-owns-shared-process-config-term10
Aug 13, 2026
Merged

S0001-config-owns-shared-process: term-10 successor, the stderr version line#74
NSchatz merged 1 commit into
mainfrom
sdd/S0001-config-owns-shared-process-config-term10

Conversation

@NSchatz

@NSchatz NSchatz commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

The changeset-only follow-up that task 8 of the config slice asks for: the successor to @cosyte/process@0.0.1 differs from it in exactly one behaviour, the line term 10 pins.

What changes

Each of the five delegated verbs (build, test, lint, typecheck, format) writes the single line

cosyte-process <package version>

to stderr, newline terminated, immediately before the tool is spawned, so it precedes the tool's own output. check prints no such line, stdout is never touched, and an invocation that fails before it reaches a tool (bad argv, no package.json, invalid override, unresolvable tool) prints nothing new either.

The version is read from this package's own manifest at run time. src/ and the built dist/ sit one level below package.json, so the same relative path answers from source and from the installed tarball, and a later bump cannot strand a stale literal.

What deliberately does not change

Term 10 pins the successor as differing from the first published version ONLY in this line, so nothing else rides along: the term-4 baselines and token partition, the term-3 modifiers, the term-7 override semantics, check, and the verbatim exit-code propagation are all untouched.

Tests

  • test/e2e.test.ts: the guard that pinned "the first published version prints no version line" is flipped. It now asserts, through the real bin in a fixture consumer, that all five delegated verbs put the line first on stderr, exactly once, and never on stdout; that check prints none; and, against the broken-eslint fixture, that eslint's own stderr output comes after ours. The tool-failure case still asserts no cosyte-process: diagnostic rides along, now alongside the expected version line rather than instead of it.
  • test/cli.test.ts: the same behaviour at stream level with the spawn injected, including that the write happens BEFORE the spawn, that the version read is real semver rather than a placeholder, and that a run which never reaches a tool prints nothing.
  • pnpm --dir packages/process run test: 6 files, 136 passing (was 125).
  • pnpm run test:root: 13 files, 216 passing. pnpm run build, typecheck, lint, format:check, check:no-emdash, changeset:guard, pnpm -r publish --dry-run --no-git-checks and npm pack --dry-run all clean; packages/process floor suite (node 22.0.0 + pnpm 10.0.0) 6 passing.

Release

Carries a @cosyte/process: patch changeset (0.0.1 -> 0.0.2, respecting the 0.0.x ladder in RELEASING.md) and an ## [Unreleased] CHANGELOG entry to be promoted by hand in the Version PR.

Spec: work/specs/S0001-config-owns-shared-process/children/config.md, task 8 (AC happy 8, contract term 10).

…on line

The representative change term 10 pins for the version-bump instance test: the
successor to 0.0.1 differs from it only in that each of the five delegated
verbs writes the single line `cosyte-process <version>` to stderr before its
tool is spawned.

- src/run.ts writes the line at the one seam before spawnTool, so it precedes
  the tool's own output. The version is read from this package's own manifest
  at run time (`<pkg>/package.json`, one level above both `src/` and `dist/`),
  never inlined, so a later bump cannot strand a stale literal.
- `check` prints nothing, stdout is untouched, and no invocation that fails
  before reaching a tool prints it either.
- The e2e guard that pinned "the first published version prints no such line"
  is flipped to assert the line IS present for all five verbs, is the first
  thing on stderr, appears exactly once, and never reaches stdout; `check`
  still asserted to print none. The tool-failure case still asserts no
  `cosyte-process:` diagnostic rides along, now alongside the expected version
  line rather than instead of it.
- cli.test.ts pins the same behaviour at stream level with the spawn injected,
  including that the write happens BEFORE the spawn.

Nothing else changes: baselines, modifiers, overrides, check and verbatim
exit-code propagation are untouched.

Spec: work/specs/S0001-config-owns-shared-process/children/config.md (task 8)
@NSchatz
NSchatz merged commit 78d3d47 into main Aug 13, 2026
5 checks passed
@NSchatz
NSchatz deleted the sdd/S0001-config-owns-shared-process-config-term10 branch August 13, 2026 02:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant