Taus
2734377e5d
Python: Add API graph support for parameter annotations
...
Adds API graph support for observing that in
```python
def foo(x : Bar): ...
```
The variable `x` is likely to be an instance of the type `Bar` inside
this function.
In particular, we add `getInstanceFromAnnotation` as a predicate on API
graph nodes that tracks this step (corresponding to a new edge type
labeled with "annotation" in the API graph), and extend the existing
`getAnInstance` predicate to also include instances arising from type
annotations.
A more complete solution would also add support for annotated
assignments (`x : Foo = ...` or just `x : Foo`) as well as track types
through type aliases (`type Foo = Bar`). This turns out to be
non-trivial, however, as these type constructs don't have any CFG nodes
(and so no data-flow nodes by default either). In order to not have
perfect be the enemy of good, this commit is only targeting the type
parameter case (which is also likely to be the most common use case
anyway).
The tests for API graphs have been extended accordingly, including tests
for the kinds of type ascriptions that we _don't_ currently model in API
graphs (marked with `MISSING:` in the inline tests).
2024-11-26 13:03:06 +00:00
Alexander Eyers-Taylor
c0474c4e45
Revert "Revert "Post-release preparation for codeql-cli-2.19.4""
2024-11-21 15:37:52 +00:00
Alexander Eyers-Taylor
4effe9e364
Revert "Post-release preparation for codeql-cli-2.19.4"
2024-11-21 14:43:15 +00:00
github-actions[bot]
9783a11565
Release preparation for version 2.19.4
2024-11-19 16:21:37 +00:00
yoff
22287be5d1
Merge pull request #17370 from Kwstubbs/Bottle/Tornado-HeaderSupport
...
Python: Bottle Framework Support
2024-11-19 15:34:26 +01:00
github-actions[bot]
cc7b724123
Release preparation for version 2.19.3
2024-11-04 16:37:28 +00:00
Taus
28f8874243
Merge pull request #17688 from github/tausbn/python-3.13-default-type-parser-support
...
Python: Add support for type parameter defaults
2024-10-15 18:01:51 +02:00
Taus
d4e0cb2ffa
Merge pull request #17767 from github/tausbn/python-3.13-model-flow-in-replace
...
Python: Model `copy.replace`
2024-10-15 18:01:28 +02:00
Taus
3b60d8302b
Python: Add change note
2024-10-15 12:14:20 +00:00
Taus
d905010aa8
Python: Add change note
2024-10-15 11:22:34 +00:00
Arthur Baars
9ba8045837
Fix typos in changelog entries
2024-10-15 11:06:20 +00:00
github-actions[bot]
255f55cf1a
Release preparation for version 2.19.2
2024-10-15 10:29:25 +00:00
Rasmus Lerchedahl Petersen
6bd46148e7
Python: add change note
2024-10-09 16:27:52 +02:00
yoff
1f1b1b7aab
Merge pull request #17653 from yoff/python/typetracking-through-comprehensions
2024-10-08 19:39:21 +02:00
Rasmus Lerchedahl Petersen
a4c1a622b7
Merge branch 'main' of https://github.com/github/codeql into python/add-comprehension-capture-flow
2024-10-04 14:53:03 +02:00
Rasmus Lerchedahl Petersen
6d486f9931
Python: move change note to the right place
2024-10-03 10:15:55 +02:00
Rasmus Lerchedahl Petersen
9e808c17af
Python: add change note
2024-10-03 10:09:59 +02:00
yoff
7816f34d75
Merge branch 'main' into stdlib-optparse
2024-10-01 12:48:09 +02:00
Rasmus Lerchedahl Petersen
64890a1a6b
Python: valid change note
2024-10-01 12:37:45 +02:00
yoff
2eac11edd6
Update python/ql/lib/change-notes/2024-09-24-std-lib-models.md
...
Co-authored-by: Rasmus Wriedt Larsen <rasmuswriedtlarsen@gmail.com >
2024-10-01 11:47:42 +02:00
Rasmus Lerchedahl Petersen
e0a3c8a1c4
Python: add change note
2024-10-01 10:12:39 +02:00
github-actions[bot]
455c8c5953
Release preparation for version 2.19.1
2024-09-30 17:59:48 +00:00
Rasmus Wriedt Larsen
431a1af628
Merge branch 'main' into threat-models
2024-09-26 11:44:24 +02:00
yoff
e7f9b5bbbc
Merge branch 'main' into stdlib-optparse
2024-09-24 20:24:00 +02:00
Rasmus Lerchedahl Petersen
f95926e1a8
Python: add change note
2024-09-24 20:23:39 +02:00
Rasmus Wriedt Larsen
4a21a85e73
Merge branch 'main' into threat-models
2024-09-23 11:19:58 +02:00
Joe Farebrother
7aa2816570
Add changenote
2024-09-20 15:19:54 +01:00
github-actions[bot]
acdafd9646
Release preparation for version 2.19.0
2024-09-16 10:56:10 +00:00
Dave Bartolomeo
485fc04029
Initial merge from main
2024-09-15 08:55:31 -04:00
Rasmus Wriedt Larsen
0ccb5b198a
Python: Add change-note
2024-09-10 14:32:38 +02:00
github-actions[bot]
91537cdf9a
Release preparation for version 2.18.4
2024-09-09 16:08:48 +00:00
Erik Krogh Kristensen
49aaf65f3f
fix mistake in the Python change-note
...
Co-authored-by: Taus <tausbn@github.com >
2024-09-04 12:43:01 +02:00
Kevin Stubbings
bd2564ee44
Formatting
2024-09-03 14:34:25 -07:00
erik-krogh
e2b16bd8f9
add some change-notes
2024-09-03 22:06:07 +02:00
Kevin Stubbings
5c8c99d31f
Add header support for bottle and tornado
2024-08-30 18:16:01 -07:00
github-actions[bot]
17cd9624fb
Release preparation for version 2.18.3
2024-08-21 17:13:52 +00:00
github-actions[bot]
019da8c287
Release preparation for version 2.18.2
2024-08-07 14:02:38 +00:00
Alexander Eyers-Taylor
46577b585e
Revert "Release preparation for version 2.18.2"
2024-08-07 14:24:37 +01:00
github-actions[bot]
c14ba0e4bd
Release preparation for version 2.18.2
2024-08-06 12:46:15 +00:00
yoff
123dcc75d1
Merge pull request #16971 from RasmusWL/mad-dict-source
...
Python: Add MaD support for DictionaryElement/DictionaryElementAny for sources
2024-07-31 13:40:07 +02:00
Chuan-kai Lin
a5fe3f4d9c
Minor changelog improvements
2024-07-22 14:34:56 -07:00
github-actions[bot]
368bcb684a
Release preparation for version 2.18.1
2024-07-22 21:30:50 +00:00
Chuan-kai Lin
23320b6e5e
Revert "Release preparation for version 2.18.1"
2024-07-22 13:22:49 -07:00
Chuan-kai Lin
cda4339056
Minor changelog improvements
2024-07-22 09:42:31 -07:00
github-actions[bot]
55935fc123
Release preparation for version 2.18.1
2024-07-22 14:56:15 +00:00
Rasmus Wriedt Larsen
efcd4e297e
Add change-note
2024-07-12 15:21:51 +02:00
Joe Farebrother
8152ec7472
Merge pull request #16696 from joefarebrother/python-cookie-write-headers
...
Python: Model CookieWrites from HeaderWrites
2024-07-11 14:25:54 +01:00
github-actions[bot]
b0d6778652
Release preparation for version 2.18.0
2024-07-08 09:10:51 +00:00
Arthur Baars
b12b33c8f9
Merge remote-tracking branch 'upstream/main' into 'rc/3.14'
2024-06-28 19:50:35 +02:00
Rasmus Lerchedahl Petersen
da03237b32
Python: fix typo pointed out in review but missed by me
2024-06-27 11:21:28 +02:00