-
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 - CodeQL exiting with exit code 2 #14866
Comments
Would it be possible for you to rerun the workflow with debugging enabled and send us the log files from the generated artifacts? You can see how to rerun your workflow with debugging enabled here: https://github.blog/changelog/2022-08-01-debugging-codeql-analysis-in-code-scanning-made-easier-by-obtaining-detailed-logs-and-debugging-artifacts-from-the-codeql-action/ |
@MathiasVP are there any particular files or folders that would be of interest? sorry just looking at some of the files I can see that some sensitive company information is on them and since this is a private repo I have to be careful. |
Oh, I see. Sorry, I didn't realize this wasn't in an open source repository. We're mostly interested in the |
Any idea what the reason could be. I'm experiencing exactly the same issue. The CodeQL workflow fails approx. in 50% of the workflow runs. |
Difficult to say without more information, unfortunately. The issue reported by the user is now being handled elsewhere. Do you mind opening a fresh issue with as much information you can so that we can debug this better? I'm thinking of information such as:
And anything else that you think may be relevant. We'll be happy to help you from there! |
Hi @MathiasVP, sorry for the delay. Now I've collected some information which might be helpful: CodeQL version: 2.15.5 Before every run, the database is cleared with:
Unfortunately this is not an open source repo of my company, but I've attached some uncritical log output. It is not captured in debug mode. The problem is that if I would re-run such a failed action manually in debug mode, it always works well. 5_Initialize CodeQL.txt |
Any update on this issue? |
I have the same issue, with codeql 2.19.4 |
/apps/actions-runner/_work/_tool/CodeQL/2.15.2/x64/codeql/codeql database finalize --finalize-dataset --threads=4 --ram=14356 /apps/actions-runner/_work/_temp/codeql_databases/csharp
Running pre-finalize script /apps/actions-runner/_work/_tool/CodeQL/2.15.2/x64/codeql/csharp/tools/pre-finalize.sh in /apps/actions-runner/_work//.
Running TRAP import for CodeQL database at /apps/actions-runner/_work/_temp/codeql_databases/csharp...
A fatal error occurred: Dataset /apps/actions-runner/_work/_temp/codeql_databases/csharp/db-csharp has been finalized and does not support further TRAP import.
A fatal error occurred: Dataset import for /apps/actions-runner/_work/_temp/codeql_databases/csharp/db-csharp failed with code 2.
Error: Encountered a fatal error while running "/apps/actions-runner/_work/_tool/CodeQL/2.15.2/x64/codeql/codeql database finalize --finalize-dataset --threads=4 --ram=14356 /apps/actions-runner/_work/_temp/codeql_databases/csharp". Exit code was 2 and error was: A fatal error occurred: Dataset import for /apps/actions-runner/_work/_temp/codeql_databases/csharp/db-csharp failed with code 2. Context: A fatal error occurred: Dataset /apps/actions-runner/_work/_temp/codeql_databases/csharp/db-csharp has been finalized and does not support further TRAP import. See the logs for more details.
This is issue is fixed if I delete the database folder but it will start up again. We had been running CodeQL nightly for months and then this issue began. I have checked the disk space and that does not seem to be an issue. Any ideas how to fix this?
The text was updated successfully, but these errors were encountered: