Comment 7 for bug 624220

Revision history for this message
Eric Casteleijn (thisfred) wrote : Re: [Bug 624220] Re: searching for tracks freezes player

On 10/13/2010 04:59 PM, Florian Demmer wrote:
> thanks for your continued work on this and autoqueue in general. it
> really finds the right kind of music almost always!
>
> however... still not perfect :(
>
> consider this log output, starting with directly after track change:
>
> libmirageaudio: decoding /.../02 - Meredith Brooks - Bitch.mp3
> libmirageaudio: EOS Message received
> libmirageaudio: EOS Message sent
> libmirageaudio: time = 980.000000
> libmirageaudio: frames=2583 (maxhops=2583), size=513
> Mirage: decoded frames=c_int(2583),size=c_int(513)
> Mirage: mfcc Execution Time: 0:00:00.031188
> Mirage: scms created in: 0:00:01.531043
> [autoqueue] Getting similar tracks from last.fm for: gladys knight& the pips - i've got to use my imagination<<--- stuck here for 3 sec
> [autoqueue] looking for: 000100 the supremes - stoned love
> [autoqueue] looking for: 000061 wilson pickett - land of 1000 dances
> [autoqueue] looking for: 000053 the four tops - i can't help myself (sugar pie honey bunch)
> [autoqueue] rating: 0.5 last played 11 days ago, suggested play: after 90.0 days
> [autoqueue] looking for: 000036 aretha franklin - respect
> [autoqueue] looking for: 000034 gladys knight& the pips - best thing that ever happened to me
> [autoqueue] looking for: 000032 gladys knight& the pips - storms of troubled times
> [autoqueue] looking for: 000027 the four tops - i can't help myself (sugar pie, honey bunch)
> [autoqueue] looking for: 000026 the 5th dimension - aquarius/let the sunshine in
> [autoqueue] looking for: 000016 aretha franklin - chain of fools
> [autoqueue] looking for: 000016 al green - let's stay together
> [autoqueue] rating: 0.5 last played 14895 days ago, suggested play: after 90.0 days<<--- stuck here for 5 sec
>
> with "<<-- stuck here" i mean this line gets printed, then stuck, before
> the next line appears.

This is where autoqueue talks to last.fm, and the request + response
usually takes a little while to process. I'll see if it involves loops
that I can break out of more often. The good news is that it stores the
results of the request in the database, so the next time this song gets
played, the request to last.fm won't have to be made, and things will be
much faster.

> what is strange about the second one is, that the line gets logged, then
> stuck and nothing is logged when it becomes responsive again. no idea
> what is happening there. i have disabled "keep db clean".

This is where I store all the found relations into the database. I
postpone this until after queueing the newly found song. I'll
investigate if I can break up that work into smaller chunks too, so as
to minimize UI freezes.

--
eric casteleijn
https://code.launchpad.net/~thisfred
Canonical Ltd.