refactor(estree-ast-utils)!: remove dependency to VariableTracer#366
Merged
refactor(estree-ast-utils)!: remove dependency to VariableTracer#366
Conversation
🦋 Changeset detectedLatest commit: 92fb263 The changes in this PR will be included in the next version bump. This PR includes changesets to release 3 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR refactors the AST utilities by removing the dependency on VariableTracer and replacing it with a unified DefaultOptions interface using an externalIdentifierLookup callback. Key changes include:
- Replacing tracer-based lookups with an externalIdentifierLookup function in several utility functions.
- Removing the VariableTracer dependency from estree-ast-utils and updating related tests.
- Updating documentation and configuration files to reflect these refactors.
Reviewed Changes
Copilot reviewed 18 out of 18 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| workspaces/tracer/src/VariableTracer.ts | Updated to use externalIdentifierLookup for processing call expressions and member expressions. |
| workspaces/js-x-ray/src/probes/isSyncIO.ts | Simplified moduleName extraction with a local variable. |
| workspaces/estree-ast-utils/* | Replaced tracer usage with DefaultOptions and externalIdentifierLookup throughout source and test files. |
| workspaces/estree-ast-utils/README.md | Updated documentation to reflect the new API options and refactor changes. |
| eslint.config.mjs | Added additional ignore patterns. |
| .changeset/legal-lands-crash.md | Documented version bumps and dependency refactors. |
Comments suppressed due to low confidence (1)
workspaces/estree-ast-utils/README.md:78
- The documentation heading appears to be mislabelled; it presents 'extractLogicalExpression' in a section that seems intended for getCallExpressionIdentifier. Please verify the function each section describes and adjust the headings accordingly.
<summary>extractLogicalExpression(node: ESTree.Node): IterableIterator< { operator: string; node: ESTree.Expression; } ></summary>
PierreDemailly
approved these changes
Jun 30, 2025
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.
No description provided.