title | shortTitle | allowTitleToDifferFromFilename | intro | type | topics | versions | redirect_from | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Upload was rejected because CodeQL default setup is enabled for {% data variables.product.prodname_code_scanning %} |
Default setup is enabled |
true |
You cannot upload SARIF results generated by the {% data variables.product.prodname_codeql %} action or {% data variables.product.prodname_codeql %} CLI when default setup for {% data variables.product.prodname_code_scanning %} is enabled. Check your configuration and decide whether to keep default setup or unblock SARIF upload. |
reference |
|
|
|
Upload with CodeQL results rejected due to "default setup"
This error is reported if a process attempts to upload a SARIF file containing results of {% data variables.product.prodname_codeql %} analysis to a repository where {% data variables.product.prodname_codeql %} default setup is enabled. This includes uploads using the REST API and the {% data variables.product.prodname_codeql_cli %}. SARIF uploads are blocked when {% data variables.product.prodname_codeql %} default setup is enabled to reduce the potential for users to be confused by seeing similar {% data variables.product.prodname_code_scanning %} alerts generated by different systems.
You will only see this error for SARIF files that contain results created using {% data variables.product.prodname_codeql %}.
{% data reusables.repositories.navigate-to-repo %} {% data reusables.repositories.sidebar-settings %} {% data reusables.repositories.navigate-to-code-security-and-analysis %}
- In the "{% data variables.product.UI_code_security_scanning %}" section of the page, next to "{% data variables.product.prodname_codeql %} analysis," click {% octicon "kebab-horizontal" aria-label="Menu" %}.
- If there is a {% octicon "workflow" aria-hidden="true" %} Switch to advanced option, default setup is enabled for the repository.
Before you can fix the problem, you need to decide whether {% data variables.product.prodname_code_scanning %} alerts from {% data variables.product.prodname_codeql %} analysis in this repository should be generated using default setup or uploaded from SARIF files.
- Leave the repository settings as they are, with default setup enabled.
- Disable the process or processes that tried to upload SARIF files to the repository.
- In the "{% data variables.product.prodname_code_scanning_caps %}" section of the page, next to "{% data variables.product.prodname_codeql %} analysis," from the {% octicon "kebab-horizontal" aria-label="Menu" %} menu select {% octicon "stop" aria-hidden="true" %} Disable {% data variables.product.prodname_codeql %}. {% data reusables.code-scanning.sarif-upload-retry %}