Describe the bug
this bit of code
import requests
import responses
def get_something():
return requests.get('http://example.com')
def test_get_something():
with responses.RequestsMock() as rsps:
rsps.add(responses.GET, 'http://example.com', body='foo')
foo = get_something()
assert rsps.calls[0].request.url == 'http://example.com/'
results in a type checking failure in mypy and pyright. The Pyright message is:
Cannot access member "request" for type "List[Call]"
Member "request" is unknown
Additional context
No response
Version of responses
0.22.0
Steps to Reproduce
Example in bug description.
Expected Result
The example code should pass type checking. Members of List[Call] should have their attributes properly annotated.
Actual Result
Cannot access member "request" for type "List[Call]" Member "request" is unknown
Describe the bug
this bit of code
results in a type checking failure in mypy and pyright. The Pyright message is:
Additional context
No response
Version of
responses0.22.0
Steps to Reproduce
Example in bug description.
Expected Result
The example code should pass type checking. Members of List[Call] should have their attributes properly annotated.
Actual Result
Cannot access member "request" for type "List[Call]" Member "request" is unknown