Bugzilla – Bug 9307
Music source switch from SBC doesn't work with Boom
Last modified: 2009-09-08 09:11:36 UTC
Fletch pointed this out, easily reproduced. Try switching music sources from Controller while Boom is the chosen player, doesn't even show the option of other servers.
methinks this is a controller bug. a tricky one at that, as I'm seeing intermittent bad behavior. Sometimes the other sources show up, sometimes they don't.
(In reply to comment #1) > methinks this is a controller bug. a tricky one at that, as I'm seeing > intermittent bad behavior. Sometimes the other sources show up, sometimes they > don't. > FWIW, I have never seen the other sources show up for a Boom. AFAIK, it's always been like that. I mentioned it during Beta, but never filed a bug because I assumed it was a side effect of the Boom being redirected to a different SN.
r2907 has a possible fix for this. I had trouble testing because the problem was intermittent for me, but after making this change I couldn't get it to misbehave any more. I'll call this fixed, with QA to verify. If it's still a problem, reopen and pass back to me.
Is this fix really working for everyone else? I finally got around to upgrading to r2907 and now it's worse. I'm unable to enter the Music Source menu for any player, Boom or SB2. I think there were a few reports on the forums of this as well.
I've got a controller with r2907, which I also factory reset to be doubly sure I was starting with a clean slate. Connected to a Boom, I was able to switch between SN and SC repeatedly without issue. Fletch, if you can reproduce this readily, I'd really appreciate a piece of debug you could pass my way. ssh to the controller and do a tail -f on /var/log/messages (or if you have an SD card in, /mnt/mmc/log/messages). Then try to enter Settings->Music Source. If it fails to load a window, I'm guessing you will see an error posted to the messages file. btw-- nice to meet you last week at the Boom open house. :) I'm going to reopen this even though I can't reproduce...
*** Bug 9427 has been marked as a duplicate of this bug. ***
Created attachment 3989 [details] SBC log Log attached. The sequence of events during this log is that the SBC was initially connected to an SB2. I attempted to navigate to Settings->Music Source. It plays the click sound effect but the Music Source window doesn't open. I then switched the SBC to a different player which is a Boom and tried to navigate to Settings-Music Source. Same result. At the time of the test, the 2 players were synced and playing, but I get the same results when the players are off and/or unsynced. I have not tried doing a factory reset. The only thing unusual about my configuration is that my SBC and players are on different private subnets than SC. It was nice meeting you as well :-)
that is really weird...nothing at all in the log that shows anything useful. just for reference, this is what I see on my console when I enter Settings->Music Source: 145129:16691168 INFO (AppletManager.lua:445) - Loaded: ChooseMusicSource 145129:16691169 INFO (SlimServer.lua:476) - SlimServer {SqueezeNetwork}:connect 145129:16691170 INFO (SlimServer.lua:476) - SlimServer {mediumspicy}:connect 145130:16691323 INFO (NetworkThread.lua:249) - NOTIFY: cometConnected(Comet {mediumspicy}) 145130:16691324 INFO (SlimServer.lua:518) - SlimServer {mediumspicy} connected 145130:16691324 INFO (NetworkThread.lua:249) - NOTIFY: serverConnected(SlimServer {mediumspicy}) 145130:16691324 INFO (SlimDiscoveryApplet.lua:436) - serverConnected 145130:16691412 INFO (NetworkThread.lua:249) - NOTIFY: cometConnected(Comet {SqueezeNetwork}) 145130:16691413 INFO (SlimServer.lua:518) - SlimServer {SqueezeNetwork} connected 145130:16691413 INFO (NetworkThread.lua:249) - NOTIFY: serverConnected(SlimServer {SqueezeNetwork}) 145130:16691413 INFO (SlimDiscoveryApplet.lua:436) - serverConnected 145130:16691475 INFO (SlimServer.lua:201) - SlimServer {SqueezeNetwork}: has no players!
Ben, this is 100% reproducible for me so let me know what else you'd like me to try - I'm happy to help test.
I'll see your "what can I do to help" and I'll raise you a "gimme lots more debug". :) Fletch, can you do the following steps: 1. edit /usr/share/jive/jive/utils/log.lua and find the line that sets the logging state for applets.setup, and set it to DEBUG 2. reboot the controller 3. from a connected player, browse to Settings->Music Source (i.e., reproduce the issue) 4. dump the entire messages file and attach it to the bug as a text/plain attachment much obliged.
Created attachment 4003 [details] log with applets.setup set to DEBUG New log as requested.
thanks a bunch Fletch (this is mostly notes to myself here) the important bits from that log: Sep 16 07:01:13 SqueezeboxController user.info jive: (AppletManager.lua:445) - Loaded: ChooseMusicSource Sep 16 07:01:13 SqueezeboxController user.info jive: (SlimServer.lua:476) - SlimServer {SqueezeNetwork}:connect Sep 16 07:01:13 SqueezeboxController user.debug jive: (ChooseMusicSourceApplet.lua:127) - _addServerItem nil nil so for some reason ChooseMusicSource is finding no servers. the _addServerItem() method in ChooseMusicSource is called from two different spots, the poll list, and the discovered list. It appears the poll list comes back as nil and iterateSqueezeCenters returns nothing to loop through. -- slimservers on the poll list local poll = appletManager:callService("getPollList") for address,_ in pairs(poll) do if address ~= "255.255.255.255" then self:_addServerItem(nil, address) end end -- discovered slimservers for _,server in appletManager:callService("iterateSqueezeCenters") do self:_addServerItem(server) end
(In reply to comment #12) > so for some reason ChooseMusicSource is finding no servers. Note my comment above that my SC is on a different private subnet than either the SBC or my players. Could that be why? This did work fine, however, with the previous firmware other than the Boom-specific issue orginaly reported in this bug.
the fact that it worked before makes me think that the SC on the private subnet isn't the problem, but I'm willing to entertain any hypothesis right now. How difficult would it be to temporarily put your SC on your SBC/Squeezebox subnet to see if it behaves any better?
(In reply to comment #14) > the fact that it worked before makes me think that the SC on the private subnet > isn't the problem, but I'm willing to entertain any hypothesis right now. Yeah, and it should still list SN as a source even if it can't find my SC (which it's already connected to)... > How difficult would it be to temporarily put your SC on your SBC/Squeezebox > subnet to see if it behaves any better? Not easy. Let me think about it, but I can't promise it's something I can do soon.
Yes, quite right--if it can't see SN the problem isn't your SC on a private subnet. This one is a head scratcher...
on the bug that I closed as a dupe of this one, bug 9427, the user reported that moving back to r2873 from r2907 fixed the problem. It's inferred from this bug that there was no issue in r2873 with non-boom players. If you're unsure of that being the case, could you load r2873 and confirm that resolves the issue with non-boom players? rather than use the SD card, I'd force SC to push the firmware to the SBC. In case you haven't done that before, this is done with custom.jive.* files: 1. copy the bin file linked here to your SC cache folder and name it custom.jive.bin http://update.slimdevices.com/update/firmware/7.2/jive_7.2_r2873.bin 2. extract the version info with `unzip -p custom.jive.bin jive.version > custom.jive.version` 3. restart SC when you connect to a SC-connected player with SBC after these steps, you should be prompted to download and install 2873.
I'm not sure if comment 17 was directed at me specifically, but yes. I have not tried to revert to r2873 because I know it worked fine for non-Boom players. Even for Boom players, the Music Source window would open and list my SC - only SN was missing.
okay, fair enough. admittedly I'm kind of grasping at straws with this since I can't reproduce. There were only two checkins on the 7.1 branch between 2873 and 2907, and only one that was in this area of the code. What's really strange is that that checkin was only for code changes within the _addServerItem() method, which from Fletch's log is clearly not the issue-- the problem is that the servers aren't being found in the first place. So, hence my confusion as to 2873<->2907 should be acting differently. for documentation sake, here's that checkin. --------------------- Author: bklaas Date: Thu Sep 4 14:03:06 2008 New Revision: 2907 URL: http://svn.slimdevices.com?rev=2907&root=Jive&view=rev Log: Bug: 9307 Description: allow other music sources to be selected from boom Modified: 7.1/trunk/squeezeplay/src/squeezeplay/share/applets/ChooseMusicSource/ChooseMusicSourceApplet.lua 7.1/trunk/squeezeplay/src/squeezeplay/share/jive/slim/Player.lua Modified: 7.1/trunk/squeezeplay/src/squeezeplay/share/applets/ChooseMusicSource/ChooseMusicSourceApplet.lua URL: http://svn.slimdevices.com/7.1/trunk/squeezeplay/src/squeezeplay/share/applets/ChooseMusicSource/ChooseMusicSourceApplet.lua?rev=2907&root=Jive&r1=2906&r2=2907&view=diff ============================================================================== --- 7.1/trunk/squeezeplay/src/squeezeplay/share/applets/ChooseMusicSource/ChooseMusicSourceApplet.lua (original) +++ 7.1/trunk/squeezeplay/src/squeezeplay/share/applets/ChooseMusicSource/ChooseMusicSourceApplet.lua Thu Sep 4 14:03:06 2008 @@ -126,8 +126,7 @@ function _addServerItem(self, server, address) log:debug("_addServerItem ", server, " " , port) - local id = server or address - + local id = server:getIpPort() or address -- remove existing entry if self.serverList[id] then @@ -165,8 +164,6 @@ if currentPlayer and currentPlayer:getSlimServer() and server == currentPlayer:getSlimServer() then item.style = 'checkedNoAction' item.callback = nil - elseif not currentPlayer or not currentPlayer:canConnectToServer() then - return end self.serverMenu:addItem(item) Modified: 7.1/trunk/squeezeplay/src/squeezeplay/share/jive/slim/Player.lua URL: http://svn.slimdevices.com/7.1/trunk/squeezeplay/src/squeezeplay/share/jive/slim/Player.lua?rev=2907&root=Jive&r1=2906&r2=2907&view=diff ============================================================================== --- 7.1/trunk/squeezeplay/src/squeezeplay/share/jive/slim/Player.lua (original) +++ 7.1/trunk/squeezeplay/src/squeezeplay/share/jive/slim/Player.lua Thu Sep 4 14:03:06 2008 @@ -81,7 +81,7 @@ [4] = "squeezebox2", [5] = "transporter", [7] = "receiver", - [10] = "b", + [10] = "boom", } @@ -655,7 +655,7 @@ if self.info.model == "squeezebox2" or self.info.model == "receiver" or self.info.model == "transporter" - or self.info.model == "b" then + or self.info.model == "boom" then return string.gsub(self.id, "[^%x]", "") end @@ -1156,7 +1156,7 @@ return self.info.model == "squeezebox2" or self.info.model == "receiver" or self.info.model == "transporter" - or self.info.model == "b" + or self.info.model == "boom" end @@ -1165,7 +1165,7 @@ return self.info.model == "squeezebox2" or self.info.model == "receiver" or self.info.model == "transporter" - or self.info.model == "b" + or self.info.model == "boom" end
OK Ben, just for you :-) I reverted to r2873 and everything worked as expected (except for the "Boom can't switch to SN" bug). I then re-upgraded to r2907 and am still unable to enter the Music Source window for any player.
thank ye kindly. that pretty much defines the issue as being caused by checkin r2907. still makes no sense to me, but at least it assuredly narrows the scope.
Fletch, this line from your log...were you doing some hacking? I don't think this has any bearing on the problem, but would like to know why jive is looking for an applet called SqueezeDiscovery, because there is no such thing in the repository: Sep 16 07:00:49 SqueezeboxController user.err jive: (AppletManager.lua:183) - Error while loading meta for SqueezeDiscovery:/usr/share/jive/jive/AppletManager.lua:151: error loading meta `SqueezeDiscovery' (cannot open /usr/share/jive/applets/SqueezeDiscovery/SqueezeDiscoveryMeta.
Nope. I haven't hacked anything nor have I installed any 3rd party applets.
wow, okay...this is going into Twilight Zone territory now. There is exactly one mention of "SqueezeDiscovery" in the entire current 7.1 squeezeplay codebase, and it's an a block that's commented out. --- squeezeplay/7.1/trunk/squeezeplay/src: ack SqueezeDiscovery squeezeplay/share/jive/AppletManager.lua 64: SqueezeDiscovery = true, --- I've pinged Richard to see if he has any idea what's going on with that. I'm going to try to post a revised ChooseMusicSourceApplet.lua file here later tonight, adding in a ton of log() messages for tracing what's going on, as well as adding back one small block of code that was removed in r2907. I'll post instructions on getting that file on to the controller along side it.
It's probably not an issue, but I should add that this is an SBC that I received during the very late stages of the Jive beta testing. I always assumed it was MPQ, but I really don't know. 00:04:20:1A:01:75 I don't have a newer SBC, but if you send me one I'll be happy to test it ;-)
Created attachment 4013 [details] ChooseMusicSourceApplet with a whole bunch of debug messages added Fletch, if you could stick this applet on to your controller that is otherwise running r2907 it would be of help. Steps to do this: 1. scp ChooseMusicSourceApplet.lua root@your.sbc.ip.address:/usr/share/jive/applets/ChooseMusicSource/. 2. reboot controller then reproduce the issue (though note: shot-in-the-dark possibility this new applet file will fix it), then attach the messages file again to the bug. btw-- don't think an MPQ unit is of concern, though I'm amazed that you know what MPQ is :)
Created attachment 4015 [details] Log with Ben's special ChooseMusicSourceApplet Here you go...
Created attachment 4016 [details] another ChooseMusicSourceApplet.lua; only call server:getIpPort() if server exists second verse, same as the first... Fletch, can you give this one a whirl? I think there's a good chance this will fix the issue. What I saw in the last log was this: Sep 17 05:53:35 SqueezeboxController user.warn jive: (ChooseMusicSourceApplet.lua:86) - BKDEBUG: Time to poll Sep 17 05:53:35 SqueezeboxController user.warn jive: (ChooseMusicSourceApplet.lua:89) - BKDEBUG: Here's one: 255.255.255.255 Sep 17 05:53:35 SqueezeboxController user.warn jive: (ChooseMusicSourceApplet.lua:89) - BKDEBUG: Here's one: 10.192.163.3 Sep 17 05:53:35 SqueezeboxController user.warn jive: (ChooseMusicSourceApplet.lua:91) - BKDEBUG: this server is in the polled list: 10.192.163.3 <then nothing more from ChooseMusicSource> what's different about your setup (issue seen) and my setup (issue not seen), is that your server list comes from the poll list, not the discovered slimserver list. When called from the polled list loop, it balks when it hits this line of code in ChooseMusicSource:_addServerItem(): local id = server:getIpPort() or address Can you scp on this new applet and let me know if it fixes the issue?
Yep, that fixes it! Let me know if you still want to see the log.
saweet! no need for a log, now that it works the log will just confirm that. I'll strip the debug log messages and check it in today. Kudos for your patience and help, Fletch. Probably never would have figured this out without your assistance. moving forward I'm going to try to figure out how to my force my squeezecenters to be in the "polled" list and not the "discovered" list-- that will be all that's required to exercise that part of the ChooseMusicSource code. There is definitely some further opportunities for code cleanup there, but right now I'm not going to fix what ain't broke.
(In reply to comment #30) > Kudos for your patience and help, Fletch. Probably never would have figured > this out without your assistance. Glad to help :-)
fix checked in, r2920. r2907 should not be used any more...either stick with the release build, r2873, or use this one when it is made available with tomorrow's nightly build cycle. r2920 (or later) will probably be pushed out to users in the not-too-distant future.
Verified fixed in SqueezeCenter 7.2.1-23555 Controller 7.2 r3080 Boom r33 Was able to switch from SN > SC > SC > SN
This bug has been fixed in the 7.3.0 release version of SqueezeCenter! Please download the new version from http://www.slimdevices.com/su_downloads.html if you haven't already. If you are still experiencing this problem, feel free to reopen the bug with your new comments and we'll have another look.