Closed SamInPgh closed 3 years ago
Hmm ... I wonder what LMS actually sends. To see this, In the LMS web-interface please select Settings/Advanced/Logging and raise the "(network.cometd) - Cometd protocol logging" log-level to Debug.
Then we can decide whether this should be fixed in LMS or in Squeezer.
Here is the portion of the log that is created when I select "My Apps" for one of the two squeezelite players. Keep in mind that the list is displayed correctly when non-squeezelite players are selected and also when a different client app (SqueezeCtrl) is used with the squeezelite players. Let me know if you need additional info. Thanks.
[21-07-08 18:56:02.9245] Slim::Web::Cometd::handler (149) Cometd request (192.168.1.9:47032): [
{
channel => "/slim/request",
clientId => "338f3fa6",
data => {
request => [
"b8:26:eb:c1:71:f0",
["myapps", "items", 0, 50, "useContextMenu:1", "menu:myapps"],
],
response => "/338f3fa6/slim/request/2",
},
id => 181,
},
]
[21-07-08 18:56:03.0572] Slim::Web::Cometd::handleRequest (893) Request for /338f3fa6/slim/request/2 / 181 is async, will callback
[21-07-08 18:56:03.1053] Slim::Web::Cometd::sendHTTPResponse (724) Sending Cometd response (192.168.1.9:47032):
HTTP/1.1 200 OK
Cache-Control: no-cache
Pragma: no-cache
Content-Length: 80
Content-Type: application/json
Expires: -1
X-Time-To-Serve: 0.236538887023926
[{"clientId":"338f3fa6","channel":"/slim/request","successful":true,"id":"181"}]
[21-07-08 18:56:03.8561] Slim::Display::Display::string (887) Error: missing string
[21-07-08 18:56:03.8867] Slim::Display::Display::string (887) Backtrace:
frame 0: Slim::Utils::Log::logBacktrace (/usr/share/perl5/Slim/Display/Display.pm line 887)
frame 1: Slim::Display::Display::string (/usr/share/perl5/Slim/Player/Player.pm line 193)
frame 2: Slim::Player::Player::string (/usr/share/perl5/Slim/Plugin/MyApps/Plugin.pm line 122)
frame 3: Slim::Plugin::MyApps::Plugin::__ANON__ (/usr/share/perl5/Slim/Formats/XML.pm line 330)
frame 4: Slim::Formats::XML::gotViaHTTP (/usr/share/perl5/Slim/Networking/SimpleAsyncHTTP.pm line 154)
frame 5: Slim::Networking::SimpleAsyncHTTP::onBody (/usr/share/perl5/Slim/Networking/Async/HTTP.pm line 608)
frame 6: Slim::Networking::Async::HTTP::_http_read_body (/usr/share/perl5/Slim/Networking/IO/Select.pm line 122)
frame 7: (eval) (/usr/share/perl5/Slim/Networking/IO/Select.pm line 118)
frame 8: Slim::Networking::IO::Select::__ANON__ (/usr/share/perl5/Slim/Networking/IO/Select.pm line 167)
frame 9: (eval) (/usr/share/perl5/Slim/Networking/IO/Select.pm line 167)
frame 10: Slim::Networking::IO::Select::loop (/usr/sbin/squeezeboxserver line 729)
frame 11: main::idle (/usr/sbin/squeezeboxserver line 679)
frame 12: main::main (/usr/sbin/squeezeboxserver line 1216)
[21-07-08 18:56:03.9230] Slim::Display::Display::string (887) Error: missing string
[21-07-08 18:56:03.9478] Slim::Display::Display::string (887) Backtrace:
frame 0: Slim::Utils::Log::logBacktrace (/usr/share/perl5/Slim/Display/Display.pm line 887)
frame 1: Slim::Display::Display::string (/usr/share/perl5/Slim/Player/Player.pm line 193)
frame 2: Slim::Player::Player::string (/usr/share/perl5/Slim/Plugin/MyApps/Plugin.pm line 122)
frame 3: Slim::Plugin::MyApps::Plugin::__ANON__ (/usr/share/perl5/Slim/Formats/XML.pm line 330)
frame 4: Slim::Formats::XML::gotViaHTTP (/usr/share/perl5/Slim/Networking/SimpleAsyncHTTP.pm line 154)
frame 5: Slim::Networking::SimpleAsyncHTTP::onBody (/usr/share/perl5/Slim/Networking/Async/HTTP.pm line 608)
frame 6: Slim::Networking::Async::HTTP::_http_read_body (/usr/share/perl5/Slim/Networking/IO/Select.pm line 122)
frame 7: (eval) (/usr/share/perl5/Slim/Networking/IO/Select.pm line 118)
frame 8: Slim::Networking::IO::Select::__ANON__ (/usr/share/perl5/Slim/Networking/IO/Select.pm line 167)
frame 9: (eval) (/usr/share/perl5/Slim/Networking/IO/Select.pm line 167)
frame 10: Slim::Networking::IO::Select::loop (/usr/sbin/squeezeboxserver line 729)
frame 11: main::idle (/usr/sbin/squeezeboxserver line 679)
frame 12: main::main (/usr/sbin/squeezeboxserver line 1216)
[21-07-08 18:56:04.0560] Slim::Web::Cometd::requestCallback (925) requestCallback got results for /338f3fa6/slim/request/2 / 181
[21-07-08 18:56:04.6534] Slim::Web::Cometd::Manager::deliver_events (254) Delivering events to 338f3fa6:
do {
my $a = [
{
channel => "/338f3fa6/slim/request/2",
data => {
base => {
actions => {
add => {
cmd => ["myapps", "playlist", "add"],
itemsParams => "params",
params => { menu => "myapps" },
player => 0,
},
"add-hold" => {
cmd => ["myapps", "playlist", "insert"],
itemsParams => "params",
params => 'fix',
player => 0,
},
go => { cmd => ["myapps", "items"], itemsParams => "params", params => 'fix' },
more => {
cmd => ["myapps", "items"],
itemsParams => "params",
params => 'fix',
player => 0,
window => { isContextMenu => 1 },
},
play => {
cmd => ["myapps", "playlist", "play"],
itemsParams => "params",
nextWindow => "nowPlaying",
params => 'fix',
player => 0,
},
playControl => {
cmd => ["myapps", "items"],
itemsParams => "playControlParams",
params => { _index => 0, _quantity => 50, menu => "myapps", useContextMenu => 1 },
player => 0,
window => { isContextMenu => 1 },
},
},
},
count => 7,
item_loop => [
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.0", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com",
text => "",
type => "link",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.1", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com",
text => "",
type => "link",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.2", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com/static/images/icons/lma.png",
text => "Live Music Archive",
type => "link",
},
{
actions => {
go => { cmd => ["podcasts", "items"], params => { menu => "podcasts" } },
},
addAction => "go",
"icon-id" => "plugins/Podcast/html/images/icon.png",
text => "Podcasts",
type => "redirect",
},
{
actions => {
go => {
cmd => ["radioparadise", "items"],
params => { menu => "radioparadise" },
},
},
addAction => "go",
"icon-id" => "plugins/RadioParadise/html/icon.png",
text => "Radio Paradise",
type => "redirect",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.5", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com/static/images/icons/icon_nature_sounds.png",
text => "Sounds & Effects",
type => "link",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.6", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com/static/images/icons/tidal.png",
text => "TIDAL",
type => "link",
},
],
offset => 0,
title => "My Apps",
window => { windowStyle => "home_menu" },
},
ext => { priority => "" },
id => 181,
},
];
$a->[0]{data}{base}{actions}{"add-hold"}{params} = $a->[0]{data}{base}{actions}{add}{params};
$a->[0]{data}{base}{actions}{go}{params} = $a->[0]{data}{base}{actions}{add}{params};
$a->[0]{data}{base}{actions}{more}{params} = $a->[0]{data}{base}{actions}{add}{params};
$a->[0]{data}{base}{actions}{play}{params} = $a->[0]{data}{base}{actions}{add}{params};
$a;
}
[21-07-08 18:56:04.6786] Slim::Web::Cometd::sendHTTPResponse (730) Sending Cometd chunk (192.168.1.9:47023):
[{"ext":{"priority":""},"id":"181","data":{"item_loop":[{"icon":"https://www.mysqueezebox.com","actions":{"go":{"cmd":["myapps","items"],"params":{"item_id":"015eff1e.0","menu":"myapps"}}},"text":"","addAction":"go","type":"link"},{"addAction":"go","type":"link","text":"","icon":"https://www.mysqueezebox.com","actions":{"go":{"cmd":["myapps","items"],"params":{"menu":"myapps","item_id":"015eff1e.1"}}}},{"text":"Live Music Archive","addAction":"go","type":"link","actions":{"go":{"params":{"menu":"myapps","item_id":"015eff1e.2"},"cmd":["myapps","items"]}},"icon":"https://www.mysqueezebox.com/static/images/icons/lma.png"},{"type":"redirect","addAction":"go","text":"Podcasts","icon-id":"plugins/Podcast/html/images/icon.png","actions":{"go":{"params":{"menu":"podcasts"},"cmd":["podcasts","items"]}}},{"icon-id":"plugins/RadioParadise/html/icon.png","actions":{"go":{"cmd":["radioparadise","items"],"params":{"menu":"radioparadise"}}},"type":"redirect","addAction":"go","text":"Radio Paradise"},{"icon":"https://www.mysqueezebox.com/static/images/icons/icon_nature_sounds.png","actions":{"go":{"params":{"item_id":"015eff1e.5","menu":"myapps"},"cmd":["myapps","items"]}},"addAction":"go","type":"link","text":"Sounds & Effects"},{"icon":"https://www.mysqueezebox.com/static/images/icons/tidal.png","actions":{"go":{"cmd":["myapps","items"],"params":{"item_id":"015eff1e.6","menu":"myapps"}}},"text":"TIDAL","type":"link","addAction":"go"}],"window":{"windowStyle":"home_menu"},"offset":"0","count":"7","title":"My Apps","base":{"actions":{"more":{"params":{"menu":"myapps"},"player":"0","cmd":["myapps","items"],"window":{"isContextMenu":"1"},"itemsParams":"params"},"go":{"cmd":["myapps","items"],"itemsParams":"params","params":{"menu":"myapps"}},"play":{"player":"0","params":{"menu":"myapps"},"nextWindow":"nowPlaying","itemsParams":"params","cmd":["myapps","playlist","play"]},"add-hold":{"itemsParams":"params","cmd":["myapps","playlist","insert"],"player":"0","params":{"menu":"myapps"}},"add":{"cmd":["myapps","playlist","add"],"itemsParams":"params","params":{"menu":"myapps"},"player":"0"},"playControl":{"params":{"useContextMenu":"1","_quantity":"50","menu":"myapps","_index":"0"},"player":"0","window":{"isContextMenu":"1"},"cmd":["myapps","items"],"itemsParams":"playControlParams"}}}},"channel":"/338f3fa6/slim/request/2"}]
Thanks for the log output.
So Squeezer sends:
{
channel => "/slim/request",
clientId => "338f3fa6",
data => {
request => [
"b8:26:eb:c1:71:f0",
["myapps", "items", 0, 50, "useContextMenu:1", "menu:myapps"],
],
response => "/338f3fa6/slim/request/2",
},
id => 181,
}
And the response is:
{
channel => "/338f3fa6/slim/request/2",
data => {
base => {
actions => {
add => {
cmd => ["myapps", "playlist", "add"],
itemsParams => "params",
params => { menu => "myapps" },
player => 0,
},
"add-hold" => {
cmd => ["myapps", "playlist", "insert"],
itemsParams => "params",
params => 'fix',
player => 0,
},
go => { cmd => ["myapps", "items"], itemsParams => "params", params => 'fix' },
more => {
cmd => ["myapps", "items"],
itemsParams => "params",
params => 'fix',
player => 0,
window => { isContextMenu => 1 },
},
play => {
cmd => ["myapps", "playlist", "play"],
itemsParams => "params",
nextWindow => "nowPlaying",
params => 'fix',
player => 0,
},
playControl => {
cmd => ["myapps", "items"],
itemsParams => "playControlParams",
params => { _index => 0, _quantity => 50, menu => "myapps", useContextMenu => 1 },
player => 0,
window => { isContextMenu => 1 },
},
},
},
count => 7,
item_loop => [
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.0", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com",
text => "",
type => "link",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.1", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com",
text => "",
type => "link",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.2", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com/static/images/icons/lma.png",
text => "Live Music Archive",
type => "link",
},
{
actions => {
go => { cmd => ["podcasts", "items"], params => { menu => "podcasts" } },
},
addAction => "go",
"icon-id" => "plugins/Podcast/html/images/icon.png",
text => "Podcasts",
type => "redirect",
},
{
actions => {
go => {
cmd => ["radioparadise", "items"],
params => { menu => "radioparadise" },
},
},
addAction => "go",
"icon-id" => "plugins/RadioParadise/html/icon.png",
text => "Radio Paradise",
type => "redirect",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.5", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com/static/images/icons/icon_nature_sounds.png",
text => "Sounds & Effects",
type => "link",
},
{
actions => {
go => {
cmd => ["myapps", "items"],
params => { item_id => "015eff1e.6", menu => "myapps" },
},
},
addAction => "go",
icon => "https://www.mysqueezebox.com/static/images/icons/tidal.png",
text => "TIDAL",
type => "link",
},
],
offset => 0,
title => "My Apps",
window => { windowStyle => "home_menu" },
},
ext => { priority => "" },
id => 181,
}
Notice the count = 7, and the item_loop contains 2 items at the top with no text (and invalid icon path). This indicates to me that Squeezer is showing the received info correctly.
Your log also shows 2 traces with "Slim::Display::Display::string (887) Error: missing string".
Slim/Display/Display.pm line 887 reads:
return $strings->{$name} || ( logBacktrace("missing string $name") && $name );
This correlates with the 2 items without a text. What those 2 items are supposed to contain, why LMS is having trouble generating them, and why it doesn't happen with SqueezeCtrl i don't know. I think the proper way to determine this, is to ask in the forum, or alternatively try to debug yourself. If it turns out that Squeezer should/could do something different, I'm of course willing to try and do so.
Thanks for the feedback. I saw that too. As it turns out, I was wrong about the problem only happening with Squeezer. The "Slim::Display::Display::string (887) Error: missing string" errors also happen with SqueezeCtrl during its top-level menu creation, but not on each invocation of the "My Apps" menu, probably because it caches the information and only creates the menu once. It apparently just skips menu entries with invalid urls or null text strings when displaying them. I will pursue this issue elsewhere as you suggest. One thing I have found, just for additional info, is that each of these two null entries seems to be associated with an active plugin. That is to say, when I remove the "Radio Paradise" plugin, one of the null entries goes away and when I remove the "Podcasts" plugin, the other one goes away, leaving the remaining 3 "My Apps" entries displaying correctly without the missing string errors. Unfortunately, I use both of those plugins extensively. Thanks again. You can close this issue if you like.
This was found to be an LMS issue and is fixed in V8.2.
I have five players in my system. Three are controlled by Philippe's Chromecast plugin (squeeze2cast) and the other two are separate instances of squeezelite, all running on the same machine (rPi) as the Server. For only the two squeezelite players, when I select "My Apps" from the Squeezer menu, I get two blank entries at the top followed by the correct five apps:
At the same time, the following error messages are written to the Server debug log:
The problem doesn't happen with my other client app SqueezeCtrl. Only the five valid Apps are displayed and no error messages are created.
Any help in tracking this down would be greatly appreciated. I am running Squeezer v2.2.6.