You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Consider URLLib3Transport interface, since it's becoming public API. #966
There's a couple of things we could consider in the URLLib3Transport interface, now that it's becoming public API.
We don't really want to pass pool_limits, since it doesn't quite fit the parameters that urllib3 uses to configure it's PoolManager. We needed to pass it before, since we were using the class for our sync implementation, and needed the consistency between our async and sync cases, but now that we're providing it separately we should just mirror their native num_pools and maxsize.
With httpcore we provide different classes for the proxy and the plain-connection-pool transports. We could? choose to do the same with the urllib3 transport, rather than providing a single class with an optional proxy=... argument.
The only reason I'd be in favor of keeping URLLib3Transport is to make it easier for folks that use Requests to migrate over without having to deal with slight behavior differences right away.
I'm actually not certain that's what people would do in practice - there are already lots of behavior differences that come from switching from Requests anyway, so not sure if switching to our transport is a big leap.
Another argument in favor of dropping it before 1.0 lands would be reducing maintenance burden - now that the transport interface is public it would be pretty easy for someone to maintain this as a 3rd party component (esp given that we have a working implementation in 0.12.x for people to take inspiration from). But at the same time, it's not very high cost.
Edit: oh okay, I didn't get that you were talking about the Transport/Dispatch compatibility layer. Sure, let's drop it IMO. I guess what I wrote above^ is another discussion then. 😄
I'm 👍 on dropping URLLib3Transport completely tbh.
I might be missing something but it seems atm it feels like the remnants of our old sync flow rather than a core piece of HTTPX that users would reach for. It already has our lowest test coverage percentage, feels like it will eventually break for someone since it's now in the public API.
Okay, well let's drop the URLLib3Transport/URLLib3ProxyTransport convo from the 0.13 milestone so we can get this thing released, and keep the idea of URLLib3Transport as a third-party-package as an open option.
(Personally I probably think it's a pretty useful thing to have available to us, but I'm not absolute on it.)
Activity
lovelydinosaur commentedon May 21, 2020
Also we could just drop the
URLLib3Dispatchcompat shim, since it's only ever existed in the pre-releases.And in any case, never made it to the public interface even then.
florimondmanca commentedon May 21, 2020
The only reason I'd be in favor of keeping
URLLib3Transportis to make it easier for folks that use Requests to migrate over without having to deal with slight behavior differences right away.I'm actually not certain that's what people would do in practice - there are already lots of behavior differences that come from switching from Requests anyway, so not sure if switching to our transport is a big leap.
Another argument in favor of dropping it before 1.0 lands would be reducing maintenance burden - now that the transport interface is public it would be pretty easy for someone to maintain this as a 3rd party component (esp given that we have a working implementation in 0.12.x for people to take inspiration from). But at the same time, it's not very high cost.
Edit: oh okay, I didn't get that you were talking about the
Transport/Dispatchcompatibility layer. Sure, let's drop it IMO. I guess what I wrote above^ is another discussion then. 😄yeraydiazdiaz commentedon May 21, 2020
I'm 👍 on dropping
URLLib3Transportcompletely tbh.I might be missing something but it seems atm it feels like the remnants of our old sync flow rather than a core piece of HTTPX that users would reach for. It already has our lowest test coverage percentage, feels like it will eventually break for someone since it's now in the public API.
lovelydinosaur commentedon May 21, 2020
Okay, well let's drop the
URLLib3Transport/URLLib3ProxyTransportconvo from the 0.13 milestone so we can get this thing released, and keep the idea ofURLLib3Transportas a third-party-package as an open option.(Personally I probably think it's a pretty useful thing to have available to us, but I'm not absolute on it.)
lovelydinosaur commentedon May 21, 2020
Remaining points for 1.0 consideration...
URLLib3Transport/URLLib3ProxyTransportfor consistency withhttpcoreinterface, andurllib3'sPoolManager/ProxyManager?URLLib3Transportinto a third party package instead?lovelydinosaur commentedon Jul 25, 2020
We can close this off now.
Once #1090 is addressed, the signatures are...
And...