Hi,
I have some strange beahviour for the RSS widget not updating its content. Other widgets are updating as expected. I have tried “everything”, like Chrome cache, deleting the subdirectory compiled. The only thing that did update the RSS components was restarting the appdaemon daemon itself and then refreshing the dashboard.
I found no clue in the java console, log or err files whats so ever.
So I thought that I start from the beginning, and see if anyone can give my a hint on where to start searching.
This is my setup:
Hadashboard running on a rpi3.
I have tried with chrome on Rpi and Windows. IE on windows. Tried with different windows clients one that has never viewed the hadashboard before ie definitely no client cache involved.
“Empty Cache and Hard Reload” didn’t have any effect. Not until I restarted the daemon then the updated news showed up. I think I have ruled out the local web browser cache as the culprit.
No errors in appdaemon.err or in the java console. No unusual debug msg in appdaemon.log either.
It’s like the rss_update interval is ignored, what could cause that? Network errors?
could be.
maybe the pi has some AD parts cashed as well.
did you also try a complete restart?
i have never used the RSS so i cant debug wth you.
like i said, you could try to set it to a higher interval (in the hope that is what is causing the problem)
maybe that @aimc has a clue why this isnt working.
@asyncio.coroutine
def update_rss():
# Grab RSS Feeds
if conf.rss_feeds is not None and conf.rss_update is not None:
while not conf.stopping:
if conf.rss_last_update == None or (conf.rss_last_update + conf.rss_update) <= time.time():
conf.rss_last_update = time.time()
for feed_data in conf.rss_feeds:
feed = yield from utils.run_in_executor(conf.loop, conf.executor, feedparser.parse, feed_data["feed"])
new_state = {"feed": feed}
with conf.ha_state_lock:
conf.ha_state[feed_data["target"]] = new_state
data = {"event_type": "state_changed",
"data": {"entity_id": feed_data["target"], "new_state": new_state}}
ws_update(data)
yield from asyncio.sleep(1)
yeah i can see a problem there.
i dont know if thats a bug or an oversight or that its recalculated elsewhere, but
conf.rss_last_update is a time and
conf.rss_update is an int
and in line 6 they are added together which normally gives an error.
but then there should be an error somewhere.
off course it could be just my little knowledge from python, but maybe that @aimc can tell more about it.
but he is a bit busy at the moment so you might have to have a little patience.
Thanks,
I actually added some debug statements in rundash.py and as far as I can see update_rss is called at start up, and is run successfully. So the time and int is not causing a problem.
The problem seams to be that there was some kind of problem with the result from my rss feed.
The ws_update(data) call didn’t return.
What kind of problem I can not say, it didn’t generate an error of any kind
Thanks for your support.
i should have thought to ask you to use another feed to check if the problem is there
but at least you now know the problem, and we didnt need @aimc for that