-
Notifications
You must be signed in to change notification settings - Fork 329
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
Include custom query help in analysis results #804
Conversation
ffd03a1
to
cf59610
Compare
cf59610
to
eef9c63
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code change looks good, some suggestions for change note and tests.
CHANGELOG.md
Outdated
@@ -3,6 +3,7 @@ | |||
## [UNRELEASED] | |||
|
|||
- The `init` step of the Action now supports `ram` and `threads` inputs to limit resource use of CodeQL extractors. These inputs also serve as defaults to the subsequent `analyze` step, which finalizes the database and executes queries. [#738](https://github.com/github/codeql-action/pull/738) | |||
- When used with CodeQL bundle 2.7.1 or above, the action now includes custom query help (if it exists in Markdown files that have the same paths as the query files but with `.md` extension instead of `.ql`) in analysis results. [#804](https://github.com/github/codeql-action/pull/804) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How's this?
- When used with CodeQL bundle 2.7.1 or above, the action now includes custom query help (if it exists in Markdown files that have the same paths as the query files but with `.md` extension instead of `.ql`) in analysis results. [#804](https://github.com/github/codeql-action/pull/804) | |
- When used with CodeQL 2.7.1 or above, the Action now includes custom query help in the analysis results uploaded to GitHub code scanning, if available. To add help text for a custom query, create a Markdown file next to the `.ql` file containing the query, using the same base name but the file extension `.md`. [#804](https://github.com/github/codeql-action/pull/804) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is much better. I applied it to the commit.
71b4936
to
01d7f67
Compare
src/codeql.test.ts
Outdated
await codeqlObject.databaseInterpretResults("", [], "", "", "", ""); | ||
t.false( | ||
runnerConstructorStub.firstCall.args[1].includes("--sarif-add-query-help"), | ||
"--sarif-add-query-help is present" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the failure message? Perhaps "should not be present".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the suggestion. I updated the failure message.
src/codeql.test.ts
Outdated
await codeqlObject.databaseInterpretResults("", [], "", "", "", ""); | ||
t.true( | ||
runnerConstructorStub.firstCall.args[1].includes("--sarif-add-query-help"), | ||
"--sarif-add-query-help is present" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be present
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the suggestion. I updated the failure message.
01d7f67
to
9a44540
Compare
Merge / deployment checklist