This forum has been archived. All content is frozen. Please use KDE Discuss instead.

duplicates in collection

Tags: None
(comma "," separated)
shngn
Registered Member
Posts
2
Karma
0

duplicates in collection

Sat Jan 06, 2007 7:47 pm
I have duplicates in my collection like other people around here seem to have. I haven't read any solutions in this forum so I did a little investigation of my own. I'm using amarok 1.4.4 although my library was built with 1.4.3 and upgraded. My distro is Kubuntu 6.10.

I'm using mysql which allows me to poke around the db easily and I found what looks like a data problem thats causing my duplicate tracks. I'm hoping by posting this that someone can confirm the problem and I'll be able to create a meaningful bug report.

So I don't really know the meaning of these tables but I assume uniqueid is the canonical list of files, and tags has foreign keys into this and defines your collection. Anyway I have duplicates for tracks in Dave Matthews' Stand Up album, and I found what looks like the problem:

mysql> select count(*) from uniqueid where url like '%American_Baby.mp3';
+----------+
| count(*) |
+----------+
|        1 |
+----------+
1 row in set (0.05 sec)

Ok, that looks good, but doesn't this seem to be a problem?

mysql> select url from tags where url like '%American_Baby.mp3';
+------------------------------------------------------------------+
| url                                                              |
+------------------------------------------------------------------+
| ./mnt/raidical/music/library/Dave_Matthews_Band/American_Baby.mp3 |
| ./music/library/Dave_Matthews_Band/American_Baby.mp3            |
+------------------------------------------------------------------+
2 rows in set (0.07 sec)

Shouldn't there only be one entry? These are both relative paths but they somehow resolve to the same file. I don't have two copies of this file, I promise.

To further confirm that this is the problem, I loaded up my whole collection into a playlist and got 22,816 tracks. I removed duplicates and reduced the track count by 10,387.

If I count the number of tag entries starting with './music' I get this:

mysql> select count(*) from tags where url like './music/%';
+----------+
| count(*) |
+----------+
|    10386 |
+----------+
1 row in set (0.03 sec)

Ok, so its off by one but still pretty convincing I think.

Andy
User avatar
dangle_wtf
Moderator
Posts
1252
Karma
0

Re: duplicates in collection

Sat Jan 06, 2007 8:54 pm
Out of interest, is your music volume actually mounted twice? Or, is it a network drive?

There have been glitches here and there along the upgrade route while dynamic collections and Amarok File Tracking (AFT) are being stabilised, which have occasionally caused dupes where mount points have changed, but amarok doesn't recognise the music as being the same, and it's possible this is what you're experiencing.

For me, the easiest way to fix this was to drop my mysql db and recreate it. You might be more mysql-savvy. :)


"There are two theories to arguing with women. Neither one works."
.
If men could get pregnant, we'd learn the true meaning of "screaming nancyboy wuss"
shngn
Registered Member
Posts
2
Karma
0

Re: duplicates in collection

Sat Jan 06, 2007 9:10 pm
dangle_wtf wrote:Out of interest, is your music volume actually mounted twice? Or, is it a network drive?


No, its only mounted once. Its a remote nfs mount.

There have been glitches here and there along the upgrade route while dynamic collections and Amarok File Tracking (AFT) are being stabilised, which have occasionally caused dupes where mount points have changed, but amarok doesn't recognise the music as being the same, and it's possible this is what you're experiencing.

For me, the easiest way to fix this was to drop my mysql db and recreate it. You might be more mysql-savvy. :)


I fixed my problem by deleting all the rows in tags starting with the weird ./music path. I don't want to drop my collection and recreate it because I've spent a ridiculous amount of labor rating my music :) Amarok works and scanning for changes doesn't readd them so I guess I'm good. Do you think this is worth a bug report?

Andy
User avatar
dangle_wtf
Moderator
Posts
1252
Karma
0

Re: duplicates in collection

Sat Jan 06, 2007 9:23 pm
It could be, but check first that it's not already reported/fixed in svn. Amarok development is quite fast, so often we find bugs after they've fixed them ;)


"There are two theories to arguing with women. Neither one works."
.
If men could get pregnant, we'd learn the true meaning of "screaming nancyboy wuss"


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], kde-naveen, Sogou [Bot], Yahoo [Bot]