Skip to main content

This version of GitHub Enterprise was discontinued on 2022-06-03. No patch releases will be made, even for critical security issues. For better performance, improved security, and new features, upgrade to the latest version of GitHub Enterprise. For help with the upgrade, contact GitHub Enterprise support.

Viewing code scanning logs

You can view the output generated during code scanning analysis in your GitHub Enterprise Server instance.

If you have write permissions to a repository, you can view the code scanning logs for that repository.

Code scanning is available for organization-owned repositories where GitHub Advanced Security is enabled. For more information, see "About GitHub Advanced Security."

Note: Your site administrator must enable code scanning for your GitHub Enterprise Server instance before you can use this feature. If you want to use GitHub Actions to scan your code, the site administrator must also enable GitHub Actions and set up the infrastructure required. For more information, see "Configuring code scanning for your appliance."

About your code scanning setup

You can use a variety of tools to set up code scanning in your repository. For more information, see "Setting up code scanning for a repository."

Viewing the logging output from code scanning

This section applies to code scanning run using GitHub Actions (CodeQL or third-party).

After setting up code scanning for your repository, you can watch the output of the actions as they run.

  1. Under your repository name, click Actions. Actions tab in the main repository navigation

    You'll see a list that includes an entry for running the code scanning workflow. The text of the entry is the title you gave your commit message.

    Actions list showing code scanning workflow

  2. Click the entry for the code scanning workflow.

  3. Click the job name on the left. For example, Analyze (LANGUAGE).

    Log output from the code scanning workflow

  4. Review the logging output from the actions in this workflow as they run.

  5. Once all jobs are complete, you can view the details of any code scanning alerts that were identified. For more information, see "Managing code scanning alerts for your repository."

Note: If you raised a pull request to add the code scanning workflow to the repository, alerts from that pull request aren't displayed directly on the Code scanning page until the pull request is merged. If any alerts were found you can view these, before the pull request is merged, by clicking the n alerts found link in the banner on the Code scanning page.

Click the "n alerts found" link