Repository navigation
docs: say what @effect/docgen 0.5.2 actually loads in pnpm-workspace.yaml - #346
Merged
Merged
Conversation
…yaml docgen 0.5.2's bin.cjs bundles TypeScript 5.5.2 (via ts-morph) and never requires the `typescript` package; it type-checks examples with the `tsc` on PATH and runs them under `tsx`. Correct the three comments that said it drives the TS6 alias through the JS API, and say the peer rule only satisfies pnpm's range check. Refs #343 Claude-Session: https://claude.ai/code/session_01MbvVf1RHTwKCbEw9dyn3Aa Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR fixes three comments in
pnpm-workspace.yaml. They said@effect/docgendrives TypeScript through the JS API and so sees the TS6 side of the split. The pinned version, 0.5.2, never loads thetypescriptpackage. The PR changes comments only: the docgen version, the peer rule and the lockfile stay as they are.Refs #343 (#343 stays open: its second done-when item, the owner's decisions on the docgen 4.x move and on AGENTS.md lines 9/34, is not done by this PR)
@effect/docgencatalog entry now says what 0.5.x actually does:bin.cjsbundles TypeScript 5.5.2 (through ts-morph) to parsesrc/;tscon PATH, which is native TS7 undervp run;tsx;import * as assert from 'assert'to any example that usesassert..typescript(TS6 alias) catalog entry no longer lists docgen as a JS-API consumer. It namesscripts/docgen-class-examples.ts(import ts from "typescript"), which does load the alias."@effect/docgen>typescript": "6"peer rule now says what it is for. It only satisfies pnpm's peer-range check, because 0.5.x declarestypescript ^5.2.2and never loads it. The comment also says when the rule can be dropped.Evidence (details in #343):
npm pack @effect/docgen@0.5.2in a fresh directory gives a singlebin.cjsthat inlines@ts-morph/common@0.24.0/dist/typescript.js(version = "5.5.2") and contains norequire("typescript").runTscOnExamplesspawnstsc, andrunTsxOnExamplesspawnstsx.Module._loadhook made no request for thetypescriptpackage. The only TypeScript-related request was the bundled compiler's optional@microsoft/typescript-etwprobe.Verification
Run in order on a fresh clone. Every gate passed.
pnpm install --frozen-lockfile: passvp run build: pass (✔ Build complete)vp check: pass (All 221 files are correctly formatted;Found 0 errors, with warnings only from the existingwarntier)vp run check(sources, type-level tests, examples, emitted declarations): passvp run -r test:unit: pass (root 51 files / 3256 tests; examples 2/45, 2/43, 4/54)vp run docgen(every JSDoc@examplecompiled and executed): pass (docgen-class-examples: every class example compiled and ran)pnpm audit --audit-level high: pass (1 moderate, below the threshold)fallow audit --base origin/trunk: pass (✓ No issues in 1 changed file).fallow audit --format json --quiet --explain --gate-marker agentgave"verdict":"pass".Changeset
None. The PR changes only comments in
pnpm-workspace.yaml, which is tooling, not published behaviour..changeset/for every change to published behaviour (not applicable)Notes
These are left for the owner (see #343):
typescript >=5.8.2 <7, so the TS6 alias satisfies it and the peer rule could go. It injects noassertimport, so examples need explicit named imports. It also defaultsrunExamplestofalse, sodocgen.jsonwould need"runExamples": trueor the examples silently stop executing. This PR does not bump docgen.vp run docgenruns and with which tsc #298 still says docgen's parse sees TS6. docs: pnpm-workspace.yaml says @effect/docgen 0.5.2 drives the TS6 alias; it bundles TypeScript 5.5.2 #343 proposes replacement text.🤖 Generated with Claude Code
https://claude.ai/code/session_01MbvVf1RHTwKCbEw9dyn3Aa
Generated by Claude Code
Generated by Claude Code