michaelahern / homebridge-airthings

A Homebridge plugin for Airthings air quality monitors via the Airthings Consumer API.
ISC License
38 stars 6 forks source link

Issue with polling data from Airthings API #19

Closed DocIOTUpdate closed 1 year ago

DocIOTUpdate commented 2 years ago

Issue with polling data from Airthings API - this progressively stops working after working 1st time only. I have deleted the API on Airthings Dashboard and recreated it. I then update the plugin JSON file with the config and it works briefly and then it stops again. Values in Homekit are all now zero, or the sensor is ignored/disabled. Please can you fix....

Here is the log:

[7/18/2022, 5:21:36 PM] [Kitchen-Airthings] Request failed with status code 429 [7/18/2022, 5:21:36 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:21:36 PM] [Lounge-Airthings] Request failed with status code 429 [7/18/2022, 5:21:36 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:21:36 PM] [Guest-Airthings] Request failed with status code 429 [7/18/2022, 5:21:36 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:21:36 PM] [Hall-Airthings] Request failed with status code 429 [7/18/2022, 5:21:36 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:21:36 PM] [Gym-Airthings] Request failed with status code 429 [7/18/2022, 5:21:36 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:21:36 PM] [Office-Airthings] Request failed with status code 429 [7/18/2022, 5:21:36 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:21:36 PM] [Master-Airthings] Request failed with status code 429 [7/18/2022, 5:21:36 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:24:06 PM] [Office-Airthings] Request failed with status code 429 [7/18/2022, 5:24:06 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:24:06 PM] [Hall-Airthings] Request failed with status code 429 [7/18/2022, 5:24:06 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:24:06 PM] [Gym-Airthings] Request failed with status code 429 [7/18/2022, 5:24:06 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:24:06 PM] [Guest-Airthings] Request failed with status code 429 [7/18/2022, 5:24:06 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:24:06 PM] [Lounge-Airthings] Request failed with status code 429 [7/18/2022, 5:24:06 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:24:06 PM] [Kitchen-Airthings] Request failed with status code 429 [7/18/2022, 5:24:06 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info. [7/18/2022, 5:24:06 PM] [Master-Airthings] Request failed with status code 429 [7/18/2022, 5:24:06 PM] [homebridge-airthings] This plugin generated a warning from the characteristic 'Current Temperature': characteristic was supplied illegal value: null! Home App will reject null for Apple defined characteristics. See https://homebridge.io/w/JtMGR for more info.

ninjas28 commented 2 years ago

It looks like you have seven Airthings devices you're trying to request data from. Currently the Airthings API query limit is 100 requests per hour and each device uses one request, so the default query interval of 2.5 minutes is too frequent for seven devices. Try changing the refreshInterval to 260 in the config and wait for the query limit to reset and see if it can go for more than an hour without getting this error.