Linux returns response with expected 302, Windows raises an error #3407
Unanswered
JustRedTTG
asked this question in
Potential Issue
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have an client connecting to some API.
This API handles small streams of chunked content upload just fine, however if it sees the content-length is larger than it can handle it starts to make a google signed url to upload to, once it's done it cancels receiving and returns a response with 302.
The file may have streamed partially (inside the official app using the API same thing occurs, normal behavior)
The issue arises only on windows (not tested on mac)
On windows the expected behavior of getting a 302 for larger files fails, instead httpx raises one of:
httpx.ReadError: [WinError 10053] An established connection was aborted by the software in your host machine
httpcore.WriteError
or similar but it doesn't reproduce every the time.The issue happens on both http1 and http2 with no apparent differences
I cannot provide the API to reproduce but I am sure you could make a basic endpoint that receives let's say 20MB on it's own and returns
response 200
and if it is bigger (200MB) it waits a sec (simulating request to google for signed url) and returnsresponse 302
, you should be able to reproduce the error on the client code with windows and on linux properly receive theresponse 302
here is the client code stripped down a bit:
Beta Was this translation helpful? Give feedback.
All reactions