GNOME Bugzilla – Bug 632112
Banshee adds duplicate entries to the library when importing
Last modified: 2010-10-14 02:52:29 UTC
For me, using Media→Import Media… and selecting “Folders” will cause Banshee to add large quantities of duplicate tracks to the media library: sqlite> select count(uri) from CoreTracks; 15653 sqlite> select count(distinct uri) from CoreTracks; 13784 (number of dupes continues to grow if I re-import repeatedly.) I removed the dupes manually and added a unique index to the uri field. Now I get the output like at http://pastebin.com/yEKhX9K4 for each file that it tries to import.
Looking at the output I see that the query for an already existing track URL-encodes the comma. However, the insert does not. This of course means that it will continue to try to insert the track with a comma over and over and over. Obviously the solution is to normalize the uri format… Also, it would probably be a good idea to add a unique constraint on the uri field to prevent similar problems.
Thanks for the report. This sounds a lot like Bug 623441, so I'm closing it as a duplicate. Feel free to reopen if I'm wrong. *** This bug has been marked as a duplicate of bug 623441 ***