Bug 3282

Summary: duplicated feed items
Product: Claws Mail (GTK 2) Reporter: Michael Schwendt <mschwendt>
Component: Plugins/RSSylAssignee: users
Status: RESOLVED FIXED    
Severity: normal    
Priority: P3    
Version: 3.10.1   
Hardware: PC   
OS: Linux   
Attachments:
Description Flags
the saved post in the .claws-mail/RSSyl folder none

Description Michael Schwendt 2014-09-12 14:05:06 UTC
Created attachment 1430 [details]
the saved post in the .claws-mail/RSSyl folder

https://bugzilla.redhat.com/1139749

feed.c rssyl_feed_item_exists(…) returns EXISTS_NEW for an item that has been seen and saved before. It skips the rssyl_feed_item_changed(…) call. As a result, for such feed posts a new unread one is added everytime the feed is refreshed/updated.
Comment 1 Michael Schwendt 2014-09-13 23:15:31 UTC
Examined this further..

rssyl_cb_feed_compare() doesn't recognize the post as seen before, because somewhere a different "id" string is generated for it:

  The compare function searches for this id (a):
    http://blog-ciah.rhcloud.com/

  Claws Mail saved this id (b):
    http://blog-ciah.rhcloud.com/<540F2280.9050400@redhat.com>

rssyl_parse_folder_item_file() strips off from the Message-ID, and Claws Mail debug tells:

  RSSyl: got id 'http://blog-ciah.rhcloud.com/'
Comment 2 users 2014-09-14 05:26:03 UTC
Changes related to this bug have been committed.
Please check latest Git and update the bug accordingly.
You can also get the patch from:
http://git.claws-mail.org/

++ ChangeLog	2014-09-14 05:26:02.857653310 +0200
http://git.claws-mail.org/?p=claws.git;a=commitdiff;h=d6c7e33acfd3dc56f46813a911cbdc2907684c95
Merge: d10e4ac 9e4d6e4
Author: Colin Leroy <colin@colino.net>
Date:   Sun Sep 14 05:26:02 2014 +0200

    Merge branch 'master' of file:///home/git/claws

http://git.claws-mail.org/?p=claws.git;a=commitdiff;h=9e4d6e44b4b9324109d5d1aa045a94332109cc96
Author: Andrej Kacian <ticho@claws-mail.org>
Date:   Sun Sep 14 05:24:07 2014 +0200

    RSSyl: Do not use g_strsplit_set() to get the ID from message file, since the ID itself can contain < or > characters. Should fix bug #3282.
Comment 3 Andrej Kacian 2014-09-14 05:32:35 UTC
The real issue seems to be that the guids in this feed contain < and >, which exposes our naive handling of stored guids. I have pushed a fix to git which fixes this.
Thanks for the report!
Comment 4 Michael Schwendt 2014-09-14 10:56:30 UTC
> The real issue seems to be that the guids in this feed contain < and >, 

Yep, that's what the bottom of comment 1 suggest. ;-)
Comment 5 Andrej Kacian 2014-09-14 11:03:26 UTC
(In reply to comment #4)
> > The real issue seems to be that the guids in this feed contain < and >, 
> 
> Yep, that's what the bottom of comment 1 suggest. ;-)

Oh, you're right, sorry. In my defense, it was 5am! :)