twisted / treq

Python requests like API built on top of Twisted's HTTP client.
Other
587 stars 139 forks source link

Eliminate dependency on requests #325

Open graingert opened 3 years ago

graingert commented 3 years ago

The treq dependency on requests seems to be causing issues for Klein and other packages that depend on idna

https://twistedmatrix.com/pipermail/twisted-python/2021-February/065444.html

wsanchez commented 3 years ago

Here is the error, in case the above expires:

ERROR: Cannot install hyperlink==21.0.0, idna==3.1 and treq because these package versions have conflicting dependencies.

The conflict is caused by:
    The user requested idna==3.1
    hyperlink 21.0.0 depends on idna>=2.5
    requests 2.25.1 depends on idna<3 and >=2.5
…
glyph commented 2 months ago

Sadly #266 has made the situation a little bit worse, as it uses requests.utils.parse_dict_header but that seems like a pretty light level of string-mashing logic (which maybe should be in Twisted? I'm a little surprised we don't have any use for this in any of Twisted's own HTTP code)