-
Notifications
You must be signed in to change notification settings - Fork 66
Modernize qlpacks #179
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
Modernize qlpacks #179
Conversation
Co-authored-by: Jeroen Ketema <93738568+jketema@users.noreply.github.com>
This reverts commit 55ff603. This only applies to CodeQL 2.10.4 and later, while 2.9.4 is being targeted here.
2ffc00e
to
37074fb
Compare
37074fb
to
9cd9638
Compare
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
🏁 Beep Boop! One or things failed during performance testing. Please check the release engineering repo for details. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
🏁 Beep Boop! One or things failed during performance testing. Please check the release engineering repo for details. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
🏁 Beep Boop! One or things failed during performance testing. Please check the release engineering repo for details. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
🏁 Beep Boop! One or things failed during performance testing. Please check the release engineering repo for details. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
🏁 Beep Boop! One or things failed during performance testing. Please check the release engineering repo for details. |
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
🏁 Beep Boop! ** Performance testing complete! See below for performance of the last 3 runs vs your PR.
|
/test-performance |
🏁 Beep Boop! Performance testing for this PR has been initiated. Please check back later for results. Note that the query package generation step must complete before testing will start so it might be a minute. |
🏁 Beep Boop! Performance testing complete! See below for performance of the last 3 runs vs your PR. Times are based on predicate performance. You can find full graphs and stats in the PR that was created for this test in the release engineering repo.
🏁 Below are the slowest predicates for the last 2 releases vs this PR.
|
Description
This PR updates the qlpacks and related files to use CodeQL packaging to declare and resolve dependencies. Neither the
codeql_modules
submodule nor thecodeql_home/codeql-stdlib
checkout ofgithub/codeql
are required anymore. The necessary dependencies can be installed by runningpython3 scripts/install-packs.py
. This need only be run when we update to a new standard library version, but it doesn't hurt to run it after every pull.None of the
codeql
commands we run should require--search-path
or--additional-packs
any longer. References within our repo are resolved automatically because all of our packs are in the same "CodeQL Workspace" (defined by our.codeqlmanifest.json
file. References to the standard library are resolved from the package download cache.Details:
codeql/
scope to all pack names, which is necessary to publish packs to the pack registry. Note that we don't actually publish to the package registry yet.dependencies:
map instead oflibraryPathDependencies:
list. The'*'
version indicates that any version will do, which is correct for the referenced packs that are found in the local workspace, rather than downloaded from the registry..codeqlmanifest.json
in thecpp
directory into the root.codeqlmanifest.json
. All pack references should resolve automatically now, without a need for--search-path
. Moreover, the manifest indicates which packs are local to the workspace and do not need to be downloaded from the registry..codeql
directories to.gitignore
..codeql
is where the output of building a query or library pack is placed.--search-path
and--additional-packs
from all of our CI workflows.qlpack.yml
files match the versions in thegithub/codeql
commit specified insupported_codeql_configs.json
. The script used by this workflow will also be used, in a future PR, in the workflow to update to a new toolset version.Change request type
.ql
,.qll
,.qls
or unit tests)Rules with added or modified queries
Release change checklist
A change note (development_handbook.md#change-notes) is required for any pull request which modifies:
If you are only adding new rule queries, a change note is not required.
Author: Is a change note required?
Reviewer: Confirm that either a change note is not required or the change note is required and has been added.
Query development review checklist
For PRs that add new queries or modify existing queries, the following checklist should be completed by both the author and reviewer:
Author
As a rule of thumb, predicates specific to the query should take no more than 1 minute, and for simple queries be under 10 seconds. If this is not the case, this should be highlighted and agreed in the code review process.
Reviewer
As a rule of thumb, predicates specific to the query should take no more than 1 minute, and for simple queries be under 10 seconds. If this is not the case, this should be highlighted and agreed in the code review process.