File tree Expand file tree Collapse file tree 3 files changed +4
-2
lines changed Expand file tree Collapse file tree 3 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ Note: Can be used with `oxsecurity/megalinter@beta` in your GitHub Action mega-l
15
15
- Linter enhancements & fixes
16
16
17
17
- Core
18
+ - Fix failure of AzureCommentReporter when there is no pull request found in ENV vars
18
19
19
20
- Documentation
20
21
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ To apply file formatting you must set `XML_XMLLINT_CLI_LINT_MODE: file` and `XML
25
25
| Variable | Description | Default value |
26
26
| -----------------------------------------| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| --------------------|
27
27
| XML_XMLLINT_AUTOFORMAT | If set to ` true ` , it will reformat and reindent the output | ` false ` |
28
- | XML_XMLLINT_INDENT | The number of indentation spaces when ` XML_XMLLINT_AUTOFORMAT ` is ` true ` | ` ` |
28
+ | XML_XMLLINT_INDENT | The number of indentation spaces when ` XML_XMLLINT_AUTOFORMAT ` is ` true ` | `` |
29
29
| XML_XMLLINT_ARGUMENTS | User custom arguments to add in linter CLI call<br />Ex: ` -s --foo "bar" ` | |
30
30
| XML_XMLLINT_FILTER_REGEX_INCLUDE | Custom regex including filter<br />Ex: ` (src\|lib) ` | Include every file |
31
31
| XML_XMLLINT_FILTER_REGEX_EXCLUDE | Custom regex excluding filter<br />Ex: ` (test\|examples) ` | Exclude no file |
Original file line number Diff line number Diff line change @@ -40,12 +40,13 @@ def produce_report(self):
40
40
"SYSTEM_PULLREQUEST_PULLREQUESTID" , ""
41
41
)
42
42
if SYSTEM_PULLREQUEST_PULLREQUESTID == "" :
43
- logging .warning (
43
+ logging .info (
44
44
"[Azure Comment Reporter] Missing value SYSTEM_PULLREQUEST_PULLREQUESTID\n "
45
45
+ "You may need to configure a build validation policy to make it appear.\n "
46
46
+ "See https://docs.microsoft.com/en-US/azure/devops/repos/git/"
47
47
+ "branch-policies?view=azure-devops&tabs=browser#build-validation"
48
48
)
49
+ return
49
50
SYSTEM_TEAMPROJECT = urllib .parse .quote (config .get ("SYSTEM_TEAMPROJECT" ))
50
51
BUILD_REPOSITORY_ID = config .get ("BUILD_REPOSITORY_ID" )
51
52
BUILD_BUILDID = config .get ("BUILD_BUILDID" , config .get ("BUILD_BUILD_ID" ))
You can’t perform that action at this time.
0 commit comments