Skip to content

Commit 4d4aba1

Browse files
[EDI] Logs are not detailed enough (#59867)
Co-authored-by: mc <42146119+mchammer01@users.noreply.github.com>
1 parent 4ac4ac8 commit 4d4aba1

File tree

1 file changed

+15
-6
lines changed

1 file changed

+15
-6
lines changed

content/code-security/reference/code-scanning/troubleshoot-analysis-errors/logs-not-detailed-enough.md

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: Logs are not detailed enough
33
shortTitle: Logs not detailed enough
4-
intro: If you'd like to increase the level of detail in your logs, try these steps.
4+
intro: Increase log verbosity and generate debugging artifacts when logs lack diagnostic detail.
55
allowTitleToDifferFromFilename: true
66
versions:
77
fpt: '*'
@@ -16,9 +16,18 @@ contentType: reference
1616

1717
If your logs are not detailed enough to troubleshoot a problem, there are several steps you can take to obtain extra information and make logs more useful.
1818

19-
## Enable step debug logging
19+
## Enabling step debug logging
2020

21-
You can enable step debug logging in {% data variables.product.prodname_actions %} to increase the verbosity of a job's logs during a job's execution. For more information, see [AUTOTITLE](/actions/monitoring-and-troubleshooting-workflows/enabling-debug-logging#enabling-step-debug-logging).
21+
Step debug logging increases the verbosity of a job’s logs during and after execution.
22+
23+
To enable step debug logging:
24+
25+
1. In the repository that contains the workflow, set the following secret or variable: `ACTIONS_STEP_DEBUG` to `true`. If both the secret and variable are set, the value of the secret takes precedence over the variable.
26+
1. Re-run the workflow or trigger a new run.
27+
28+
After setting the secret or variable, more debug events are shown in the step logs. See [AUTOTITLE](/actions/monitoring-and-troubleshooting-workflows/using-workflow-run-logs#viewing-logs-to-diagnose-failures).
29+
30+
You can also use the `runner.debug` context to conditionally run steps only when debug logging is enabled. See [AUTOTITLE](/actions/reference/workflows-and-actions/contexts#runner-context).
2231

2332
## Creating {% data variables.product.prodname_codeql %} debugging artifacts
2433

@@ -28,11 +37,11 @@ You can enable step debug logging in {% data variables.product.prodname_actions
2837
You can obtain artifacts to help you debug {% data variables.product.prodname_codeql %}.
2938
The debug artifacts will be uploaded to the workflow run as artifacts with names starting with `debug-artifacts`. If {% data variables.product.prodname_codeql %} analyzes multiple languages concurrently as part of the workflow run, there will be one such artifact for every language. The data contains the {% data variables.product.prodname_codeql %} logs, {% data variables.product.prodname_codeql %} databases, extracted source code files, and any SARIF files produced by the workflow. For more information about downloading {% data variables.product.prodname_codeql %} artifacts, see [AUTOTITLE](/actions/managing-workflow-runs/downloading-workflow-artifacts).
3039

31-
These artifacts will help you debug problems with {% data variables.product.prodname_codeql %} {% data variables.product.prodname_code_scanning %}. If you contact GitHub support, they might ask for this data.
40+
These artifacts will help you debug problems with {% data variables.product.prodname_codeql %} {% data variables.product.prodname_code_scanning %}. If you contact {% data variables.contact.github_support %}, they might ask for this data.
3241

3342
### Creating {% data variables.product.prodname_codeql %} debugging artifacts for {% data variables.product.prodname_codeql %} default setup
3443

35-
You can create {% data variables.product.prodname_codeql %} debugging artifacts by enabling {% data variables.product.prodname_actions %} step debug logging and triggering a new {% data variables.product.prodname_codeql %} analysis by, for example, pushing a new commit to a pull request branch. For information on how to enable {% data variables.product.prodname_actions %} step debug logging, see [AUTOTITLE](/actions/monitoring-and-troubleshooting-workflows/enabling-debug-logging#enabling-step-debug-logging).
44+
You can create {% data variables.product.prodname_codeql %} debugging artifacts by enabling step debug logging (see [Enabling step debug logging](#enabling-step-debug-logging)) and triggering a new {% data variables.product.prodname_codeql %} analysis, for example, by pushing a new commit to a pull request branch.
3645

3746
{% ifversion org-private-registry %}
3847

@@ -63,4 +72,4 @@ You can create {% data variables.product.prodname_codeql %} debugging artifacts
6372
6473
#### Using {% data variables.product.prodname_actions %} step debug logging
6574
66-
If you have enabled {% data variables.product.prodname_actions %} step debug logging, {% data variables.product.prodname_codeql %} will also produce debugging artifacts and upload them. See [AUTOTITLE](/actions/monitoring-and-troubleshooting-workflows/enabling-debug-logging#enabling-step-debug-logging).
75+
If you enable {% data variables.product.prodname_actions %} step debug logging, {% data variables.product.prodname_codeql %} will also produce debugging artifacts and upload them as part of the workflow run. For instructions, see [Enabling step debug logging](#enabling-step-debug-logging).

0 commit comments

Comments
 (0)