-
-
Notifications
You must be signed in to change notification settings - Fork 536
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
failed to import TS file from node_modules on Linux & Mac #990
Comments
@cspotcode But why Windows works? The difference of File System? |
Not sure, though that does seem strange. Could be an issue with Windows paths using backslashes instead of forward slashes, or an issue with Windows being case-insensitive. Can you simplify your reproduction to the bare minimum? I think you can trigger the problem with only 4 files, for example: |
@cspotcode reproduction created, but GitHub Actions doesn't run... |
Thanks! The Github Actions is still experimental, I may have made a mistake. I will take a look. |
I tried running and it succeeds; no errors. Can you take another look? I also fixed the Github Actions, so if you merge the latest master into your branch and push again, it should run. |
@cspotcode I don't know why the minimal reproduction is OK... |
@TechQuery I suspect this was working on Windows due to the bug fixed by #997, which was released in v8.9.0 We were not rigorously normalizing Windows paths, so in some codepaths, they had This should be fixed by #970 and looks like the same underlying issue as #876. |
Expected Behavior
I want to import everything (including TS source codes in
node_modules/
) :https://github.com/EasyWebApp/MarkCell/blob/7b43ea0/source/File.ts#L26-L29
Actual Behavior
TypeError: Unable to require file: node_modules/xxx/source/yyy.tsx
TypeError: Unable to require file: node_modules/xxx/source/yyy.tsx
error on Linux
https://travis-ci.com/github/EasyWebApp/mark-wiki/builds/155135722
error on Mac
Steps to reproduce the problem
git clone https://github.com/EasyWebApp/mark-wiki.git cd mark-wiki/ npm install npm run build
Minimal reproduction
TypeStrong/ts-node-repros#1
Specifications
The text was updated successfully, but these errors were encountered: