Open brentru opened 4 years ago
Not sure if this library is still maintained, but this is a core breaking bug that has been open for at least a year. Is there any plan to tackle it or will someone try and fork the library?
Can confirm. I am experiencing the same bug.
>>> aio.receive("myfeed") Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/local/lib/python3.7/dist-packages/adafruit_io-2.5.0-py3.7.egg/Adafruit_IO/client.py", line 216, in receive File "/usr/local/lib/python3.7/dist-packages/adafruit_io-2.5.0-py3.7.egg/Adafruit_IO/client.py", line 118, in _get File "/usr/local/lib/python3.7/dist-packages/adafruit_io-2.5.0-py3.7.egg/Adafruit_IO/client.py", line 108, in _handle_error Adafruit_IO.errors.RequestError: Adafruit IO request failed: 404 Not Found - not found - API documentation can be found at https://io.adafruit.com/api/docs
the same issue.
Calling
client.receive
on a newly created feed with no data points raises a 404 if no data exists on the feed.Update the library to not error on that call with a 404, and instead return a
None
value or a Data type which sets thevalue
asNone
:Example code
Output