fix: lint
This commit is contained in:
parent
27d5535b54
commit
97f7a29fec
@ -292,8 +292,20 @@ class Executor:
|
|||||||
do http request depending on api bundle
|
do http request depending on api bundle
|
||||||
"""
|
"""
|
||||||
if self.method not in {
|
if self.method not in {
|
||||||
"get", "head", "post", "put", "delete", "patch", "options",
|
"get",
|
||||||
"GET", "POST", "PUT", "PATCH", "DELETE", "HEAD", "OPTIONS",
|
"head",
|
||||||
|
"post",
|
||||||
|
"put",
|
||||||
|
"delete",
|
||||||
|
"patch",
|
||||||
|
"options",
|
||||||
|
"GET",
|
||||||
|
"POST",
|
||||||
|
"PUT",
|
||||||
|
"PATCH",
|
||||||
|
"DELETE",
|
||||||
|
"HEAD",
|
||||||
|
"OPTIONS",
|
||||||
}:
|
}:
|
||||||
raise InvalidHttpMethodError(f"Invalid http method {self.method}")
|
raise InvalidHttpMethodError(f"Invalid http method {self.method}")
|
||||||
|
|
||||||
@ -309,7 +321,7 @@ class Executor:
|
|||||||
"follow_redirects": True,
|
"follow_redirects": True,
|
||||||
"max_retries": self.max_retries,
|
"max_retries": self.max_retries,
|
||||||
}
|
}
|
||||||
|
|
||||||
# Use with statement to ensure proper resource cleanup
|
# Use with statement to ensure proper resource cleanup
|
||||||
with httpx.Client() as client:
|
with httpx.Client() as client:
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user