adafruit / Adafruit_CircuitPython_Requests

Requests-like interface for web interfacing
MIT License
51 stars 36 forks source link

Fix chunked request detection #65

Closed tannewt closed 3 years ago

tannewt commented 3 years ago

The response to http://site.api.espn.com/apis/site/v2/sports/basketball/mens-college-basketball/scoreboard has an extra space between Transfer-Encoding: and chunked so the comparison fails.

Fixes #64

tannewt commented 3 years ago

@jedgarpark This should fix your demo. You can try this version of adafruit_requests.py to see.

jedgarpark commented 3 years ago

It works! Thanks @tannewt

tannewt commented 3 years ago

Other than the 2 spaces in Transfer-Encoding: chunked, which is more of a nitpick since it's just a test, it looks good to me. I didn't test.

I'm not sure what you mean by this. The test is exactly for the 2 spaces. That's what the ESPN server is giving us and is being fixed.

makermelissa commented 3 years ago

Oh, then no worries. :)

makermelissa commented 3 years ago

Also, I was helping John and have tested now.