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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge releases/v2 into releases/v1 #1195

Merged
merged 134 commits into from Aug 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
134 commits
Select commit Hold shift + click to select a range
2a70419
Revert "Revert "Add capability to filter queries #1098""
aeisenberg Jun 27, 2022
237260b
Revert "Revert usage of `--codescanning-config` flag"
aeisenberg Jun 17, 2022
6fabde2
Add packs and queries from input
aeisenberg Jun 19, 2022
8688a09
When using codescanning config call run queries a single time
aeisenberg Jun 29, 2022
01d16b1
Merge branch 'main' into aeisenberg/fix-config-files
aeisenberg Jul 13, 2022
4e46a69
Merge branch 'main' into aeisenberg/fix-config-files
aeisenberg Jul 25, 2022
907f1de
Merge branch 'main' into aeisenberg/fix-config-files
aeisenberg Jul 28, 2022
1016eba
Move logs, SARIF actions uploads to post: hooks
angelapwen Jul 29, 2022
2746051
Catch case where database isn't finalized
angelapwen Jul 29, 2022
81c5b2d
New debug artifacts workflow with separate jobs
angelapwen Aug 1, 2022
2c25894
Zip partial database directory
angelapwen Aug 1, 2022
52de49c
Refactor helper function to util
angelapwen Aug 1, 2022
ebc59ec
More descriptive partial db bundle messages
angelapwen Aug 1, 2022
af87cc6
Improve for `matrix`
angelapwen Aug 1, 2022
6630cbe
Minor syntax update
angelapwen Aug 1, 2022
8a4a573
Error handling for JSON parsing
angelapwen Aug 1, 2022
5da7870
Refactoring per PR comments
angelapwen Aug 1, 2022
5229df1
Add unit test descriptions
angelapwen Aug 1, 2022
daaac43
Linting, node_modules update
angelapwen Aug 1, 2022
cc047a3
Condense matrix syntax
angelapwen Aug 2, 2022
13e7a52
Change download job to only run on linux
angelapwen Aug 2, 2022
64d83c7
Fix syntax error
angelapwen Aug 2, 2022
a557279
Clean up syntax per PR review
angelapwen Aug 2, 2022
44a27e6
Add top level comments, rename cleanup to post
angelapwen Aug 2, 2022
5895ab0
Address more PR comments, refactoring
angelapwen Aug 2, 2022
eeee462
Move debug artifact methods into separate file
angelapwen Aug 2, 2022
a758ec5
Add more info messages to user, rename log printing function
angelapwen Aug 2, 2022
7f86ddc
Move debug log printing back to actions util
angelapwen Aug 2, 2022
ef145d6
Display downloaded file structure
angelapwen Aug 3, 2022
f7a7ac1
bash syntax fixup
angelapwen Aug 3, 2022
f51da86
Add script to check in appropriate directories
angelapwen Aug 3, 2022
e16d085
Remove ls check, log formatting
angelapwen Aug 3, 2022
4ec485d
bash syntax fixup per review
angelapwen Aug 3, 2022
2d4d9d8
Update changelog and version after v2.1.18
invalid-email-address Aug 3, 2022
bb2956f
Update checked-in dependencies
invalid-email-address Aug 3, 2022
1a0331c
Merge pull request #1167 from github/mergeback/v2.1.18-to-main-2ca79b6f
cklin Aug 3, 2022
2a582eb
Merge branch 'main' into angelapwen/refactor-debug-artifacts-pr-check
angelapwen Aug 4, 2022
9990b40
Merge pull request #1160 from github/angelapwen/refactor-debug-artifa…
angelapwen Aug 4, 2022
38c2c09
Add dependency on `@actions/cache`
edoardopirovano Aug 3, 2022
693d3f2
Merge pull request #1164 from github/edoardo/add-cache-dep
edoardopirovano Aug 5, 2022
2d5738c
Add option to override TRAP caching feature flag
edoardopirovano Aug 5, 2022
cade2b5
Merge pull request #1170 from github/edoardo/add-trap-cache-option
edoardopirovano Aug 5, 2022
0e3ae6e
fix: clarify upload-sarify category uniqueness error message
Aug 5, 2022
8f867dc
Introduce TRAP caching
edoardopirovano Aug 2, 2022
010abe7
Merge remote-tracking branch 'origin/main' into angelapwen/post-init-…
angelapwen Aug 8, 2022
b952980
Add integration test for failed analyze step
angelapwen Aug 8, 2022
6bc2291
Add description in CHANGELOG
angelapwen Aug 8, 2022
05176bc
Add continue-on-error for expected failing job
angelapwen Aug 8, 2022
1c82b1b
Display downloaded files structure
angelapwen Aug 8, 2022
27df4c2
Fix directory name of artifacts
angelapwen Aug 8, 2022
4993f1e
Remove downloaded files structure display
angelapwen Aug 8, 2022
8903097
Remove database init test for success case
angelapwen Aug 9, 2022
ff7a29d
Clarify expected failure for upload job
angelapwen Aug 9, 2022
6df9361
Address review comments from @henrymercer
edoardopirovano Aug 9, 2022
07720c7
Merge pull request #1172 from github/edoardo/trap-caching
edoardopirovano Aug 9, 2022
3835e64
Remove distrust of `GITHUB_ACTION_REF` for local actions
edoardopirovano Aug 10, 2022
c7db5d9
Merge pull request #1174 from github/edoardo/remove-workaround
edoardopirovano Aug 10, 2022
484a72c
Add utilities unit tests
angelapwen Aug 10, 2022
90676d9
Merge remote-tracking branch 'origin/main' into angelapwen/post-init-…
angelapwen Aug 10, 2022
3c4f458
Re-declare codeql var
angelapwen Aug 10, 2022
a6d0901
Merge pull request #1171 from crenshaw-dev/clarify-category-error-mes…
aeisenberg Aug 10, 2022
44f42da
Merge branch 'main' into aeisenberg/unrevert-query-filters
aeisenberg Aug 10, 2022
0403fb7
Merge branch 'main' into aeisenberg/fix-config-files
aeisenberg Aug 10, 2022
2314063
Add the `defaultAugmentationProperties` constant
aeisenberg Aug 10, 2022
bbdc9ef
Use the API URL from the environment if it is present.
chrisgavin Aug 10, 2022
65d6ee0
Address review comments
angelapwen Aug 11, 2022
fa59c28
Update CHANGELOG.md wording
angelapwen Aug 11, 2022
d909f71
Update comment wording
angelapwen Aug 11, 2022
4e121c0
Address additional review comments
angelapwen Aug 11, 2022
6fdaff6
Improve file system unit tests
angelapwen Aug 11, 2022
15608ce
Merge remote-tracking branch 'origin/main' into angelapwen/post-init-…
angelapwen Aug 11, 2022
26cafd2
Add unit tests for post: hook run methods
angelapwen Aug 11, 2022
fd83e55
Remove extraneous files
angelapwen Aug 11, 2022
172eca4
Improve doesDirectoryExist test
angelapwen Aug 11, 2022
cf7f893
Make file paths OS-agnostic
angelapwen Aug 11, 2022
79b933c
Remove review comments
angelapwen Aug 11, 2022
b659ce5
Merge pull request #1159 from github/angelapwen/post-init-cleanup
angelapwen Aug 11, 2022
7c6fa5c
Remove an unneeded `if`.
chrisgavin Aug 11, 2022
07e8996
Merge main into local.
chrisgavin Aug 11, 2022
a09a029
Fix failing test and address PR comments
aeisenberg Aug 11, 2022
d74f663
Merge remote-tracking branch 'upstream/main' into aeisenberg/fix-conf…
aeisenberg Aug 11, 2022
072cd92
Merge remote-tracking branch 'upstream/main' into aeisenberg/unrevert…
aeisenberg Aug 11, 2022
0495378
Bump @types/long from 4.0.1 to 5.0.0
dependabot[bot] Aug 11, 2022
ccfb4e2
Update checked-in dependencies
invalid-email-address Aug 11, 2022
d101dd6
Merge pull request #1175 from github/local
chrisgavin Aug 11, 2022
bcf4720
Merge remote-tracking branch 'upstream/main' into aeisenberg/unrevert…
aeisenberg Aug 11, 2022
c12cfbc
Merge pull request #1127 from github/aeisenberg/unrevert-query-filters
aeisenberg Aug 11, 2022
fa2bc21
Merge branch 'aeisenberg/unrevert-query-filters' into aeisenberg/fix-…
aeisenberg Aug 11, 2022
68f1d68
Merge remote-tracking branch 'origin/main' into dependabot/npm_and_ya…
henrymercer Aug 12, 2022
1e8043f
Update default CodeQL version to 2.10.3
henrymercer Aug 12, 2022
5836ad9
Merge pull request #1176 from github/dependabot/npm_and_yarn/types/lo…
henrymercer Aug 12, 2022
680d08e
Merge pull request #1105 from github/aeisenberg/fix-config-files
aeisenberg Aug 12, 2022
af9d911
Merge remote-tracking branch 'origin/main' into henrymercer/codeql-cl…
henrymercer Aug 15, 2022
f9bce02
Merge pull request #1178 from github/henrymercer/codeql-cli-2.10.3
henrymercer Aug 15, 2022
909e2fd
Disable python2 + pipenv tests
RasmusWL Aug 15, 2022
c8cb2b4
Update CHANGELOG.md
RasmusWL Aug 15, 2022
b3adcb7
Merge pull request #1181 from github/RasmusWL/disable-python2-pipenv
RasmusWL Aug 15, 2022
d8adbe9
Fix cache key for TRAP caching
edoardopirovano Aug 16, 2022
ca10a6d
Merge pull request #1183 from github/edoardo/fix-cache-key
edoardopirovano Aug 16, 2022
4139682
Add telemetry for TRAP caching
edoardopirovano Aug 15, 2022
b29194f
Address review comments from @henrymercer
edoardopirovano Aug 16, 2022
8a4437a
Merge pull request #1182 from github/edoardo/trap-cache-telemetry
edoardopirovano Aug 16, 2022
016a5e3
Use `util.promisify` instead of manually constructing promise
edoardopirovano Aug 16, 2022
b0d61cf
Merge pull request #1184 from github/edoardo/trap-telemetry-followup
edoardopirovano Aug 16, 2022
df0c0da
Add bypass toolcache feature flag
henrymercer Aug 16, 2022
5862bae
Bypass toolcache when feature flag enabled
henrymercer Aug 16, 2022
96a8424
Don't bypass the toolcache in test mode
henrymercer Aug 16, 2022
d45b0eb
Improve readability of CodeQL bundle tests
henrymercer Aug 16, 2022
e1cd41a
Add tests for toolcache bypassing
henrymercer Aug 16, 2022
9b7fa3d
Add `expect-error` input to force PR check green on expected failure …
angelapwen Aug 16, 2022
8beb190
Update supported GitHub Enterprise Server versions.
web-flow Aug 17, 2022
8bc36d5
Merge pull request #1187 from github/update-supported-enterprise-serv…
edoardopirovano Aug 17, 2022
416ad3d
Merge branch 'main' into henrymercer/bypass-toolcache-feature-flag
henrymercer Aug 17, 2022
f47f573
Add a debug log message when forcing the latest tools
henrymercer Aug 17, 2022
b469d53
Tweak debug logging message
henrymercer Aug 17, 2022
7d94bb8
Merge pull request #1185 from github/henrymercer/bypass-toolcache-fea…
henrymercer Aug 17, 2022
eb6f272
Round fields in TRAP caching telemetry to integers
edoardopirovano Aug 17, 2022
5f4cfb0
Merge pull request #1188 from github/edoardo/round-fields
edoardopirovano Aug 17, 2022
ff9d53b
Dump GitHub event in debug artifacts failure workflow
henrymercer Aug 17, 2022
219a937
Require test mode to be set to use `expect-error` input
henrymercer Aug 17, 2022
b21cab9
Mock `expect-error` input to avoid errors in Action integration tests
henrymercer Aug 17, 2022
3154c4f
Merge pull request #1190 from github/henrymercer/fix-debug-artifact-t…
henrymercer Aug 17, 2022
0349bb0
Fix TRAP cache upload timing
edoardopirovano Aug 17, 2022
5502fef
Merge pull request #1191 from github/edoardo/fix-upload-times
edoardopirovano Aug 17, 2022
04ea3b1
Update changelog for v2.1.19
invalid-email-address Aug 17, 2022
7c3d74c
Move changelog note to right release
henrymercer Aug 17, 2022
f5d217b
Merge pull request #1192 from github/update-v2.1.19-5502fefd
henrymercer Aug 19, 2022
2d1b5eb
Revert "Update version and changelog for v1.1.18"
invalid-email-address Aug 19, 2022
2505212
Revert "Update checked-in dependencies"
invalid-email-address Aug 19, 2022
d5aef51
Merge remote-tracking branch 'origin/releases/v2' into update-v1.1.19…
invalid-email-address Aug 19, 2022
3af72a7
Update version and changelog for v1.1.19
invalid-email-address Aug 19, 2022
fbab93d
Resolve merge conflicts
henrymercer Aug 19, 2022
b7435e9
Explicitly import `performance` for Node 12 compatibility
henrymercer Aug 19, 2022
de68405
Update checked-in dependencies
invalid-email-address Aug 19, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
60 changes: 60 additions & 0 deletions .github/check-codescanning-config/action.yml
@@ -0,0 +1,60 @@
name: Check Code-Scanning Config
description: |
Checks the code scanning configuration file generated by the
action to ensure it contains the expected contents
inputs:
languages:
required: false
description: The languages field passed to the init action.

