Repository navigation
Conversation
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. |
[Medium impact] No new blocking issues were found; the remaining large-scan responsiveness concern is non-blocking. SummaryThe PR preserves directory ownership and unknown symlink targets during offline JavaScript lookup.
Diagram%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Artifact inventory] --> B[Retain directories and symlinks with container digests]
B --> C[Shared path lookup]
D[Analyzed and unanalyzed files] --> C
C --> E{Same-container symlink on candidate path?}
E -->|Yes| F[Unavailable: stop lookup]
E -->|No| G[Apply loader-specific file and directory probes]
F --> H[Graph relationships]
G --> H
C --> I[Electron summary]
Reviews (18) · Last reviewed commit: "fix(javascript): reject artifact-root ES..." · Reviewed by Greptile |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 87bdcf8442
ℹ️ 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".
|
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: cd0afeebb4
ℹ️ 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-reviewed changes. Tests, builds and check reruns were skipped at maintainer request.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4e029384ce
ℹ️ 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. The package-main resolver checked only finalized files, then discarded the distinct inventoried-directory failure. Commit 496cedd checks the finalized candidate with the existing container-aware directory predicate before the not-found fallback, retaining rejected directory-import semantics without trying later candidates. The public CLI/MCP package-main regression includes lib.js alongside lib/.js/child.js and the Node ERR_UNSUPPORTED_DIR_IMPORT control. Existing resolution helpers own the interpretation; no separate directory classifier or downstream repair remains. Source and affected-consumer inspection, targeted formatting with two threads, and git diff --check completed. Regression coverage was authored; tests, builds, typechecks, lint, provider execution and CI reruns were skipped at the user’s request. |
(cherry picked from commit 8cac51e)
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 924f74c501
ℹ️ 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".
…HEAD # Conflicts: # scripts/lib/clean-linux-hopper-runtime.mjs
|
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. Root cause: |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 275d62b8bf
ℹ️ 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: c5127f3670
ℹ️ 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".
Preserve CommonJS literal paths and confined ESM URL semantics, including package main fallback, directory intent, Unicode identity, and present opaque modules. Parse extraction inputs at their AST/source owner, retain skipped HTML and source-map coverage, and distinguish endpoint candidates from proven receiver facts. Version structural fingerprints with computed literal contents and propagate them through worker contracts. Reviewed fixes include #1810, #1840, #2642, #2700, #2702, #2714, #2803, #2960, #2968, #2986, #3035, and #3036. Validation: 158 resolver tests passed; public CLI/MCP module lookup controls, package-main/Unicode workflows, and six builtin workflows passed in the current compiled lane. Worker schema/fingerprint regressions passed. Large public pdf.js completion and real Electron analysis remain unverified.
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits. |
|
Edit: new results on head 60bb965 are in #2702 (comment). TL;DR: The symlink and container fixes work on Node 24 and 26. Two of the six new inventory tests fail, in the same way on GitHub. They expect the words "names a directory", but the code says "The declared path is empty." I tested head 17fa9dc as pushed. Main already holds the earlier package-main work. Commit b58adaf is already in this branch's base, 44d98de. Main does not hold the container and symlink part, so I tested that. GitHub reports no conflict. A merge of the 14 shared files onto main acca91d (#3831) also had no text conflict. Results
The inventory file is the new test file this PR adds. The artifact root case fails through the CLI and through stdio MCP. Before and afterI built three fixtures and ran the analyze command on main and on head. Main gave the same edges as the base 44d98de, so each change below comes from this PR.
Node 24 and Node 26 gave the same edges. The artifact root fixture gave "rejected" on both builds. Its limitation reads "The declared path is empty." The head test wants "names a directory". In the source, the subpath code rejects an empty path at line 867 of the path resolution file. That comes before the directory check at line 898. I did not trace this at run time (unverified). Not run
Thanks, Rohit, for the fix and the thorough tests. Test setup
CommandsEach run sat under nice and 🤖 Generated with Claude Code (Sonnet 5.5, verified by Opus 5.5) 🦊 |
A legacy ESM subpath that normalizes to the artifact root produced an empty encoded path and was rejected as an empty declaration before directory-form handling. Admit the empty root path so it reaches the directory rejection Node reports as ERR_UNSUPPORTED_DIR_IMPORT. Resolve retained path owners through a container map instead of scanning every container per occurrence.
|
TL;DR: Fixed. On head 60bb965, all 173 tests in the three test files pass on Node 24 and 26. The two inventory tests that failed on head 17fa9dc now pass. The empty-path case now says the import has URL directory form. This follows my earlier result on head 17fa9dc. Head is now 60bb965. The merge-base with today's main 9d6651e is cf0a38a. Thanks, Rohit, for the fix.
The three files are the path resolution unit file, the inventory file and the module lookup CLI file. The inventory file is the one that failed before. The case I reported. The artifact root fixture used to end with the limitation Before and after, again. I rebuilt my three fixtures and ran the analyze command on head 60bb965 with Node 24 and Node 26. Both gave the same edges. Two fixtures give the same edges as head 17fa9dc. The third is the artifact root fixture, where only the limitation text changed.
I did not rerun main this time. The "before" columns of my earlier result stay as posted. Not run
The box was shared with other test jobs. Timings are not benchmarks. Test setupCommandsnpm ci && npm run build && npm run test:prepare
node scripts/run-development-tests.mjs focused src/application/javascript/JavaScriptArtifactPathResolution.test.ts tests/acceptance/applications/packagePathInventoryCli.test.ts tests/acceptance/applications/JavaScriptModuleLookupCli.test.ts
node scripts/rea.mjs analyze-javascript-application <fixture> --format jsonEach test run sat under 🤖 Generated with Claude Code (Sonnet 5.5, verified by Opus 5.5) 🦊 |
Summary
Match Node package-main lookup while preserving artifact directory ownership and unknown symlink targets in offline JavaScript reconstruction.
Problem and expected behavior
Node ignores a non-string main and can resolve an index. CommonJS probes normalized main paths; legacy ESM also finalizes the original main plus its selected suffix. Collapsing those stages creates false or missing dependencies.
Retained directory paths also need their container identity: an outer directory cannot establish a package inside a nested ASAR. The inventory's root spelling must match resolver candidates. A symlink at a selected final target, such as
lib/.jsfor main./lib/, establishes uncertainty rather than absence.The slash-main case was reported in the resolver discussion; the retained-path gaps were raised in review. No separate issue was identified for these fixes.
Change and scope
Existing upstream integrations and the bounded Apple fixture compiler timeout are retained.
Contract and boundary impact
Expected effects:
Evidence and regression coverage
Existing CLI/stdio MCP and native-control sources cover non-string main, trailing slash, root/index fallback, dotfile decoys, and ESM finalization. Added regression sources cover outer versus nested ASAR directories, empty directories, artifact-root identity without metadata/index, foreign-container path facts, symlink finalization, unknown earlier probes, and linked parent directories.
The new symlink fixture is excluded on Windows because it creates filesystem links; platform-independent source-level cases still cover retained symlink ownership. No new cases have been executed.
Validation performed
Merged current main (cf0a38a). An ESM subpath that normalizes to the artifact root is now admitted to directory-form rejection instead of being rejected as an empty declaration. Retained path owners come from a container map lookup. Executed on Node 24.19.0 (macOS arm64): JavaScriptArtifactPathResolution.test.ts, packagePathInventoryCli, JavaScriptModuleLookupCli and packageSpecifierSuffixCli, 175/175 passed through CLI and stdio MCP, including native Node controls;
tsc --noEmitandnpm run linthave 0 errors. Not run: Windows, Node 22 native controls (they expect Node 24 loader codes), the full suite, real Electron apps, large-input timing.Compatibility, safety, and release
No public schema or dependency change. Same-container admission remains mandatory for retained paths. REA does not follow or execute symlinks. Latest runtime and cross-platform behavior remain unverified.
Author readiness
Human owner: @rohitg00
Before merge