Repository navigation
fix(javascript): retain TypeScript import-equals module dependencies - #2081
rekcilyssup wants to merge 11 commits into
Conversation
import value = require("./dep.cjs") in a .cts source parsed with
complete coverage but produced no import relationship and reported
module_format unknown, while the emitted program loads the dependency.
Bind the declaration as an immutable import alias, project it as a
require module link, and emit the matching static require reference so
both graph producers keep the dependency. Type-only declarations and
internal namespace aliases keep their local alias without a module
origin because TypeScript emits no load for either form. Module format
now follows Node and TypeScript's extension rule for mts and cts, so an
mts source stays ESM when its import-equals compiles through
createRequire.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 827ff567ad
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
@greptileai review |
|
Pinned main already implements import-equals via owning helper; removed duplicate merged producers and obsolete redundant unit regression, retained contributor filesystem regression. Review fixes preserve internal alias provenance from TSQualifiedName, add namespace scope ownership, and verify per-source require edges and declaration ranges. Source inspection and git diff --check. Further tests/typechecks/builds skipped by explicit user instruction; canceled validations are not passes.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 719d87778a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Admit immutable import-equals initializers to the shared stable-initializer owner. Namespace blocks retain private lexical scope while a shared exported-member owner resolves repeated namespace declarations; all binding lookup paths reuse that owner. Source inspection and git diff --check only. Tests, builds and typechecks skipped by explicit user request. GitHub review writes paused globally.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e6f89a2247
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Review findings addressed at their producing boundaries and consumers. Latest changes were reviewed from source; tests and provider runs were skipped at the maintainer's request. Findings requiring separate decisions or verification remain open. Fixed in e6f89a2. Root cause and structural fix: The shared stable-initializer owner now admits immutable import-equals aliases while excluding runtime ESM imports. Electron classification can reach the existing qualified-alias provenance instead of stopping at the initializer gate. Validation: source inspection and git diff --check only. Tests, builds and typechecks were skipped by the user's explicit request; no runtime or real-provider pass is claimed. No directly related cleanup remains identified. Fixed in e6f89a2. Root cause and structural fix: Each namespace block retains its private lexical environment, and repeated declarations reuse a shared exported-member owner. All binding lookup paths consult that owner while preserving lexical parents and private shadowing; the IR retains the exported-scope link. Validation: source inspection and git diff --check only. Tests, builds and typechecks were skipped by the user's explicit request; no runtime or real-provider pass is claimed. No directly related cleanup remains identified. |
|
Review findings addressed at their producing boundaries and consumers. Latest changes were reviewed from source; tests and provider runs were skipped at the maintainer's request. Findings requiring separate decisions or verification remain open. Fixed in 553efb8. Babel represents export-import ownership on TSImportEqualsDeclaration.isExport, so checking only an ExportNamedDeclaration parent kept these aliases private. namespaceDeclarationScope now recognizes that producer flag and routes the declaration through the same shared exported-member owner used by exported variables/functions/classes. Both alias binding and name/provenance lookup continue using that owner; private aliases retain their separate lexical block. A reopened-namespace Electron provenance regression was authored, not run. Source inspection followed Babel declaration handling, binding ownership and Electron call classification; git diff --check passed. Validation: inspected the producing boundary and affected consumers in source; no tests, builds, lint, typechecks, provider workloads or CI reruns were executed, as explicitly requested. No downstream provenance workaround was added. Fixed in 553efb8. Only the final TSModuleBlock previously created a namespace owner, dropping earlier dotted declaration segments and colliding A.B with top-level B. The owning scope builder now walks the TSModuleDeclaration chain and interns each segment under its actual parent owner. This also makes dotted A.B and nested exported A/B declarations share the same identity, while an unrelated top-level B remains distinct. Regression source covers all three forms and both positive and negative Electron provenance; it was not run. Source inspection followed parent indexing, export ownership and semantic binding lookup; git diff --check passed. Validation: inspected the producing boundary and affected consumers in source; no tests, builds, lint, typechecks, provider workloads or CI reruns were executed, as explicitly requested. The superseded final-name-only key path is removed. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 553efb800c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e3306333a5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Source fixes and publication evidence for the review findings below. Tests and executable checks were skipped at the maintainer's request. Findings that still require a decision or execution evidence remain open. Dotted namespace bodies resolve outer exports through the shared namespace owner chain after private lexical lookup. semanticScopedBinding now traverses those parent owners while retaining private shadowing; producer and consumer regression source covers inherited exports, hidden private names, and repeated nested namespaces. Source inspection and git diff --check passed; tests were not run. |
…mport
The call root is the shared Electron module alias itself, so the proven
root path is empty, matching the established require("electron")
.ipcMain.handle classification. The authored expectation ipcMain was
never run and made the reopened-namespace regression fail on the
correct behavior.
Validated with typecheck and the javascript domain and application
suites.
The shared-owner walk in semanticScopedBinding consulted every owner binding before the lexical climb resumed, so a nested exported namespace resolved names against its containing namespace's export owner before the enclosing block's private bindings. A private ipcRenderer binding in a reopened namespace block lost to the shared ipcMain export, and an enclosing namespace private lost to a same-named program binding. Stop the owner walk at any owner that an enclosing lexical scope claims as its namespaceExportScopeId (or reaches as its parent), so each enclosing scope resolves its own private bindings first while dotted bodies still read outer-segment exports that their lexical parent skips. The strict worker scope schema also lacked the "namespace" kind and namespaceExportScopeId that immutableSemanticScopes now emits, so any TSModuleBlock scope failing the record parse would abort a transfer. Extend the schema with a round-trip test that retains namespace scopes and their export owners across writeJavaScriptAnalysisTransfer.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d22f2fc826
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| parent = state.parentsByNode.get(declaration); | ||
| } | ||
| if ( | ||
| (t.isExportNamedDeclaration(parent) && parent.declaration === declaration) |
There was a problem hiding this comment.
Route ambient namespace members to the shared owner
For a reopened ambient namespace such as declare namespace N { const require: (s: string) => unknown; } namespace N { export const x = require("not-a-module"); }, ambient members are implicitly exported even without an ExportNamedDeclaration, so this predicate leaves require in the first block's private scope. The second block then records it unbound and collectUnboundRequireLink invents a dependency on not-a-module, although TypeScript emits N.require(...); route declarations in an ambient namespace context to the shared owner as well.
AGENTS.md reference: AGENTS.md:L19-L19
Useful? React with 👍 / 👎.
namespaceDeclarationScope only recognized an ExportNamedDeclaration
wrapper, but ambient namespace and module bodies export every member
implicitly. A reopened ambient block therefore kept its members private:
declare namespace N { const require: ... } followed by namespace N bound
the second block's require() call to nothing, so collectUnboundRequireLink
invented a dependency on the call's string argument even though
TypeScript emits N.require(...) and no module is loaded.
Route declarations whose ancestor chain includes a declare-marked
TSModuleDeclaration to the shared exported-member owner, matching the
TypeScript rule that ambient members are exported by default at any
nesting depth. The shared owner keeps the reopened block's reference
resolved, which suppresses the fabricated require link at its source.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: dcf804e57e
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| parent: t.Node | null, | ||
| ): JavaScriptSemanticScopeState["kind"] | undefined => { | ||
| if (t.isFunction(node)) return "function"; | ||
| if (t.isTSModuleBlock(node)) return "namespace"; |
There was a problem hiding this comment.
Expose global augmentations to program lookups
When an external-module source uses a global augmentation such as export {}; declare global { const require: (s: string) => unknown; } require("not-a-module"), Babel represents the body as a TSModuleBlock under a TSModuleDeclaration with global: true, but this unconditional branch models it as an ordinary namespace scope. The augmented binding is consequently stored under the namespace export owner while the following program reference never traverses that owner, so collectUnboundRequireLink invents a runtime dependency (and other augmented globals remain unbound); global-augmentation members need to participate in global name lookup rather than named-namespace lookup.
AGENTS.md reference: AGENTS.md:L19-L19
Useful? React with 👍 / 👎.
|
Source fixes and publication evidence for the review findings below. Tests and executable checks were skipped at the maintainer's request. Findings that still require a decision or execution evidence remain open. Status: Current live source already contains namespace schema shape and private-before-shared lookup; inspected at live head. Validation is source-only; no tests/builds/checks/CI reruns were run. Root cause, owner-level fix, and any residual cleanup are recorded in the per-PR result. This is not a claim of exact CI reproduction. |
A top-level `declare global` block was modeled as an ordinary named namespace, so its members landed under a synthesized exports:["global"] owner that program-name lookup never traverses. The augmented binding was recorded unbound and collectUnboundRequireLink invented a runtime dependency on the call's string argument. Babel 8 marks no global flag, so a global augmentation is identified by declare: true with an Identifier id of global directly under the Program; a nested `declare namespace global` keeps its namespace owner. Route the augmentation block's namespaceExportScopeId to the enclosing program scope so its members participate in global name lookup. The ambient walk in ambientNamespaceContext also now starts at the declaration itself: a declaration that is itself ambient (`declare namespace B`) exports its own name, so its owner matches the one reopened dotted declarations create instead of leaving them unbound.
|
Want your agent to iterate on Greptile's feedback? Try greploops. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fd5019b506
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| t.isTSModuleDeclaration(node) && | ||
| node.declare === true && | ||
| t.isIdentifier(node.id, { name: "global" }) && | ||
| t.isProgram(state.parentsByNode.get(node) ?? null); |
There was a problem hiding this comment.
Check module kind before treating
global as an augmentation
When a valid file contains declare function require(...); declare namespace global { const require: ...; } require("./dep"), Babel marks the namespace declaration as kind: "namespace", but this predicate matches it solely because it is declared, named global, and top-level. Its member is consequently installed in the program scope, so collectUnboundRequireLink sees a false binding and omits the ./dep edge even though TypeScript emits the unqualified call unchanged; gate this on the parsed module kind rather than the name/position heuristic.
AGENTS.md reference: AGENTS.md:L19-L19
Useful? React with 👍 / 👎.
| names.unshift(t.isIdentifier(id) ? id.name : id.value); | ||
| let owner = namespaceDeclarationScope(parent, parentScope, state); | ||
| for (const [index, name] of names.entries()) { | ||
| const key = JSON.stringify([owner.scopeId, name]); |
There was a problem hiding this comment.
Tag quoted modules in namespace owner keys
When declare module "N" { const require: ... } and runtime namespace N { export const x = require("./dep") } coexist, TypeScript keeps the string-literal external module and identifier namespace distinct, but these lines reduce both IDs to N and reuse the same owner key. The runtime namespace then resolves its call to the ambient module's require, causing collectUnboundRequireLink to suppress the real dependency even though TypeScript emits an unqualified require("./dep"); retain an identifier-vs-string tag in the owner identity.
AGENTS.md reference: AGENTS.md:L29-L29
Useful? React with 👍 / 👎.
Distinguish `declare global` by Babel's exact `kind: "global"` discriminator instead of the identifier name: a top-level `declare namespace global` carries `kind: "namespace"` and declares an ordinary namespace whose later require() calls keep their dependency links. The name heuristic misclassified it and hid its dependencies. Bind augmentation members in a lazily created outer scope, parented above the program scope, rather than in the program scope itself. Augmentation members live outside the module scope, so file-local bindings now shadow them instead of merging: an `import ipc` keeps its single definition beside a global `var ipc`, and the local call still classifies. The outer scope participates in ordinary lexical lookup, so global-only names keep resolving from any program position.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 7dbe0fd6d0
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| if ( | ||
| (t.isExportNamedDeclaration(parent) && | ||
| parent.declaration === declaration) || | ||
| ambientNamespaceContext(declaration, state) |
There was a problem hiding this comment.
Keep ambient import aliases private unless explicitly exported
Fresh evidence after the ambient-member fix is that TypeScript does not implicitly export import aliases: with a program binding ipc = electron.ipcRenderer, declare namespace N { import ipc = electron.ipcMain; }, and a reopened namespace N { ipc.send(...) }, the final ipc resolves to the program binding. This blanket ambient branch instead stores the alias in N's shared owner, so Electron classification attributes the call to ipcMain rather than ipcRenderer; only explicitly exported ambient import aliases should use the shared owner.
AGENTS.md reference: AGENTS.md:L19-L19
Useful? React with 👍 / 👎.
| node.declare === true && | ||
| node.kind === "global" && | ||
| t.isProgram(state.parentsByNode.get(node) ?? null); |
There was a problem hiding this comment.
Recognize global augmentations nested in ambient modules
Fresh evidence after the top-level-global guard is the valid inherited-ambient form declare module "x" { global { const require: (s: string) => unknown; } }: its global declaration is parented by a TSModuleBlock, not the program, and has no inner declare modifier. These predicates therefore leave its members under module x, so a following require("not-a-module") is recorded unbound and collectUnboundRequireLink invents a dependency; route kind: "global" declarations nested directly in ambient module declarations to the program-global owner while continuing to exclude ordinary namespaces named global.
AGENTS.md reference: AGENTS.md:L19-L19
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4778c70b45
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| definitionNode: node.id, | ||
| initializer: null, | ||
| directOrigin: { specifier, importedPath: [], resolutionMode: "require" }, | ||
| initializer: specifier === null ? node.moduleReference : null, |
There was a problem hiding this comment.
Keep type-space aliases out of runtime bindings
When an internal import alias resolves only in TypeScript's type namespace but a same-named value declaration supplies the runtime value—for example, const ipc = electron.ipcRenderer; namespace T { export interface ipc {} } import ipc = T.ipc; ipc.send(...)—TypeScript accepts the merge and erases the alias. Recording T.ipc as another initializer on the value binding makes semanticStableInitializer reject the otherwise stable ipc binding, so Electron classification drops the valid ipcRenderer call and the IR loses its module provenance; model the type and value identities separately instead.
AGENTS.md reference: AGENTS.md:L19-L19
Useful? React with 👍 / 👎.
| kind: "source-range", | ||
| source: path, | ||
| start: { line: 1, column: 0 }, | ||
| end: { line: 1, column: 36 }, |
There was a problem hiding this comment.
Both fixtures contain import value = require("./dep.cjs");, which ends at column 35. This assertion expects end.column to be 36. range copies Babel’s end column, and graph evidence keeps it unchanged, so the new test fails for both files even when their dependency edges are correct. Expect 35, or derive the range from the fixture.
| end: { line: 1, column: 36 }, | |
| end: { line: 1, column: 35 }, |
Prompt To Fix With AI
This is a comment left during a code review.
Path: tests/boundary/filesystem/javascript-applications/javascriptApplicationTypeScript.test.ts
Line: 204
Comment:
**Correct dependency test fails**
Both fixtures contain `import value = require("./dep.cjs");`, which ends at column 35. This assertion expects `end.column` to be 36. `range` copies Babel’s end column, and graph evidence keeps it unchanged, so the new test fails for both files even when their dependency edges are correct. Expect 35, or derive the range from the fixture.
```suggestion
end: { line: 1, column: 35 },
```
---
For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
|
TL;DR: The first fix in this PR is already on main, and main gives the same output as the head on the issue's example. The namespace work is still new: 15 of the PR's tests fail on main and pass on the head, and a 16th fails on both. One PR test fails because its expected count is wrong, and one file fails the format check. I tested head 4778c70 as pushed. GitHub says it conflicts with main 4692bb3, which is 368 commits ahead of the merge base. Results
On main, 16 tests fail. One is the line-216 test, which fails on head too. The other 15 are namespace and alias tests. The failing test sits at line 216 of the TypeScript boundary test. It expects 2 resolved edges. The head makes 4: one meaning link and one static link for each of main.cts and esm.mts. Every edge has the right file, range and resolved path, so the count looks wrong, not the code. This matches the failing CI shard. Greptile asked for end column 35 on the same test. The head emits 36 and the test expects 36, so they agree. Greptile's 35 does not match what the head emits. Before and after, on the CLI (Node 24.18.0):
Not run
Thanks, Aravind Rao and morluto, for the fix and the namespace tests. Test setupCommandsThe format check flags this file: For the main rows, I copied the head's 4 test files onto the main tree. Each fixture is a folder with a package.json and one .cts file. Every run sat under 🤖 Generated with Claude Code (Sonnet 5.5, verified by Opus 5.5) 🦊 |
|
Superseded by the delivered change on main: 86fab11fb. Runtime TypeScript import-equals links are retained through require resolution, with producer and public workflow coverage. This closure does not claim the separate type-only import-equals report #3932 is resolved. Closing this earlier proposal. Current main qualification passed: https://github.com/morluto/rea/actions/runs/38690953281. |
|
@rekcilyssup, thank you for identifying the runtime import-equals gap. Main now retains import-equals declaration and export evidence; this thanks is for that runtime case. |
Summary
import value = require("./dep.cjs")in a.ctssource parsed with complete coverage but contributed no import relationship and reportedmodule_format: "unknown", while the TypeScript program it describes really loads the dependency. TheTSImportEqualsDeclarationnode was parsed but never classified by the binding, semantic module-link, or static reference producers, so the graph silently omitted a dependency the emitted program depends on. Fixes #2058.Problem and expected behavior
.ctsfile whose only dependency is an import-equals declaration, in a directory that also inventories the target.tsc --module NodeNextexits 0, and the emittedmain.cjsrunsconsole.log(value)printing42; the companioncontrol.cjsusing a plainrequireis already represented..mtssource ESM when its import-equals compiles throughcreateRequire.Change and scope
bindInnerDeclaration(src/domain/javascript/javascriptSemanticAnalysis.ts) binds import-equals as an immutableimportalias. Value external module references carry a module origin; type-only declarations andimport alias = Some.Namespacealiases keep the local name with no origin, because TypeScript emits no load for either form.collectSemanticModuleLink(src/domain/javascript/javascriptSemanticProjection.ts) projects a value external module reference as akind: "require"link withimportedName: "*",localNamebound to the declaration andlocationequal to the declaration range, mirroringconst x = require(...).inspectNode(src/domain/javascript/javascriptStaticAnalysis.ts) emits the matching staticrequirereference, so the legacy reference producer and the semantic producer agree.moduleFormat(src/domain/javascript/JavaScriptModuleRelationships.ts) now treats.mtsas ESM and.ctsas CommonJS alongside.mjs/.cjs, because Node and TypeScript fix the module system by extension. Without this, the newly recoveredrequirelink would have flipped an.mtssource tocommonjsormixedinstead of staying ESM.import type { T } fromESM imports, namespace re-exports, packageexportsresolution, or the reference-source subsystem, which already parses import-equals separately.Contract and boundary impact
domain/javascriptdefinition binding and module-link projection forTSImportEqualsDeclaration, thenapplication/javascriptmodule format classification.module_link_kind/kindedges andmodule_formatvalues use existing vocabularies.docs/public/product-catalog.json), package, or installation impact: none.Evidence and regression coverage
javascriptSemanticAnalysis.require_links.test.tscovering the require link, the three immutable aliases, retained origin for the value form and empty origins for the erased forms, and reference resolution; an end-to-end test inJavaScriptApplicationTypeScript.test.tscovering edges,resolved_path, andmodule_formatfor.ctsand.mts.7c207c79when only the source changes are stashed (2 failed | 28 passed), and pass with the fix. TypeScript emission was executed as the loader control:.ctsvalue form emitsconst value = require("./dep.cjs"),.ctstype-only form emits no load at all, and.mtsemitscreateRequire(import.meta.url)inside a.mjsoutput.main.ctsnow reports twoimportsedges for./dep.cjs(semanticmodule_link_kind: require,resolution_status: resolved,resolved_path: dep.cjs, plus the statickind: requireedge) andmodule_format: "commonjs";esm.mtsreports the same dependency withmodule_format: "esm";type.ctsandalias.ctsreport no import edges;coverage.statusstayscomplete.tsc; the emission facts above were executed once while developing the fix and are stated as derived evidence.For evidence-bearing changes:
Validation performed
npx vitest run src/domain/javascript/ src/application/javascript/— 62 files, 1129 tests passed.npx vitest run src/domain/javascript/javascriptSemanticAnalysis.require_links.test.ts src/application/javascript/JavaScriptApplicationTypeScript.test.ts— 30 tests passed; with the source changes stashed, the 2 new tests fail.npx vitest run tests/boundary/filesystem/javascriptPackageExportTargets.test.ts tests/boundary/javascript/packageConditionalExports.test.ts tests/composition/javascript-applications/electronApplicationAnalysis.test.ts tests/acceptance/applications/electronPreloadOverridesCli.test.ts tests/acceptance/applications/packageSubpathsCli.test.ts— 5 files, 128 tests passed.npx vitest run src/domain/referenceSourceGraph.test.ts— 13 tests passed.npm run check:fast— typecheck and lint passed.scripts/rea.mjs analyze-javascript-application) —main.ctstwo resolvedrequireedges withmodule_format: "commonjs",esm.mtsdependency withmodule_format: "esm",type.ctsandalias.ctszero import edges,coverage.statuscomplete.Compatibility, safety, and release
module_formatmove fromunknown(or a content-derived guess) to the extension-fixed value for.mtsand.ctssources.tscwere executed as controls.Review checklist
type(scope): outcome.