From ca0ab50c5efeabcb835e5b3862b9e35ea6596d79 Mon Sep 17 00:00:00 2001 From: dgtlmoon Date: Mon, 4 Oct 2021 08:34:10 +0200 Subject: [PATCH] Re #239 - Individual GUID for watch+changeevent (#241) * Re #239 - Individual GUID for watch+changeevent --- changedetectionio/__init__.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/changedetectionio/__init__.py b/changedetectionio/__init__.py index 8c0be58a..0faf874d 100644 --- a/changedetectionio/__init__.py +++ b/changedetectionio/__init__.py @@ -270,11 +270,14 @@ def changedetection_app(config=None, datastore_o=None): for watch in sorted_watches: if not watch['viewed']: + # Re #239 - GUID needs to be individual for each event + # @todo In the future make this a configurable link back (see work on BASE_URL https://github.com/dgtlmoon/changedetection.io/pull/228) + guid = "{}/{}".format(watch['uuid'], watch['last_changed']) fe = fg.add_entry() fe.title(watch['url']) fe.link(href=watch['url']) fe.description(watch['url']) - fe.guid(watch['uuid'], permalink=False) + fe.guid(guid, permalink=False) dt = datetime.datetime.fromtimestamp(int(watch['newest_history_key'])) dt = dt.replace(tzinfo=pytz.UTC) fe.pubDate(dt)