-
Notifications
You must be signed in to change notification settings - Fork 12.9k
fix moduleNameResolver cache #26296
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
fix moduleNameResolver cache #26296
Conversation
@@ -0,0 +1,28 @@ | |||
tests/cases/compiler/monorepo/context/src/bindingkey.ts(1,29): error TS2307: Cannot find module '@loopback/context'. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By the way, the changed baseline shows a bug in the test. It always worked because of the caching bug. Now it can no longer resolve the module. Should I fix that test?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes please, Can you please change import to context instead? Thanks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed the path where the symlink is located so it can be resolved now. I didn't want to change any import paths as I don't know exactly what this test does.
originalPath: "/sub/node_modules/a/index.ts", | ||
packageId: undefined, | ||
resolvedFileName: "/modules/a.ts", | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you also add test that in file "/sub/foo.ts" "a" resolves same as this.
Looks good but we should wait to merge this till review comments are fixed. Thanks. |
Fixes: #26271
@sheetalkamat could you please review?