Home of the Squeezebox™ & Transporter® network music players.
Page 6 of 6 FirstFirst ... 456
Results 51 to 59 of 59

Thread: iPeng and YT

  1. #51
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,987
    Ok, there must be some corner case where Youtube and Spotty (and others, I assume) don't behave correctly. That would likely be a bug in XMLBrowser. That said, your YT plugin does behave differently in some aspects, which seems to expose that issue more often than the others.

    I was wondering about the "All Songs" item. Why would you need it? Because the tracks found wouldn't all be played/queued like it happens with other lists (eg. album tracks)? That might be the reason why users want to go back to the list to play more - exposing above issue. This simple change would make your video list behave like most other track lists, in that it would queue up all tracks by default, starting playback with whatever track you picked:

    Code:
    diff --git a/plugin/Plugin.pm b/plugin/Plugin.pm
    index f70b77e..888e70f 100644
    --- a/plugin/Plugin.pm
    +++ b/plugin/Plugin.pm
    @@ -535,7 +535,7 @@ sub _renderList {
                            # $item->{type}            = 'audio';
                            $item->{on_select} = 'play';
                            $item->{play}      = STREAM_BASE_URL . $id;
    -
    +                       $item->{playall}   = 1;
                    } elsif ($kind eq 'youtube#playlist') {
                            $item->{name} = $plTags->{prefix} . $title . $plTags->{suffix};
                            $item->{passthrough} = [ { playlistId => $id, %{$through} } ];
    I'm not saying that the actual bug should not be fixed. But as it hasn't seen (m)any reports in a long time, it seems to me that "streamlining" your code might be a good workaround for now.

    BTW: your latest release would only give me a hand full of search results in the UI, but queue up dozens of them. Bug or feature?
    Michael

    http://www.herger.net/slim-plugins - Spotty, MusicArtistInfo

  2. #52
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,987
    Quote Originally Posted by philippe_44 View Post
    What I've done is caching the latest search parameter for a given client for 60s. When I receive an empty search query, I'm pulling that parameter back from the cache and using it.
    IMHO that's asking for trouble... the way you implemented it wouldn't allow you to do two different searches within 60s, would it?

    (related but slightly OT: I do see that change in my git clone, but not on GitHub?!? https://github.com/philippe44/LMS-Gr...86a7b197ee1f82 WTF??)
    Michael

    http://www.herger.net/slim-plugins - Spotty, MusicArtistInfo

  3. #53
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,987

    iPeng and YT

    Oh... and I finally can confirm that I do indeed see the problem with
    Spotty when doing a fresh search, but not with the saved searches. The
    lazy guy I am sure enough tested the saved searches all the time.

    I'm surprised this problem hasn't come up before...
    --

    Michael

  4. #54
    Senior Member
    Join Date
    May 2008
    Location
    Canada
    Posts
    3,773

    iPeng and YT

    Quote Originally Posted by mherger View Post
    Oh... and I finally can confirm that I do indeed see the problem with
    Spotty when doing a fresh search, but not with the saved searches. The
    lazy guy I am sure enough tested the saved searches all the time.

    I'm surprised this problem hasn't come up before...
    --

    Michael
    I have a solution, I just tried a pull request and I screwed up - give me a few minutes , sorry
    Last edited by philippe_44; 2018-01-11 at 00:08.
    LMS 7.7, 7.8 and 7.9 - 5xRadio, 3xBoom, 4xDuet, 1xTouch, 1 SB2. Sonos PLAY:3, PLAY:5, Marantz NR1603, JBL OnBeat, XBoxOne, XBMC, Foobar2000, ShairPortW, JRiver 21, 2xChromecast Audio, Chromecast v1 and v2, , Pi B3, B2, Pi B+, 2xPi A+, Odroid-C1, Odroid-C2, Cubie2, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5

  5. #55
    Senior Member
    Join Date
    May 2008
    Location
    Canada
    Posts
    3,773
    Quote Originally Posted by mherger View Post
    IMHO that's asking for trouble... the way you implemented it wouldn't allow you to do two different searches within 60s, would it?

    (related but slightly OT: I do see that change in my git clone, but not on GitHub?!? https://github.com/philippe44/LMS-Gr...86a7b197ee1f82 WTF??)
    I don't like the change either - I can extend the caching, just I was nervous about it but you're right it would not work it the user tries 2 songs from that list in >60s
    LMS 7.7, 7.8 and 7.9 - 5xRadio, 3xBoom, 4xDuet, 1xTouch, 1 SB2. Sonos PLAY:3, PLAY:5, Marantz NR1603, JBL OnBeat, XBoxOne, XBMC, Foobar2000, ShairPortW, JRiver 21, 2xChromecast Audio, Chromecast v1 and v2, , Pi B3, B2, Pi B+, 2xPi A+, Odroid-C1, Odroid-C2, Cubie2, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5

  6. #56
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,987

    iPeng and YT

    > I have a solution, Ijust tried a pull request and I screwed it ut - give
    > me a few minutes , sorry


    Excellent! Thank you very much!

    --

    Michael

  7. #57
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    19,987

    iPeng and YT

    > I don't like the change either - I can extend the caching, just I was
    > nervous about it but you're right it would not work it the user tries 2
    > songs from that list in >60s


    With your change to XMLBrowser this workaround should no longer be needed.

    --

    Michael

  8. #58
    Senior Member
    Join Date
    Jan 2010
    Location
    Hertfordshire
    Posts
    1,550
    Quote Originally Posted by mherger View Post
    > I don't like the change either - I can extend the caching, just I was
    > nervous about it but you're right it would not work it the user tries 2
    > songs from that list in >60s


    With your change to XMLBrowser this workaround should no longer be needed.

    --

    Michael
    This is working perfectly now with today's LMS update. I am still using YouTube version 0.61.2. Nice work.

    Sent from my SM-G900F using Tapatalk

  9. #59
    Senior Member
    Join Date
    May 2008
    Location
    Canada
    Posts
    3,773
    Quote Originally Posted by mherger View Post
    IMHO that's asking for trouble... the way you implemented it wouldn't allow you to do two different searches within 60s, would it?
    In fact, I'll take my previous comment back, I think the 60 seconds works, no? The idea is that there is always a correct search to build the contextMenu, and then where the 'search' value is missing is in the contextMenu itself, so the "play" from that context menu is wrong. So unless the user waits more than 60s in that contextMenu, the 'search' parameter should be the correct one. And any call to searchHandler w/o a parameter is a faulty search, so the most recent 'search' is probably not worse that what's in YT search result with no search data at all

    As you say, anyway, this should not be necessary with the update (if it's not breaking something else) so I'll retire the patch at some time when 7.9.1 is "official"
    LMS 7.7, 7.8 and 7.9 - 5xRadio, 3xBoom, 4xDuet, 1xTouch, 1 SB2. Sonos PLAY:3, PLAY:5, Marantz NR1603, JBL OnBeat, XBoxOne, XBMC, Foobar2000, ShairPortW, JRiver 21, 2xChromecast Audio, Chromecast v1 and v2, , Pi B3, B2, Pi B+, 2xPi A+, Odroid-C1, Odroid-C2, Cubie2, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •