Skip to content

build: behold takes chant 0.124.100, which ships dist only; tsx and esbuild become dependencies - #1102

Merged
lex00 merged 2 commits into
mainfrom
estate/chant-0.124.99
Nov 16, 2026
Merged

lex00 merged 2 commits into
mainfrom
estate/chant-0.124.99

Conversation

@lex00

@lex00 lex00 commented Nov 16, 2026

Copy link
Copy Markdown
Contributor

behold now follows 0.124.100. Since 0.124.99 the package publishes dist/ only, and esbuild and tsx are optional peers that npm does not install.

What changed:

  • CHANT_RELEASE is { version: "0.124.100", released: true }. scripts/chant-release.ts rewrote the example workspaces, fixtures and package.json. By hand I moved the sql and pulumi lexicon ranges and the k8s-client ranges. The example-terraform-estate README and the pinned version in src/example-workspaces.test.ts also needed a hand edit. Both lockfiles follow.
  • tsx and esbuild are dependencies of @intentius/behold, because behold runs chant on TypeScript projects.
  • That alone was not enough. The tool loads tsx from beside the copy it runs, so a project that installed it alone still stopped with "chant needs tsx to run TypeScript". withLoaderPath in src/chant.ts appends behold's own node_modules to NODE_PATH for the process behold spawns. The project's own copies still win. Tests are in src/chant.test.ts.
  • Two e2e scripts decided whether chant was new enough by probing chant/src/...ts and chant-lexicon-terraform/src/op/...ts. They probe the dist/...js files now. The decision-points test and fixture read chant's schema JSON from dist/workspace/ instead of src/workspace/.

I checked with a packed tarball installed plainly into an empty directory, running behold graph on a copy of example-three-cloud whose own install has no tsx. Without the NODE_PATH change the dns and gcp members came back unreadable. With it all four members are read.

Plain install of the tarball in an empty directory is 114 MB, against 164 MB on chant 0.124.98. The tarball was packed with the example node_modules directories left out.

just check finished clean, with 373 test files and 5331 tests passed, 35 skipped. No snapshot goldens changed. src/mcp-graph.test.ts passes in 8 s, and behold graph on example-terraform-estate takes about 8 s, the same as on main with chant 0.124.98.

…sbuild become dependencies

chant no longer publishes src/ and makes esbuild and tsx optional peers.
tsx and esbuild are now dependencies of behold, and behold appends its own
node_modules to NODE_PATH for the chant it spawns so a project that
installed chant alone still loads TypeScript. The e2e probes and the
decision-points fixtures read dist paths.
…ad needs no tsx

chant `0.124.99` made tsx an optional peer dependency, and a `chant.config.ts` needs it to be evaluated. The extension stages no TypeScript loader (tsx needs esbuild, a native binary, and the vsix is one file for every platform), so `chant lint` reported "chant needs tsx to run TypeScript" for every behold-tf scratch project and `chant graph` refused to emit. The scratch project now holds a `chant.config.json`, which chant reads as data. The `lexicons` key loads the Terraform lexicon the config used to import. The scratch directory name is salted so an older `chant.config.ts` does not shadow the new file.
@lex00
lex00 merged commit 0e7ea1e into main Nov 16, 2026
5 checks passed
@lex00
lex00 deleted the estate/chant-0.124.99 branch November 16, 2026 02:28
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