packs:
required: false
description: The packs field passed to the init action.

queries:
required: false
description: The queries field passed to the init action.

config-file-test:
required: false
description: |
The location of the config file to use. If empty,
then no config file is used.

expected-config-file-contents:
required: true
description: |
A JSON string containing the exact contents of the config file.

tools:
required: true
description: |
The url of codeql to use.

runs:
using: composite
steps:
- uses: ./../action/init
with:
languages: ${{ inputs.languages }}
config-file: ${{ inputs.config-file-test }}
queries: ${{ inputs.queries }}
packs: ${{ inputs.packs }}
tools: ${{ inputs.tools }}
db-location: ${{ runner.temp }}/codescanning-config-cli-test

- name: Install dependencies
shell: bash
run: npm install --location=global ts-node js-yaml

- name: Check config
working-directory: ${{ github.action_path }}
shell: bash
run: ts-node ./index.ts "${{ runner.temp }}/user-config.yaml" '${{ inputs.expected-config-file-contents }}'

- name: Clean up
shell: bash
if: always()
run: |
rm -rf ${{ runner.temp }}/codescanning-config-cli-test
rm -rf ${{ runner.temp }}/user-config.yaml
39 changes: 39 additions & 0 deletions .github/check-codescanning-config/index.ts
@@ -0,0 +1,39 @@

