Commit Graph

240 Commits

Author SHA1 Message Date
Michael B. Gale b8c496644d Rename variables in getGroupedSarifFilePaths 2025-09-30 12:05:59 +01:00
Michael B. Gale ad086e4d90 Use path.extname for some extension checks 2025-09-30 11:55:04 +01:00
Michael B. Gale 93711d3d89 Print a warning when there are sarifFiles in getGroupedSarifFilePaths that don't belong to an analysis kind 2025-09-29 15:07:16 +01:00
Michael B. Gale 056fb86575 Call fixCategory in uploadSpecifiedFiles
Since `fixCategory` is now part of `AnalysisConfig`, we don't have to remember to do it at the call site for `uploadSpecifiedFiles` or `uploadFiles` anymore.
2025-09-29 15:07:16 +01:00
Michael B. Gale fe0376ed1f Add getGroupedSarifFilePaths with tests 2025-09-29 15:07:13 +01:00
Paolo Tranquilli 4c534612bf Tweak sarif dump log 2025-09-10 07:52:59 +02:00
Paolo Tranquilli dae3742b0a Dump soon to be uploaded SARIF on request
This introduces a new internal environment variable flag
(`CODEQL_ACTION_SARIF_DUMP_DIR`) that, when set to `true`, causes the
SARIF file that will be uploaded to be dumped to the specified
directory. The filename will be `upload.sarif` or `upload.quality.sarif`
depending on the upload target.
2025-09-10 07:46:05 +02:00
Michael B. Gale 51d74ac81c Remove default arguments from uploadSpecifiedFiles and validateUniqueCategory 2025-09-04 11:44:36 +01:00
Michael B. Gale 01627081ff Rename UploadTarget to AnalysisConfig 2025-09-04 11:39:18 +01:00
Michael B. Gale ca7dd4ad38 Move UploadTarget definitions to analyses.ts 2025-09-04 11:38:53 +01:00
Henry Mercer 943116bc89 Use url.pathToFileURL instead of file-url 2025-08-29 19:17:34 +01:00
Henry Mercer 5848d111cd Bump log visibility for failed analysis upload
Make it more obvious that the SARIF file for the unsuccessful execution was successfully uploaded.
2025-08-15 17:57:13 +01:00
Henry Mercer 1afa0e7463 Cleanup extract to toolcache feature flag 2025-08-08 11:26:14 +01:00
Henry Mercer ea05bf27b6 Use more explicit checks on .length for readability 2025-08-05 17:55:50 +01:00
Koen Vlaswinkel a005f73253 Remove disable_combine_sarif_files feature flag 2025-07-24 11:12:32 +02:00
Koen Vlaswinkel 5a29823d01 Merge remote-tracking branch 'origin/main' into koesie10/disable-combine-single-file 2025-07-23 14:03:16 +02:00
Koen Vlaswinkel 287d421cf3 Disable combining runs within a single file 2025-07-23 13:51:13 +02:00
Michael B. Gale 43afe6ec0b Treat processing error for multiple runs with the same category as configuration error
This will result in it being reported as a user error rather than a failure
2025-07-23 12:48:44 +01:00
Koen Vlaswinkel 48ce740f61 Update combining SARIF runs changelog post URL 2025-07-22 11:51:12 +02:00
Koen Vlaswinkel e30db30685 Ignore pre-release parts when comparing GHES versions 2025-07-16 11:51:53 +02:00
Arthur Baars 15605b194f Make eslint happy 2025-07-15 07:31:22 +00:00
Arthur Baars ca53360d04 Fix tests 2025-07-15 07:25:49 +00:00
Koen Vlaswinkel 59d67fc4bf Fix parsing of GHES pre-release versions 2025-07-14 11:25:20 +02:00
Koen Vlaswinkel aafbeb29bc Unconditionally disable combining SARIF files for GHES 3.18 2025-07-04 15:24:36 +02:00
Koen Vlaswinkel 612df8d91c Remove support for combining SARIF runs with non-unique categories 2025-07-01 15:20:28 +02:00
Michael B. Gale 65d1e45f0b Rename SARIF_UPLOAD_ENDPOINT members 2025-06-27 13:45:14 +01:00
Michael B. Gale 10a3e4b17d Fix formatting 2025-06-27 12:32:56 +01:00
Michael B. Gale ad6046ff97 Avoid default arguments with historical values 2025-06-26 13:51:08 +01:00
Michael B. Gale 08955dbc0d Move .sarif predicates into UploadTarget instances and rename 2025-06-26 11:43:36 +01:00
Michael B. Gale 71dd63398f Rename SARIF_UPLOAD_TARGET 2025-06-26 11:38:45 +01:00
Michael B. Gale 2c76207fa4 Upload .quality.sarif files to CQ service in upload-sarif action 2025-06-25 13:43:39 +01:00
Michael B. Gale 86f47e8b74 Add some more comments 2025-06-24 13:59:46 +01:00
Michael B. Gale 51891595a7 Add test for modified findSarifFilesInDir 2025-06-24 13:24:04 +01:00
Michael B. Gale 6abacdb184 Fix getSarifFilePaths not using right filter 2025-06-23 18:19:43 +01:00
Michael B. Gale f1834221f2 Allow the same category once for each type of upload 2025-06-23 18:19:43 +01:00
Michael B. Gale 45b3bec064 Upload quality SARIFs to CQ endpoint 2025-06-23 18:19:42 +01:00
Michael B. Gale 22444a650f Add ability to use different filters in findSarifFilesInDir 2025-06-23 18:19:42 +01:00
Henry Mercer 15f19ac220 Improve docstring
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-14 15:21:38 +01:00
Henry Mercer 2f70a988e7 Skip validating SARIF produced by CodeQL 2025-05-14 15:11:16 +01:00
Fotis Koutoulakis (@NlightNFotis) 676a422916 review-comments: nest validateSariFileSchema into try-catch block to better discriminate error thrown 2025-04-02 19:06:31 +01:00
Fotis Koutoulakis (@NlightNFotis) b53826d56d review-comments: remove syntax-error handling for SARIF from upload-lib 2025-04-01 15:10:16 +01:00
Fotis Koutoulakis (@NlightNFotis) 01f1a1f2c9 Merge branch 'main' into NlightNFotis/reclassify_upload_sarif_issues 2025-03-31 16:29:02 +01:00
Fotis Koutoulakis (@NlightNFotis) 72a2b1295e feat: classify some observed SARIF errors as InvalidSarifUploadError 2025-03-31 12:17:23 +01:00
Chuan-kai Lin 534bc63d5e Rename diff-filtering-utils.ts to diff-informed-analysis-utils.ts 2025-03-27 10:27:23 -07:00
Chuan-kai Lin f88459c0a3 Use getRepositoryNwo() 2025-03-26 10:18:40 -07:00
Chuan-kai Lin dae1626680 Filter alerts by pr-diff-range JSON file 2025-02-19 06:26:11 -08:00
Chuan-kai Lin b0cd76b9fb Move Git functions to git-utils.ts 2024-12-10 08:44:11 -08:00
github-actions[bot] 44e03577b2 Rebuild 2024-12-03 18:39:38 +00:00
Fotis Koutoulakis (@NlightNFotis) 5445a29a97 tests: instead of false, use old feature flag with default value of false 2024-11-12 17:59:47 +00:00
Henry Mercer 33f2dc57a4 Enable zstd bundles on GHES and remove feature flag 2024-11-01 15:24:51 +00:00