File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -160,7 +160,8 @@ def wrapped(
160160 # req_kwargs is added dynamically by the responses
161161 # library onto PreparedRequest objects - it is not
162162 # in the requests type stubs.
163- req_kwargs : dict [str , Any ] = request .__dict__ .get (
163+ req_kwargs : dict [str , Any ] = getattr ( # pylint: disable=bad-builtin
164+ request ,
164165 "req_kwargs" ,
165166 {},
166167 )
@@ -224,7 +225,7 @@ def __enter__(self) -> Self:
224225 compiled_url_pattern = re .compile (pattern = url_pattern )
225226
226227 for http_method in route .http_methods :
227- original_callback = object . __getattribute__ (
228+ original_callback = getattr ( # pylint: disable=bad-builtin
228229 api ,
229230 route .route_name ,
230231 )
Original file line number Diff line number Diff line change @@ -161,7 +161,7 @@ def start_respx_router(
161161 compiled_url_pattern = re .compile (pattern = url_pattern )
162162
163163 for http_method in route .http_methods :
164- original_callback = object . __getattribute__ (
164+ original_callback = getattr ( # pylint: disable=bad-builtin
165165 api ,
166166 route .route_name ,
167167 )
You can’t perform that action at this time.
0 commit comments