import * as core from '@actions/core'
import * as yaml from 'js-yaml'
import * as fs from 'fs'
import * as assert from 'assert'

const actualConfig = loadActualConfig()

const rawExpectedConfig = process.argv[3].trim()
if (!rawExpectedConfig) {
core.info('No expected configuration provided')
} else {
core.startGroup('Expected generated user config')
core.info(yaml.dump(JSON.parse(rawExpectedConfig)))
core.endGroup()
}

const expectedConfig = rawExpectedConfig ? JSON.parse(rawExpectedConfig) : undefined;

assert.deepStrictEqual(
actualConfig,
expectedConfig,
'Expected configuration does not match actual configuration'
);


function loadActualConfig() {
if (!fs.existsSync(process.argv[2])) {
core.info('No configuration file found')
return undefined
} else {
const rawActualConfig = fs.readFileSync(process.argv[2], 'utf8')
core.startGroup('Actual generated user config')
core.info(rawActualConfig)
core.endGroup()

return yaml.load(rawActualConfig)
}
}
6 changes: 4 additions & 2 deletions .github/query-filter-test/action.yml
@@ -1,5 +1,5 @@
name: Query Filter Test
description: Runs a test of query filters using the check sarif action
description: Runs a test of query filters using the check SARIF action
inputs:
sarif-file:
required: true
Expand Down Expand Up @@ -34,6 +34,8 @@ runs:
config-file: ${{ inputs.config-file }}
tools: ${{ inputs.tools }}
db-location: ${{ runner.temp }}/query-filter-test
env:
TEST_MODE: "true"
- uses: ./../action/analyze
with:
output: ${{ runner.temp }}/results
Expand All @@ -49,4 +51,4 @@ runs:
queries-not-run: ${{ inputs.queries-not-run}}
- name: Cleanup after test
shell: bash
run: rm -rf "$RUNNER_TEMP/results" "$RUNNER_TEMP//query-filter-test"
run: rm -rf "$RUNNER_TEMP/results" "$RUNNER_TEMP/query-filter-test"
2 changes: 2 additions & 0 deletions .github/workflows/__analyze-ref-input.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions .github/workflows/__autobuild-action.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

96 changes: 0 additions & 96 deletions .github/workflows/__debug-artifacts.yml

This file was deleted.

2 changes: 2 additions & 0 deletions .github/workflows/__extractor-ram-threads.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions .github/workflows/__go-custom-queries.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions .github/workflows/__go-custom-tracing-autobuild.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions .github/workflows/__go-custom-tracing.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions .github/workflows/__javascript-source-root.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 11 additions & 0 deletions .github/workflows/__ml-powered-queries.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions .github/workflows/__multi-language-autodetect.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.