-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
General issue (No source code was seen and extracted to C:\***\DB-codeql) #11476
Comments
Are you running codeql inside the docker container or does the build launch the docker conatiner? If it is the latter then it won't work. CodeQL works by tracing the build and finding all compiler invocations. However it cannot trace across system boundaries (across networks or into vms and containers). If your code is built inside a container then you must run codeql inside the container also. |
Hi, As I said it was getting compiled previously with other compiler settings (minGW) but now not. |
What is your build command. Your wriote |
I have a shell script (
|
@FaiqueAli Is that the entire build-tracer.log ? If not, could you attach it (as a zip file) to the issue? Make sure to check that it does not contain sensitive information though. |
Yes this is the entire text I found inside |
That is a very short log. It looks like CodeQL is only intercepting It looks like |
Yes, I am sure, I used this command to compile/build the project. |
I am sorry for not updating with the issue as there were major changes in the project. |
@FaiqueAli The file you attached appears to be empty. |
ahh my bad, here we go.. |
I see there is some build command being run. However, CodeQL seems to be configured to look for C# code instead of C++. That's a bit strange. Just to double check you are running
|
No, this time I am compiling a C# code not cpp. |
Ah yes indeed, I got confused. So things look good, msbuild is being run, the CodeQL tracer "sees" it, but somehow CodeQL does not start analysing the C# code. If I recall correctly, you are running the builds in a windows docker container, right? |
Looking at the github/codeql repository, this commit looks relevant for analysing with msbuild on Windows 914b968 . That commit is not in CodeQL 2.10, could you try upgrading to 2.11 or 2.12? |
You you are right, I am using a docker container to compile and execute codeql. |
Ok, I will do that but it will take time, and I will let you inform. |
No source code was seen and extracted to C:*\DB-codeql**
Hi all,
I am using codeql cli and trying to create a database of my
msvc CPP
project inside a docker container and getting the errorNo source code was seen and extracted to C:\***\DB-codeql.
The project is being compiled normally without codeql but with the codeql cli I am getting this error.
I am using this command to create a database
codeql database create --ram 4096 -J-Xmx1G -vvvv --language=cpp -c path-to-file -s path-to-source
the code was being compiled previously using mingw but with msvc I am getting this issue.
the
sourceLocationPrefix
is also set to my project path and there is no much information available inbuild-tracer.log
file as shown belowInitializing tracer. Initialising tags... CodeQL CLI version 2.11.3 Initializing tracer. Initialising tags... Allocated ID F7C238AA000000E0_0000000000000001 (parent ) ==== Candidate to intercept: C:\codeql\tools\win64\runner.exe (700) ==== Executing the following tracer actions: Tracer actions: pre_invocations(0) post_invocations(0) trace_languages(1): [cpp] Initializing tracer. Initialising tags... ID set to F7C238AA000000E0_0000000000000001 (parent root) Allocated ID BB65D210000002BC_0000000000000001 (parent F7C238AA000000E0_0000000000000001) ==== Candidate to intercept: C:\Windows\System32\cmd.exe (1028) ==== Executing the following tracer actions: Tracer actions: pre_invocations(0) post_invocations(0) trace_languages(1): [cpp] Initializing tracer. Initialising tags... ID set to BB65D210000002BC_0000000000000001 (parent F7C238AA000000E0_0000000000000001) Allocated ID 96C4BE6E00000404_0000000000000001 (parent BB65D210000002BC_0000000000000001) ==== Candidate to intercept: C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe (8) ==== Executing the following tracer actions: Tracer actions: pre_invocations(0) post_invocations(0) trace_languages(1): [cpp] Initializing tracer. Initialising tags... ID set to 96C4BE6E00000404_0000000000000001 (parent BB65D210000002BC_0000000000000001)
looking for the suggestion
Thanks :)
The text was updated successfully, but these errors were encountered: