From 3c1c9d954413e4ec02ea1241a51018c8f6597064 Mon Sep 17 00:00:00 2001 From: Juni <103315958+Juniteevee@users.noreply.github.com> Date: Fri, 9 Dec 2022 12:29:13 -0500 Subject: [PATCH] Fix for double posting issues This if statement is such that if there is no title in this feed it meets the criteria for this If and the one above and thus gets placed in the queue twice and double posted. Ive seen this in Mastodon feeds for example. if (last_title == "" and entry_title == "") and (last_link != entry_link) and (last_time < entry_time): log.debug(f"New entry found via time validation for feed {name} on cid {channel.id} - no title") feedparser_plus_obj = await self._add_to_feedparser_object(entry, url) feedparser_plus_objects.append(feedparser_plus_obj) --- rss/rss.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/rss/rss.py b/rss/rss.py index 58b0a60..b39c07a 100644 --- a/rss/rss.py +++ b/rss/rss.py @@ -1405,10 +1405,6 @@ class RSS(commands.Cog): log.debug(f"New entry found via time and link validation for feed {name} on cid {channel.id}") feedparser_plus_obj = await self._add_to_feedparser_object(entry, url) feedparser_plus_objects.append(feedparser_plus_obj) - if (last_title == "" and entry_title == "") and (last_link != entry_link) and (last_time < entry_time): - log.debug(f"New entry found via time validation for feed {name} on cid {channel.id} - no title") - feedparser_plus_obj = await self._add_to_feedparser_object(entry, url) - feedparser_plus_objects.append(feedparser_plus_obj) # this is a post that has no time information attached to it and we can only # verify that the title and link did not match the previously posted entry