Commit Graph

29 Commits

Author SHA1 Message Date
Henry Mercer 3a960869ac Simplify definitions of environment variables 2023-07-06 17:28:37 +01:00
Henry Mercer 56beae86dd Remove feature flag for exporting the code scanning configuration flag 2023-07-05 16:26:20 +01:00
Josh Soref 789f65c9ee Improving handling of uploadFailedSarifResult -> [Object object] 2023-05-25 09:15:55 -04:00
Henry Mercer 599f4927f2 Allow passing the workflow via an environment variable 2023-04-12 14:14:43 +01:00
Henry Mercer e5c2f32a9f Consistently wrap errors 2023-04-06 17:04:21 +01:00
Henry Mercer c8935d5a9d Remove duplicate locations from failed run SARIF 2023-03-24 20:30:57 +00:00
Angela P Wen a21bb7f968 Update upload input values and logic (#1598)
- The `upload` input to the `analyze` Action now accepts the following values:
    - `always` is the default value, which uploads the SARIF file to Code Scanning for successful and failed runs.
    - `failure-only` is recommended for customers post-processing the SARIF file before uploading it to Code Scanning. This option uploads debugging information to Code Scanning for failed runs to improve the debugging experience.
    - `never` avoids uploading the SARIF file to Code Scanning even if the code scanning run fails. This is not recommended for external users since it complicates debugging.
    - The legacy `true` and `false` options will be interpreted as `always` and `failure-only` respectively.

---------

Co-authored-by: Henry Mercer <henry.mercer@me.com>
2023-03-23 17:23:25 +00:00
Angela P Wen 3cbd063679 Upload per-database diagnostic SARIFs on green and red runs (#1556)
Co-authored-by: Henry Mercer <henry.mercer@me.com>
2023-03-20 21:09:04 +00:00
Henry Mercer fc1366f6ec Gate config export behind a feature flag 2023-03-09 16:44:45 +00:00
Henry Mercer d98eadb536 Export configuration information for red runs 2023-03-07 21:21:47 +00:00
Henry Mercer 5f644f971e Upgrade TypeScript to 9.2.0 2023-01-18 20:59:57 +00:00
Henry Mercer 59ebabde5d Remove redundant log messages 2022-12-22 18:47:52 +00:00
Henry Mercer 3224214d91 Improve method naming 2022-12-22 18:33:06 +00:00
Henry Mercer e09fbf5b4a Demote upload failed SARIF run info statements to debug
We now report errors via telemetry, and this feature will shortly be
enabled by default.
2022-12-21 11:41:36 +00:00
Henry Mercer 8d1e008ecb Check for successful completion rather than SARIF upload
This doesn’t affect the overall behaviour, but means we can
short-circuit slightly more quickly when `analyze` is passed
`upload: false`.
2022-12-21 11:40:31 +00:00
Henry Mercer b7b875efff Reuse existing fields in post-init status report 2022-12-12 17:54:33 +00:00
Henry Mercer 118e294bb9 Record the stack trace if applicable 2022-12-09 10:35:28 +00:00
Henry Mercer e67ad6aaed Add telemetry for uploading failed runs 2022-12-09 10:35:19 +00:00
Henry Mercer 2207a72006 Downgrade log severity when we can't upload a failed SARIF file
This isn't severe enough to appear on the Actions summary.
2022-12-06 18:18:07 +00:00
Henry Mercer 58b2ab08a8 Add unit test for typical workflow 2022-11-29 17:03:01 +00:00
Henry Mercer 00a3c456fb Always wait for processing when uploading a failed SARIF file 2022-11-29 16:27:04 +00:00
Henry Mercer e628ee0ae1 Push unsuccessful execution API error detection into upload library 2022-11-29 16:25:29 +00:00
Henry Mercer 37b4358e44 Handle API versions that reject unsuccessful executions 2022-11-25 17:55:00 +00:00
Henry Mercer 122b180b66 Add an integration test for uploading SARIF when the run fails 2022-11-25 17:54:22 +00:00
Henry Mercer 8337c2be0f Only upload failed SARIF if the run failed 2022-11-25 17:53:32 +00:00
Henry Mercer 5296a763b1 Upload failed SARIF files to Code Scanning 2022-11-25 17:52:50 +00:00
Henry Mercer f9948ffd0e Improve experience when init fails before generating a config file
Suppose a customer has a run where the init Action failed before saving
a config file.
When the customer opens their Actions logs, the UI currently focuses on
the post init step, since this is the last step that failed.
Demoting the error in the post init Action to a warning means that the
UI will instead focus on the `init` step, which is more useful for
debugging what went wrong.
2022-11-07 18:50:59 +00:00
Angela P Wen 79b933c459 Remove review comments 2022-08-11 16:47:31 +02:00
Angela P Wen 26cafd2f92 Add unit tests for post: hook run methods 2022-08-11 16:01:37 +02:00