-
Notifications
You must be signed in to change notification settings - Fork 118
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
typescript-parser-wrapper fails for tsconfig.json path check on Windows #163
Comments
Thanks for reporting. The problem seems to be caused by the use of different path component separators: As a workaround you could try switching to a Linux agent. |
Unfortunately, we cannot use a linux agent or at least couldn't without weeks of work. The build for repository in question has complicated setup. The javascript present is a small portion; so, we can wait for a fix. Also worth noting that most of the javascript is generated during the build; so, no good option to do a one-off javascript "build" to capture that portion. Thanks! |
What is the JavaScript code build from? |
Mostly Emscripten |
If the source language of that code is one of the other languages covered by CodeQL (C++?), then that language analysis should take care of analyzing the source code. Analyzing compiled JavaScript, especially from a tool like Emscripten, won't provide you much benefit, as the it's unlikely that our analysis will find anything useful, and even if it does you can't fix the JavaScript code directly. My recommendation is to do the JavaScript analysis on a simple linux runner that doesn't do any build or setup |
I'm not sure. I don't think there is a translation of C++ to javascript exactly such that a C++ scan would get results. I think it is more complicated. And even if we can't drive a change directly we'd want to be aware of the issue. In some cases, there might be an alternate pattern. |
Correct. I'm currently using it on a Mac. And we test most things on Linux+Mac+Windows.
The latter.
More complicated? What is the source language? Our analysis is not designed to work on generated code, and it generally performs badly and/or produces results that don't mean much. Oh, and you won't get in-PR alerts from generated code. The alerts will only appear in the code-scanning tab. |
I have tried to replicate it on a non-dev Windows box I have access to. But I can't replicate the issue. You can see if updating CodeQL fixes the issue 🤷 If not, then I will still recommend that you move your JavaScript analysis to a separate run, where you don't do a build. |
D:\a_work_temp\codeql3000\github\codeql\codeql.exe database trace-command --index-traceless-dbs --db-cluster D:\a_work_temp\codeql3000\d
|
As stated above I was unable to replicate the issue. Can you give me a minimal example that cause the crash to happen? |
When javascript is scanned during finalize typescript-parser-wrapper can throw with tsconfig.json path mismatch.
This particular situation was found when more than javascript was detected and was on a Windows agent.
The text was updated successfully, but these errors were encountered: