Skip to content

GT-714: gate evaluate and phase advance in the published CLI need a checkout of this repository on disk #775

Description

@beyondnetPeru

What happens

On a satellite fresh from init, with the published CLI and nothing else:

mkdir my-project && cd my-project && git init -q
npx -y @beyondnet/evolith-cli@1.3.2 init --name my-project --yes
npx -y @beyondnet/evolith-cli@1.3.2 gate evaluate --phase discovery
# ■  Error: ENOENT: no such file or directory, scandir '/work/my-project/reference/governance/sdlc/gates'
# exit 1

phase advance --from discovery --to design fails the same way. With --core ../evolith pointing at a clone of this repository, both commands run and exit 2 with the real gate verdict (six missing Discovery artifacts). Measured 2026-09-20 in a clean node:20 container; the full run is in docs/evidence/phase-gate-capture.md.

Why

The tarball ships rulesets/sdlc/phase-gates.rules.json and rulesets/sdlc/artifact-registry.json at the package's own paths, but not reference/governance/sdlc/gates/gate-f1.json … gate-f5.json. PhaseGateValidatorService (src/packages/core-domain/src/application/validators/phase-gate-validator.service.ts) composes <core>/reference/governance/sdlc/gates and <core>/src/rulesets/sdlc/artifact-registry.json, and findCorePath — after walking up for a gates tree and then for a corpus — falls back to the satellite itself. The phase-gates.rules.json fallback is never reached because the gate registry throws on the missing directory first.

GT-705 fixed exactly this for the MCP package (bundled both trees, one resolver: caller → EVOLITH_CORE_PATH → walk up → bundled corpus). The CLI package was not part of that change. sdlc gate-status has no --core at all (GT-461 sub-finding).

What closes it

  • The CLI tarball carries the gate definitions and the artifact registry at the path the validator composes, and PhaseGateValidatorService falls back to the bundled trees through the same resolver chain GT-705 built — no path composed off the satellite.
  • sdlc gate-status resolves the Core the same way.
  • src/sdk/cli/scripts/check-install-smoke.mjs runs gate evaluate --phase discovery from the packed tarball in an empty directory and asserts exit 2 with six PG-1-EVIDENCE-* rows — observed red against the current package first.
  • The front-page demo and the capture are regenerated without --core, and the caption sentence about the tarball goes away.

Board row: GT-714 in gap-tracking.md · catalog: gap-reference-catalog.md#gt-714. Files: src/sdk/cli/package.json (files), src/sdk/cli/scripts/copy-rulesets.js, the validator above, check-install-smoke.mjs, .harness/scripts/generate-readme-demo.mjs.

🤖 Generated with Claude Code

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinghelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions