Commit Graph

47021 Commits

Author SHA1 Message Date
Tom Hvitved
f7fc61e39d Merge pull request #11336 from hvitved/ruby/ci-check-undefined-labels
Ruby: Add `--check-undefined-labels` to QL test job
2022-11-21 13:36:52 +01:00
AlexDenisov
6f52fe81d1 Merge pull request #11331 from github/redsun82/swift-codegen-skip-unchanged
Swift: skip QL code generation on untouched files
2022-11-21 13:34:41 +01:00
Erik Krogh Kristensen
b6dd388bdb Merge pull request #11328 from erik-krogh/removeQlCompCheck
QL/RB: delete language specific codeql query compile checks
2022-11-21 10:51:52 +01:00
Tom Hvitved
1dbcf8eb10 Ruby: Add --check-undefined-labels to QL test job 2022-11-20 10:16:35 +01:00
erik-krogh
41e8170d59 delete the rest of the qlcompile job in Ruby 2022-11-19 11:16:24 +01:00
Erik Krogh Kristensen
a69524f7b4 Merge pull request #11318 from erik-krogh/deleteMoreDeps
delete old deprecations
2022-11-19 11:15:12 +01:00
Henry Mercer
a964325724 Merge pull request #11332 from sigfaulterror/patch-1
Update analyzing-databases-with-the-codeql-cli.rst
2022-11-18 18:47:14 +00:00
sigfaulterror
a97570be63 Update analyzing-databases-with-the-codeql-cli.rst
just small doc error
2022-11-18 18:54:03 +01:00
Paolo Tranquilli
aaa96b20ed Swift: fix python compatibility with CI 2022-11-18 17:51:20 +01:00
Paolo Tranquilli
6dcdf8c71f Swift: fix bazel setup 2022-11-18 17:22:44 +01:00
Paolo Tranquilli
aeb7b0d050 Swift: remove ModifiedStubMarkedAsGeneratedError 2022-11-18 17:13:12 +01:00
Paolo Tranquilli
2cd58817d7 Swift: skip QL code generation on untouched files
This is a developer QoL improvement, where running codegen will skip
writing (and especially formatting) any files that were not changed.

**Why?** While code generation in itself was pretty much instant, QL
formatting of generated code was starting to take a long time. This made
unconditionally running codegen quite annoying, for example before each
test run as part of an IDE workflow or as part of the pre-commit hook.

**How?** This was not completely straightforward as we could not work
with the contents of the file prior to code generation as that was
already post-processed by the QL formatting, so we had no chance of
comparing the output of template rendering with that. We therefore store
the hashes of the files _prior_ to QL formatting in a checked-in file
(`swift/ql/.generated.list`). We can therefore load those hashes at
the beginning of code generation, use them to compare the template
rendering output and update them in this special registry file.

**What else?** We also extend this mechanism to detect accidental
modification of generated files in a more robust way. Before this patch,
we were doing it with a rough regexp based heuristic. Now, we just store
the hashes of the files _after_ QL formatting in the same checked file,
so we can check that and stop generation if a generated file was
modified, or a stub was modified without removing the `// generated`
header.
2022-11-18 16:56:01 +01:00
Taus
07969260c8 Merge pull request #11132 from erik-krogh/parentQl
QL: fix non-attached annotations for newtype branches
2022-11-18 15:45:02 +01:00
erik-krogh
3cdfed9483 CI: delete language specific codeql query compile checks 2022-11-18 14:41:29 +01:00
Erik Krogh Kristensen
e777934290 Merge pull request #11316 from erik-krogh/examplesComp
CI: Also compile the `examples` folder
2022-11-18 12:29:03 +01:00
erik-krogh
7c091fa6cd also compile the examples folders as part of the compilation check 2022-11-18 10:31:42 +01:00
erik-krogh
23dc977d48 add a severity to incompleteswitchoverenum.ql to fix a compiler warning 2022-11-18 10:29:42 +01:00
erik-krogh
468a879c1f Python: delete dead code. thanks QL-for-QL 2022-11-17 22:12:51 +01:00
erik-krogh
ba2734909f JS: don't use deprecated files in tests 2022-11-17 22:12:50 +01:00
erik-krogh
3635db8244 JS: delete the deprecated [queryName].qll files 2022-11-17 22:12:50 +01:00
erik-krogh
635b8772d7 JS: delete old deprecations 2022-11-17 22:12:50 +01:00
erik-krogh
e491b61e09 Python: move the contents of PEP249Impl to PEP249, which is possible now that the deprecations have been deleted 2022-11-17 22:12:50 +01:00
erik-krogh
a7ba693ccb Python: delete old deprecations 2022-11-17 22:12:50 +01:00
erik-krogh
a4e5d752e1 Java: delete old deprecations 2022-11-17 22:12:50 +01:00
erik-krogh
d5ec781d4c C#: delete old deprecations 2022-11-17 22:12:50 +01:00
erik-krogh
a5a244fc53 CPP: delete old deprecations 2022-11-17 22:12:50 +01:00
Chris Smowton
e83cc59cba Merge pull request #11296 from smowton/smowton/fix/kotlin-string-literal-formatting
Kotlin: format string literals like the Java annotaton extractor
2022-11-17 20:04:09 +00:00
Chris Smowton
cf34dbd276 Kotlin: format string literals like the Java annotaton extractor
Java's regular strings are formatted as they appear in source, but we don't easily have this information available in Kotlin. During annotation extraction however it guesses a source rendering because the source is not necessarily available. By formatting to match the annotation extractor, we prepare to ensure consistency with a Java database
when extracting annotations as seen by Kotlin.
2022-11-17 17:28:17 +00:00
Owen Mansel-Chan
ac54da7d93 Merge pull request #11002 from owen-mc/dataflow/sync-go-libraries
Update go libraries to 55e052a
2022-11-17 15:22:31 +00:00
Owen Mansel-Chan
4073d77635 Add change notes 2022-11-17 14:27:07 +00:00
Owen Mansel-Chan
ab15a19028 Address review comments 2022-11-17 14:27:07 +00:00
Owen Mansel-Chan
166a3688f8 Use standard variable names for hasLocationInfo
This makes them match the QLDoc and also other implementations of
`hasLocationInfo`.
2022-11-17 14:27:07 +00:00
Owen Mansel-Chan
1a65a27fde Update test expectations
In https://github.com/github/codeql/pull/8641, `localFlowExit` was
changed to use `Stage2::readStepCand` instead of `read`, which means
that the big-step relation is broken up less. This causes test result
changes. Nothing is lost from the `select` clause, but some results may
have fewer paths, and fewer nodes and edges are output in the test
results.
2022-11-17 14:27:06 +00:00
Owen Mansel-Chan
71aeeee7c8 Accept trivial change to test output
In the `subpaths` section, the last node is now printed without its type
if it is the sink of the path.

