-
Notifications
You must be signed in to change notification settings - Fork 35
Responses with no content cause timeout error and crash #210
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I have submitted a PR that resolves this for the I think it may still stall and timeout in the event of a |
@FoamyGuy - Thanks for looking at this. Someone over on the Adafruit forums suggested I work-around the problem like this:
That workaround does prevent the timeout error. Hopefully, this, plus your fixes, will help anyone in the future who runs into the problem and finds this issue. |
This is resolved by #213. However note that the reproducer code here calls |
I'm using CircuitPython v 9.2.6 on an Adafruit M4 Express Airlift Lite. The Adafruit_Requests module version 4.0.0 crashes with 116: ETIMEOUT when it receives a response with no content (or alternatively, when it receives a response with HTTP response code 204 - no content).
To reproduce, run the following code, adapted from the ESP32SPI example found here.
Note how when we get a 200 response, things are fine, but when we get the 204 (with a no content response) we generate a timeout error. I'd expect adafruit_response to handle no content responses rather than timeout.
The text was updated successfully, but these errors were encountered: