Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add required executionSuccessful attribute to SARIF output #2983

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html
### Fixed
- Capturing functions when used as both expressions and statements in JS (#1007)
- Literal for ocaml tree sitter (#2885)
- SARIF output now contains the required runs.invocations.executionSuccessful property.

### Changed
- The `extra` `lines` data is now consistent across scan types
Expand Down
1 change: 1 addition & 0 deletions semgrep/semgrep/output.py
Original file line number Diff line number Diff line change
Expand Up @@ -307,6 +307,7 @@ def build_sarif_output(
"results": [match.to_sarif() for match in rule_matches],
"invocations": [
{
"executionSuccessful": True,
"toolExecutionNotifications": [
_sarif_notification_from_error(e)
for e in semgrep_structured_errors
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
{
"invocations": [
{
"executionSuccessful": true,
"toolExecutionNotifications": []
}
],
Expand Down