Since a couple days the OWM binding on my OH2.5M4 setup crashes when the OWM service responds with "{msg: Not found}"
. After this exception, the binding no longer reports weather updates.
Here’s the evidence of the openhab.log:
2019-10-31 01:16:51.913 [WARN ] [mmon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception:
java.lang.IllegalStateException: Not a JSON Object: "{msg: Not found}"
at com.google.gson.JsonElement.getAsJsonObject(JsonElement.java:91) ~[?:?]
at org.openhab.binding.openweathermap.internal.connection.OpenWeatherMapConnection.getErrorMessage(OpenWeatherMapConnection.java:331) ~[?:?]
at org.openhab.binding.openweathermap.internal.connection.OpenWeatherMapConnection.getResponse(OpenWeatherMapConnection.java:301) ~[?:?]
at org.openhab.binding.openweathermap.internal.connection.OpenWeatherMapConnection.lambda$1(OpenWeatherMapConnection.java:281) ~[?:?]
at org.eclipse.smarthome.core.cache.ExpiringCache.refreshValue(ExpiringCache.java:97) ~[?:?]
at org.eclipse.smarthome.core.cache.ExpiringCache.getValue(ExpiringCache.java:68) ~[?:?]
at org.eclipse.smarthome.core.cache.ExpiringCacheMap.get(ExpiringCacheMap.java:198) ~[?:?]
at org.eclipse.smarthome.core.cache.ExpiringCacheMap.putIfAbsentAndGet(ExpiringCacheMap.java:127) ~[?:?]
at org.eclipse.smarthome.core.cache.ExpiringCacheMap.putIfAbsentAndGet(ExpiringCacheMap.java:112) ~[?:?]
at org.openhab.binding.openweathermap.internal.connection.OpenWeatherMapConnection.getResponseFromCache(OpenWeatherMapConnection.java:281) ~[?:?]
at org.openhab.binding.openweathermap.internal.connection.OpenWeatherMapConnection.getUVIndexData(OpenWeatherMapConnection.java:182) ~[?:?]
at org.openhab.binding.openweathermap.internal.handler.OpenWeatherMapUVIndexHandler.requestData(OpenWeatherMapUVIndexHandler.java:120) ~[?:?]
at org.openhab.binding.openweathermap.internal.handler.AbstractOpenWeatherMapHandler.updateData(AbstractOpenWeatherMapHandler.java:135) ~[?:?]
at org.openhab.binding.openweathermap.internal.handler.OpenWeatherMapAPIHandler.updateThing(OpenWeatherMapAPIHandler.java:176) ~[?:?]
at org.openhab.binding.openweathermap.internal.handler.OpenWeatherMapAPIHandler.updateThings(OpenWeatherMapAPIHandler.java:167) ~[?:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:?]
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) ~[?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) ~[?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) ~[?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]
at java.lang.Thread.run(Thread.java:748) [?:?]
This never happened until recently.Now I almost get it once daily, typically around 1AM CET.
Bug report opened: https://github.com/openhab/openhab2-addons/issues/6309