Closed
Description
Describe the bug
As of #8620, the request method's trace_request_ctx parameter is typed as taking a Mapping[str, str]. A value of str seems like an odd restriction to impose and other types are used in the wild. Some examples:
current_attemptis numeric: https://github.com/inyutin/aiohttp_retry/blob/ba2169891f5b32a5c59e48ca185dd8e68e44ded7/aiohttp_retry/client.py#L116urlis most likely ayarl.URL: https://github.com/fsspec/ipfsspec/blob/350c565352c6615aceedbe5e452b06a79855b0d5/ipfsspec/async_ipfs.py#L44timing_event_ctxis a nested dictionary: https://github.com/WordPress/openverse/blob/d4e84652d8936db5a62137e2a032926e203b50a2/api/api/utils/image_proxy/extension.py#L69
To Reproduce
n/a
Expected behavior
That a wider type would be accepted.
Logs/tracebacks
n/aPython Version
$ python --version
3.12.5aiohttp Version
$ python -m pip show aiohttp
3.10.8multidict Version
$ python -m pip show multidict
6.1.0yarl Version
$ python -m pip show yarl
1.13.1OS
macOS
Related component
Client
Additional context
No response
Code of Conduct
- I agree to follow the aio-libs Code of Conduct