ims-custom-component icon indicating copy to clipboard operation
ims-custom-component copied to clipboard

Forecast not updating

Open robic77 opened this issue 9 months ago • 5 comments

Often the sensors show forecasts for past hours/days. So sensor for today will show yesterday's date and temperature. Reloading the integration doesn't help.

robic77 avatar Apr 25 '24 19:04 robic77

Check logs for exceptions or errors please

GuyKh avatar Apr 26 '24 10:04 GuyKh

No errors in logs. Restarting HA updates the forecast but no further update afterwards.

robic77 avatar Apr 27 '24 20:04 robic77

There's a periodic update that runs in the background. It's either failing to update or the data in IMS is stale. in order to understand this, I need DEBUG logs

GuyKh avatar Apr 28 '24 05:04 GuyKh

Here are reproduce instructions that make the integration stop updating. tl;dr, use "Reload" integration to cause the issue. Restart HA to make it work again.

Full instructions: Open: http://ha:8123/config/integrations/integration/ims Click 3-dot menu Click "Reload" Data fetching stops.

Relevant log where reload was done at 18:52:15:

	Line 2793: 2024-07-14 13:44:27.447 INFO (MainThread) [custom_components.ims.sensor] Location: Ashdod, entity: ims_city
	Line 2928: 2024-07-14 14:44:35.949 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Data fetched from IMS of 07/14/2024, 14:00:00
	Line 2929: 2024-07-14 14:44:35.950 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Finished fetching ims data in 8.571 seconds (success: True)
	Line 2930: 2024-07-14 14:44:35.950 INFO (MainThread) [custom_components.ims.sensor] Location: Ashdod, entity: ims_city
	Line 3015: 2024-07-14 15:44:38.737 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Data fetched from IMS of 07/14/2024, 15:00:00
	Line 3016: 2024-07-14 15:44:38.737 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Finished fetching ims data in 2.358 seconds (success: True)
	Line 3017: 2024-07-14 15:44:38.738 INFO (MainThread) [custom_components.ims.sensor] Location: Ashdod, entity: ims_city
	Line 3274: 2024-07-14 16:44:50.586 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Data fetched from IMS of 07/14/2024, 16:00:00
	Line 3275: 2024-07-14 16:44:50.586 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Finished fetching ims data in 12.207 seconds (success: True)
	Line 3276: 2024-07-14 16:44:50.587 INFO (MainThread) [custom_components.ims.sensor] Location: Ashdod, entity: ims_city
	Line 3454: 2024-07-14 17:44:58.467 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Data fetched from IMS of 07/14/2024, 17:00:00
	Line 3455: 2024-07-14 17:44:58.467 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Finished fetching ims data in 8.088 seconds (success: True)
	Line 3456: 2024-07-14 17:44:58.468 INFO (MainThread) [custom_components.ims.sensor] Location: Ashdod, entity: ims_city
	Line 3693: 2024-07-14 18:45:00.691 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Data fetched from IMS of 07/14/2024, 18:00:00
	Line 3694: 2024-07-14 18:45:00.692 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Finished fetching ims data in 2.312 seconds (success: True)
	Line 3695: 2024-07-14 18:45:00.692 INFO (MainThread) [custom_components.ims.sensor] Location: Ashdod, entity: ims_city
	Line 3813: 2024-07-14 18:52:15.572 INFO (MainThread) [custom_components.ims] Unloading IMS Weather
	Line 3814: 2024-07-14 18:52:15.572 INFO (MainThread) [custom_components.ims] An existing IMS weather coordinator already exists for this location. Using that one instead
	Line 3815: 2024-07-14 18:52:15.572 INFO (MainThread) [homeassistant.components.sensor] Setting up ims.sensor
	Line 3816: 2024-07-14 18:52:15.573 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3817: 2024-07-14 18:52:15.573 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3818: 2024-07-14 18:52:15.573 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3819: 2024-07-14 18:52:15.574 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3820: 2024-07-14 18:52:15.574 INFO (MainThread) [custom_components.ims.sensor] Location: Ashdod, entity: ims_city
	Line 3821: 2024-07-14 18:52:15.574 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3822: 2024-07-14 18:52:15.575 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3823: 2024-07-14 18:52:15.575 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3824: 2024-07-14 18:52:15.575 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3825: 2024-07-14 18:52:15.575 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3826: 2024-07-14 18:52:15.576 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3827: 2024-07-14 18:52:15.576 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3828: 2024-07-14 18:52:15.576 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3829: 2024-07-14 18:52:15.576 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3830: 2024-07-14 18:52:15.577 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3831: 2024-07-14 18:52:15.577 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3832: 2024-07-14 18:52:15.577 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3833: 2024-07-14 18:52:15.578 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3834: 2024-07-14 18:52:15.578 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3835: 2024-07-14 18:52:15.578 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3836: 2024-07-14 18:52:15.578 DEBUG (MainThread) [custom_components.ims.weather_update_coordinator] Debouncer call ignored as shutdown has been requested.
	Line 3837: 2024-07-14 18:52:15.579 INFO (MainThread) [homeassistant.components.weather] Setting up ims.weather

then no log entries for many hours.

I suspect this is also caused by changing the value "Minutes to wait between updates". I didn't check explicitly. Hope it helps.

ayavilevich avatar Jul 15 '24 07:07 ayavilevich

I'll check. Thanks :)

GuyKh avatar Jul 15 '24 10:07 GuyKh