This comes from the commit "Dataflow: Bugfix: include subpaths ending at
a sink. " in https://github.com/github/codeql/pull/7526
2022-11-17 14:27:06 +00:00
Owen Mansel-Chan
f2e2c02db6 Rename predicates to avoid clashes 2022-11-17 14:27:06 +00:00
Owen Mansel-Chan
1718ef88be Data flow: Inline local(Expr)?(Flow|Taint)
See https://github.com/github/codeql/pull/7791
2022-11-17 14:27:05 +00:00
Owen Mansel-Chan
736435adda Go: Add stub expectsContent
Corresponds to https://github.com/github/codeql/pull/8870
2022-11-17 14:27:05 +00:00
Owen Mansel-Chan
50210a9d24 Go: ParameterPosition and ArgumentPosition
Corresponds to https://github.com/github/codeql/pull/7260, though some
of those changes had already been made.
2022-11-17 14:27:05 +00:00
Owen Mansel-Chan
83a3af2fff Go: Summarized Callable
Corresponds to https://github.com/github/codeql/pull/9270
2022-11-17 14:27:04 +00:00
Owen Mansel-Chan
10ed4ad3df Go: Split summaryThroughStep into two predicates
Cf. https://github.com/github/codeql/pull/9195
2022-11-17 14:27:04 +00:00
Owen Mansel-Chan
1ee5d3e80e Move ParameterPosition etc to DataflowDispatch.qll 2022-11-17 14:27:04 +00:00
Owen Mansel-Chan
e5829201e1 Go: Implement ContentSet 2022-11-17 14:27:03 +00:00
Owen Mansel-Chan
282699e5b5 Go: Refactor SummarizedCallable.
Equivalent of https://github.com/github/codeql/pull/9210
2022-11-17 14:27:03 +00:00
Owen Mansel-Chan
c768f04e32 Go: Introduce generated flag as a part of the kind column for flow summaries
Equivalent of https://github.com/github/codeql/pull/8628
2022-11-17 14:27:03 +00:00
Owen Mansel-Chan
dae60c9deb Update data flow libraries to 55e052af26 2022-11-17 14:27:02 +00:00
Chris Smowton
254a5b0928 Merge pull request #11293 from smowton/smowton/admin/exclude-kotlin-metadata-annotation
Java: Remove no-longer-needed expected diagnostics
2022-11-17 11:50:21 +00:00
Tom Hvitved
bbcef98e06 Merge pull request #11317 from hvitved/cpp/update-autobuilder-nuget-packages
C++: Update auto-builder nuget packages
2022-11-17 12:38:26 +01:00
Tamás Vajk
d8b5a04f97 Merge pull request #11291 from tamasvajk/kotlin-confusing-overload
Kotlin: Add test case for confusing overloading query
2022-11-17 11:11:33 +01:00
Tamás Vajk
c92989ca04 Merge pull request #11289 from tamasvajk/kotlin-empty-block
Kotlin: Exclude .kt files from empty block query
2022-11-17 11:11:25 +01:00
Chris Smowton
659f86cecf Merge pull request #11310 from tamasvajk/kotlin-dead-code
Kotlin: Exclude .kt files from dead code queries
2022-11-17 10:10:51 +00:00