mirror of
https://github.com/github/codeql.git
synced 2026-04-21 06:55:31 +02:00
Python: Add Requests response model
This required making some of the relevant bits public, but they are marked as internal anyway.
This commit is contained in:
committed by
Rasmus Wriedt Larsen
parent
cb1efa915e
commit
1d4b4ee740
@@ -13,6 +13,7 @@ private import semmle.python.frameworks.FastApi
|
||||
private import semmle.python.frameworks.Django
|
||||
private import semmle.python.frameworks.Tornado
|
||||
private import semmle.python.frameworks.Stdlib
|
||||
private import semmle.python.frameworks.Requests
|
||||
import semmle.python.frameworks.data.internal.ApiGraphModelsExtensions as Extensions
|
||||
|
||||
class FlaskViewClasses extends FindSubclassesSpec {
|
||||
@@ -214,6 +215,12 @@ class FlaskResponse extends FindSubclassesSpec {
|
||||
override API::Node getAlreadyModeledClass() { result = Flask::Response::classRef() }
|
||||
}
|
||||
|
||||
class RequestsResponse extends FindSubclassesSpec {
|
||||
RequestsResponse() { this = "requests.models.Response~Subclass" }
|
||||
|
||||
override API::Node getAlreadyModeledClass() { result = Requests::Response::classRef() }
|
||||
}
|
||||
|
||||
bindingset[fullyQualified]
|
||||
predicate fullyQualifiedToYamlFormat(string fullyQualified, string type2, string path) {
|
||||
exists(int firstDot | firstDot = fullyQualified.indexOf(".", 0, 0) |
|
||||
|
||||
Reference in New Issue
Block a user