Music scopes for Oneiric or Precise

Allison Randal allison at ubuntu.com
Mon Apr 2 18:21:58 UTC 2012


Hi Mark,

Sorry, I haven't been able to figure out what's causing the Guayadeque
scope to fail.

Do you want me to temporarily drop it from the set, so we can go ahead
and publish the other 3 music scopes? We can always add a new scope
later and re-release the package, once you get Guayadeque working.

Allison

On 03/30/2012 09:39 PM, Allison Randal wrote:
> Great, I've merged that change and it fixes gmusicbrowser.
> 
> Guayadeque is still not showing any results in the Music Lens. It keeps
> crashing: every time I open the dash, /var/log/syslog gets a new message
> about unity-scope-guayadeque trying to launch apport. I've attached a
> patch with the fixes I've made so far. It gets further with these fixes,
> but still crashes.
> 
> I'll look at it again tomorrow.
> 
> Allison
> 
> On 03/26/2012 05:31 PM, Mark Tully wrote:
>> I've pushed a branch to
>> lp:~markjtully/ubuntu-app-review-board/unity-scopes-music-extras-oneiric
>> <https://code.launchpad.net/%7Emarkjtully/ubuntu-app-review-board/unity-scopes-music-extras-oneiric>
>> with what I hope are fixes to the gmusicbrowser problems.  The scope now
>> checks if it has found an integer for the track year, and if not,
>> assigns 0 as the year.  I've also managed to get the scope to open
>> gmusicbrowser, but, to be honest, I'm not exactly sure how my changes
>> have managed to fix it. 
>>
>> Hopefully this fixes all the showstopping bugs with these scopes.
>>
>> Mark
>>
>> On Fri, Mar 23, 2012 at 6:31 AM, Allison Randal <allison at lohutok.net
>> <mailto:allison at lohutok.net>> wrote:
>>
>>     On 03/21/2012 12:50 PM, Mark Tully wrote:
>>     > I think there's a problem with the apparmor profile preventing the
>>     > scopes from accessing the databases of the music players,
>>     preventing any
>>     > results from being returned. There is a 'Permission Denied' error
>>     > regarding accessing the database file when the scope is run from the
>>     > command line.
>>     >
>>     > The databases are located at the following locations:
>>     > Rhythmbox: ~/.local/share/rhythmbox/rhythmdb.xml
>>     > Clementine: ~/.config/Clementine/clementine.db
>>     > Guayadeque: ~/.guayadeque/guayadeque.db
>>     > GMusicBrowser: ~/.config/gmusicbrowser/gmbrc
>>     >
>>     > These probably need to be added to the apparmor profile file of the
>>     > relevant scope, but I'm uncertain how to add files from a specific
>>     > account's home folder to the profile in order to fix this. The
>>     apparmor
>>     > profile is not present in my own PPA version, so this problem does not
>>     > occur with it.
>>
>>     Here's what it took to allow the Clementine scope to run, the others had
>>     similar needs:
>>
>>      # Allow the daemon to access the music data
>>      @{HOME}/.config/Clementine/clementine.db r,
>>      @{HOME}/.config/Clementine/clementine-scope-backup.db rwk,
>>
>>      # Allow the daemon to launch the music player
>>      /usr/bin/clementine Ux,
>>
>>     > Regarding the clementine issue, there is a bug in the activation code
>>     > stopping the lens from passing the actual song uri to Clementine.
>>      Line
>>     > 203 in unity-scope-clementine should read :
>>     >
>>     > if uri.startswith("album://"):
>>     >
>>     > rather than:
>>     >
>>     > if not uri.startswith("album://") == -1:
>>     >
>>     > Since this is a one line fix, I figure it is easier for you to
>>     change it
>>     > in your repository rather than me submitting it and then you importing
>>     > it to your own branch.
>>
>>     Great! I've applied this patch and can confirm that the Clementine scope
>>     now adds the song to the current playlist and starts playing it.
>>
>>
>>     I encountered a fatal error in the GMusicBrowser and Guayadeque daemons,
>>     which seems to be related to changing APIs:
>>
>>     Traceback (most recent call last):
>>      File "./unity-scope-gmusicbrowser", line 282, in <module>
>>        daemon = Daemon()
>>      File "./unity-scope-gmusicbrowser", line 36, in __init__
>>        self.scope.connect ("search-changed",  self.on_search_changed)
>>     TypeError: <Scope object at 0x26298c0 (UnityScope at 0x268a160)>:
>>     unknown signal name: search-changed
>>
>>     I fixed it by replacing the line:
>>
>>        self.scope.connect ("search-changed",  self.on_search_changed)
>>
>>     With these two lines from the Clementine scope:
>>
>>        self.scope.connect ("notify::active-search", self.on_search_changed)
>>        self.scope.connect ("notify::active-global-search",
>>                self.on_global_search_changed)
>>
>>
>>     I also encountered another fatal error in the Guayadeque daemon that I
>>     haven't had time to dig into yet (you may find the solution before I get
>>     back to it on Monday):
>>
>>     Traceback (most recent call last):
>>      File "./unity-scope-guayadeque", line 95, in on_search_changed
>>        self.update_results_model (search, results)
>>      File "./unity-scope-guayadeque", line 151, in update_results_model
>>        if int(track[7]) >= firstdecadefilter and int(track[7]) <=
>>     lastdecadefilter:
>>     ValueError: invalid literal for int() with base 10:
>>     '/home/allison/Music/Music for Deep Relaxation/Classical Indian Music
>>     for Healing and Meditation With Santoor Master Sunil Katti and Veena
>>     Virtuosa Gayatri Govindarajan/cover.jpg'
>>
>>     The GMusicBrowser scope is now showing results in the Music Lens, but
>>     clicking a song doesn't launch the gmusicbrowser player. (The player
>>     launches fine from an app search in the Dash or from the command-line.)
>>     But, I don't get any errors when launching the daemon manually, or in
>>     /var/log/syslog or /var/log/dmesg.
>>
>>
>>     The Clementine and Rhythmbox scopes are working fine now.
>>
>>     I've pushed all my changes to the bzr branch, so you can take a look:
>>
>>     https://code.launchpad.net/~app-review-board/ubuntu-app-review-board/unity-scopes-music-extras-oneiric
>>     <https://code.launchpad.net/%7Eapp-review-board/ubuntu-app-review-board/unity-scopes-music-extras-oneiric>
>>
>>     Allison
>>
>>



More information about the App-review-board mailing list