-
Notifications
You must be signed in to change notification settings - Fork 53
✨ Implement import-based search for nodejs.referenced capability #976
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
tsanders-rh
wants to merge
19
commits into
konveyor:main
Choose a base branch
from
tsanders-rh:fix/nodejs-referenced-import-search
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+1,288
−84
Draft
Changes from 11 commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
c4c672f
Implement import-based search for nodejs.referenced capability
tsanders-rh cf83ae9
Merge upstream/main into fix/nodejs-referenced-import-search
tsanders-rh fbf745f
Add comprehensive unit tests for import-based search
tsanders-rh 6eb0d54
Update demo-output.yaml for improved nodejs.referenced precision
tsanders-rh 5b91e1a
Add bounds check before accessing WorkspaceFolders
tsanders-rh bd53a94
Replace hardcoded sleep with retry logic and exponential backoff
tsanders-rh 9f811ef
Add bounds checks for BaseConfig.WorkspaceFolders access
tsanders-rh 308aee7
Improve escape sequence handling in string parsing
tsanders-rh ce45ca3
Refine "from" keyword detection with word boundaries
tsanders-rh db79563
Synchronize BaseConfig.WorkspaceFolders with Config.WorkspaceFolders
tsanders-rh c777cfb
Limit "from" detection to current import to avoid cross-statement int…
tsanders-rh e85cc89
Add support for namespace, mixed, and TypeScript type imports
tsanders-rh dd4a62a
Fix false negative when pattern is prefix of another symbol
tsanders-rh 9219054
Fix test script variable references
tsanders-rh dfa364b
Remove documentation and test files from repository
tsanders-rh e139b38
Refactor normalize function with helper methods
tsanders-rh 101422c
Remove public test wrapper methods
tsanders-rh 3f862a2
Respect analysisMode when filtering references
tsanders-rh b68e524
Build import locations incrementally during file walk
tsanders-rh File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -597,44 +597,9 @@ | |
| description: Testing that the node provider works - type | ||
| category: potential | ||
| incidents: | ||
| - uri: file:///examples/nodejs/test_a.ts | ||
| message: nodejs sample rule 001 | ||
| codeSnip: " 1 export interface Greeter {\n 2 name: string;\n 3 hello(): string;\n 4 }\n 5 \n 6 export const greeter: Greeter = {\n 7 name: \"Person1\",\n 8 hello() {\n 9 return `Hello, I'm ${this.name}`;\n10 },\n11 };\n" | ||
| lineNumber: 5 | ||
| variables: | ||
| file: file:///examples/nodejs/test_a.ts | ||
| - uri: file:///examples/nodejs/test_b.ts | ||
| message: nodejs sample rule 001 | ||
| codeSnip: " 1 import { greeter } from './test_a';\n 2 \n 3 console.log(greeter.hello());\n" | ||
| lineNumber: 0 | ||
| variables: | ||
| file: file:///examples/nodejs/test_b.ts | ||
| - uri: file:///examples/nodejs/test_b.ts | ||
| message: nodejs sample rule 001 | ||
| codeSnip: " 1 import { greeter } from './test_a';\n 2 \n 3 console.log(greeter.hello());\n" | ||
| lineNumber: 2 | ||
| variables: | ||
| file: file:///examples/nodejs/test_b.ts | ||
| effort: 1 | ||
| node-sample-rule-002: | ||
| description: Testing that the node provider works - function | ||
| category: potential | ||
| incidents: | ||
| - uri: file:///examples/nodejs/test_a.ts | ||
| message: nodejs sample rule 002 | ||
| codeSnip: " 1 export interface Greeter {\n 2 name: string;\n 3 hello(): string;\n 4 }\n 5 \n 6 export const greeter: Greeter = {\n 7 name: \"Person1\",\n 8 hello() {\n 9 return `Hello, I'm ${this.name}`;\n10 },\n11 };\n" | ||
| lineNumber: 2 | ||
| variables: | ||
| file: file:///examples/nodejs/test_a.ts | ||
| - uri: file:///examples/nodejs/test_a.ts | ||
| message: nodejs sample rule 002 | ||
| codeSnip: " 1 export interface Greeter {\n 2 name: string;\n 3 hello(): string;\n 4 }\n 5 \n 6 export const greeter: Greeter = {\n 7 name: \"Person1\",\n 8 hello() {\n 9 return `Hello, I'm ${this.name}`;\n10 },\n11 };\n" | ||
| lineNumber: 7 | ||
| variables: | ||
| file: file:///examples/nodejs/test_a.ts | ||
| - uri: file:///examples/nodejs/test_b.ts | ||
| message: nodejs sample rule 002 | ||
| codeSnip: " 1 import { greeter } from './test_a';\n 2 \n 3 console.log(greeter.hello());\n" | ||
| lineNumber: 2 | ||
| variables: | ||
| file: file:///examples/nodejs/test_b.ts | ||
|
|
@@ -1353,5 +1318,6 @@ | |
| unmatched: | ||
| - file-002 | ||
| - lang-ref-002 | ||
| - node-sample-rule-002 | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. IDK if all of the rule-example rules have this, but can we add a comment explaining why this rule should be unmatched? It helps when we come back later and wonder why it is unmatched and if that was a issue :) |
||
| - node-sample-rule-003 | ||
| - python-sample-rule-003 | ||
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.