PDA

View Full Version : Announce: YouTube Plugin



Pages : 1 [2] 3 4

pippin
2013-01-26, 06:23
Just enable 3rd Party Plugins under "Settings->Plugins" in the server's web interface and you can install it right from there.

doubleugk
2013-01-26, 06:24
I would suggest you simply select the plugin in plugin section, then restart your LMS and the latest version would be available. The manual steps were only applicable because the fix wasn't implemented in an update. I've successfully updated the plugin manually and later on an automated update was provided. Which is working well.

TheArchedOne
2013-01-26, 13:11
Just enable 3rd Party Plugins under "Settings->Plugins" in the server's web interface and you can install it right from there.

Thanks for getting back to me. The reason I did it manually is that my plugins tab doesn't work... it never has done so I've always had to install plugins manually. I raised this in another thread a long time ago and have just updated it with some more info (http://forums.slimdevices.com/showthread.php?93053-Plugins-tab-not-responding).

It would be great to get the plugins tab working, but if not, do you have any advice on the manual installation?

Cheers

TAO

TheArchedOne
2013-01-27, 13:35
Fixed the plugin tab issue, installed youtube and its working. Thanks for your help guys.

AceVan
2013-02-26, 16:49
Hello,

It was great to discover this YouTube plugin.

I installed the latest version (0.16) But it doesn't work.

The same issues as mentioned. After a few seconds it stops playing and starts up again.

I hope anyone can help me solve this problem.

Thanks

dave_p
2013-03-14, 21:19
Hi all,

I'm not sure if anyone is monitoring this thread too much these days, but I seem to be having a problem with the plugin -- an issue that was raised earlier, though the solution wasn't clear to me. I see the plugin fine, I can start a track, I see the video icon and it seems to show that it is playing/streaming the song; however, no music comes out (even at lower resolution setting).

In the log, I see:
Slim::Networking::IO::Select::__ANON__ (146) Error: Select task failed calling Slim::Networking::Async::HTTP::_http_read_body: Can't call method "pluginData" on an undefined value at /opt/ssods4/var/home/SqueezeboxServer/Cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 82.

Admittedly I'm running an old system:
ts209 II pro (armv5tel-linux)
SSODS 4.9.1 // SBS 7.5.2

But other than the youtube plugin, everything I need works great (i.e. I'd like to avoid having to try and 'fix' this with an upgrade that may cause larger headaches).

From what I've read through here, sbs 7.5 should be adequate.

Much appreciate any tips on how to troubleshoot this.

Thanks again as always.

Long live Slim!

pippin
2013-03-15, 00:38
I believe SBS 7.5 should be fine but I don't know whether the server is powerful enough for the plugin (I just don't know, it might just as well be an OS thing or something)

dave_p
2013-03-15, 07:50
I believe SBS 7.5 should be fine but I don't know whether the server is powerful enough for the plugin (I just don't know, it might just as well be an OS thing or something)

Thanks Pippin - I did some quick digging and it does seem the 209 II series can make this work (but I'm extrapolating a bit from what I found). Perhaps someone here can help decifer the log error message (I may also need to post in the Qnap forums).

(Pippin - you are the caregiver of Coolio yes? If so, I sent you an email about your app - hope to hear back)

datja
2013-05-02, 05:54
Hi again folks,

The relapsing problem again: no sound in the plugin again. (This happened after I just updated today.) It's a big problem because we will throw a big party in two days and had planned to use this plugin for music.

Could anybody who understands it check the protocolhandler file again please!!!

jimbobvfr400
2013-05-02, 09:24
Hi again folks,

The relapsing problem again: no sound in the plugin again. (This happened after I just updated today.) It's a big problem because we will throw a big party in two days and had planned to use this plugin for music.

Could anybody who understands it check the protocolhandler file again please!!!

Only a quick check, but I've just successfully played a couple of tracks from the top rated music list with no issues. If it helps LMS shows version 0.16 on the plugins tab.

Sent from my Nexus 7 using Tapatalk HD

pippin
2013-05-02, 10:52
Works for me, too, I've actually used it quite a bit today without problems.
How many tracks did you try? Not all videos work in all countries (most don't work in Germany) and some videos use codecs that can't be transcoded on all platforms.

sunnyside
2013-05-20, 04:22
It works fine. Thanx! It would be Nice to virus The video while listening to The music. Is Thatcher an option for The near future????

Fishy
2013-06-24, 09:46
Have noticed the plugin has stopped working for some streams.
Getting a "cannot connect to server" error message.
Problem seems to be restricted to Vevo.

Is there anyone here on the forum cleverer than me who can fix it??
Thanks in advance!

mps
2013-06-29, 18:56
I just started getting the Cannot Connect to Server message also.

Any suggestions?

Mike

tbessie
2013-08-08, 23:40
I would say only about 10% of streams on YouTube are now working for me with this plugin. I keep seeing what look like some kind of socket errors in the log.

Here are a few errors I see occasionally:

[13-05-25 12:11:49.1465] Plugins::YouTube::ProtocolHandler::__ANON__ (544) error: 400 Bad Request

[13-05-28 01:39:18.6745] Plugins::YouTube::ProtocolHandler::processFLV (233) tag size: 114539 greater than max: 102400 - closing stream

[13-08-03 02:27:00.5052] Slim::Networking::IO::Select::__ANON__ (147) Error: Select task failed calling Slim::Web::HTTP::sendStreamingResponse: substr outside of string at C:\ProgramData\Squeezebox\Cache\InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 197.
; fh=Slim::Web::HTTP::ClientConn=GLOB(0xa55229c)

... and then LOTS of the below whenever a stream doesn't work (sometimes associated with the last one above):

[13-08-04 00:36:39.5559] Slim::Networking::IO::Select::__ANON__ (147) Error: Select task failed calling Slim::Networking::Async::HTTP::_http_read_body: illegal file descriptor or filehandle (either no attached file descriptor or illegal value): at /<C:\PROGRA~2\SQUEEZ~1\server\SQUEEZ~3.EXE>Slim/Networking/IO/Select.pm line 150.
; fh=Slim::Networking::Async::Socket::HTTP=GLOB(0x86 0bfc4)


... I wonder if the creator of this plugin might know what could be causing it.

- Tim

soulkeeper4
2013-09-28, 17:38
Hi to all of you!!

I've also installed it but none of the music clips i tried can play..

So is this plug in not developed/supported any more?

Thanks!

marky
2013-12-05, 15:05
Hi!

Is there any problem with stream quality? I didn't mark "Prefer Low Resolution" in advanced settings but when I playing HD stream on squeezbox it only plays low quality stream. I think the problem occurred a few weeks ago. Thanks in advance.

smr888
2013-12-29, 06:35
Many thanks for this plugin. Funny to be sitting thinking for the first time "Gee, it would be nice to be able to play YouTube through my Squeezebox", and five minutes later I'm doing it, thanks to you. It took me longer to figure out how to get the settings page to display "all" third party plugins than it did to install the plugin.

My tryout was not without a bump. I was not able to get the plugin to accept this URL:

http://www.youtube.com/watch?v=U-I7wbMY-A4

It kept saying "Bad YouTube URL".

I was able to play the actual video by searching on Komm Susser Todd and selecting the entry "Bach - Sacred Song 'Komm, ser Tod' BWV 478", which is what I was looking for. So it doesn't seem to be a problem with the content, but the plugin evidently doesn't like that URL.

paulster
2013-12-29, 12:34
The URL thing had been broken for some time, I think since YouTube changed their URL format.

Since the plugin doesn't have an active maintainer it's reliant on best-endeavour patches and fixes from the user community.

It's great that it still works as well as it does after all this time!

marky
2014-01-01, 10:35
Hi!

Is there any problem with stream quality? I didn't mark "Prefer Low Resolution" in advanced settings but when I playing HD stream on squeezbox it only plays low quality stream. I think the problem occurred a few weeks ago. Thanks in advance.

Is it only me having a problem with low quality youtube stream? No other user has noticed difference in stream quality?

SlimChances
2014-01-18, 17:10
All my selections getting "No More Streams" . Is the plugin broken? Using ver .16

edit: working now

echievements
2014-01-21, 10:15
After checking mysqueezebox.com and the squeezebox plugins, I cannot locate the source to install the YouTube Plugin.

My firmware is up to date.

Thanks for helping a neophyte in these areas.

pippin
2014-01-21, 12:20
Enable "3rd party plugins" in "Settings->Plugins" in the web interface, then you can install it right there.
No need to handle code.

icycle
2014-01-27, 07:23
After checking mysqueezebox.com and the squeezebox plugins, I cannot locate the source to install the YouTube Plugin.

My firmware is up to date.

Thanks for helping a neophyte in these areas.

To add to what pippin said, you also need to check the box at the bottom of the Settings -> Plugins tab: "Show all 3rd party plugins", apply the change, then you will see the Youtube plugin. I guess it's not a Logitech "recommended" plugin.

Vegz78
2014-04-21, 09:41
Getting the error message " no more streams" when trying to play Youtube streams on my SB Touch.

Connected to WD NAS with:
Status for Logitech Media Server
Logitech Media Server Versjon: 7.7.3 - 1375965195 @ Mon Aug 12 03:09:39 PDT 2013
Vertsnavn:
Serverens IP-adresse:
HTTP-serverens portnummer: 9000
Operativsystem: Debian - NO - utf8
Plattformarkitektur: ppc-linux
Perl-versjon: 5.10.1 - powerpc-linux-gnu-thread-multi
Databaseversjon: DBD::SQLite 1.34_01 (sqlite 3.7.7.1)
Totalt antall tilkoplede spillere: 2

Something I'm not doing right?

Vegard

tiggert
2014-05-02, 03:40
Hi,
I too am hitting the "no more streams" error message when trying to use the Youtube plugin to stream the audio from a video clip.
On my Squeezbox radio it displays an image for the video clip, but it doesn't play and displays the "no more streams" message.
Does anyone have a fix for this please? Thanks in advance.
I had this working before I had to restore my Raspberry Pi from a copy I had before I'd installed the youtube plugin, so had to install it again, and since then I have this problem.

Information from my system:
Youtube plugin version 0.16

Error in the log:
[14-05-01 18:31:46.2269] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://x1FGvJuUmS8].

Logitech Media Server Version: 7.7.2 - r33893 @ Wed Mar 14 05:46:46 PDT 2012
(Running on Raspberry Pi)

Operating system: Debian - EN - utf8

Platform Architecture: armv7l-linux

Perl Version: 5.14.2 - arm-linux-gnueabihf-thread-multi-64int

Database Version: DBD::SQLite 1.34_01 (sqlite 3.7.7.1)

Total Players 3

Player Model: Squeezebox Radio

Firmware: 7.7.2-r9663

Kitchen Boom

Player Model: Squeezebox Boom

Firmware: 57

Lounge

Player Model: SqueezeLite

tiggert
2014-05-02, 06:40
slimchances - thanks for your reply on the other thread, I'm not sure if your watching this one but will try here first to not disrupt your other one.
I'm copying your reply here for reference:
"I didn't do anything it just started working for some streams. However other streams don't work . It is a great plugin (YouTube plugin) but as I understand it YouTube is frequently making changes that break the plugin and there is no active developer improving the plugin. Sorry I couldn't be more help."

I agree that it is (was for me) a great plugin. Are you able to let post a link to a stream that does work for you, so that I can test if that is all I'm experiencing or if my problem maybe something else?

Thanks again.

SlimChances
2014-05-02, 06:49
Hard Sun
youtube://X2k-mtM1s5U

Now on first try it didn't work so I switched to a different stream, which also didn't work. Then I switched back to Hard Sun again and it worked. Seems to be the case that to have any of them to work I have to keep trying streams before it works. Annoying for sure

tiggert
2014-05-02, 07:25
Thanks again Slimchances. I'll try that when I'm at home.

tiggert
2014-05-02, 17:14
Nope, that clip does the same for me and I've tried lots of different ones but all give me the same message. I notice you're on 7.8 so I suppose that's the next thing to try. Will try to backup my Pi and try an upgrade of the server and see if that helps... but not tonight!

tiggert
2014-05-02, 17:42
Oh, actually my lms web gui only takes me to uograde to 7.7.3. How would I upgrade to 7.8.0 ? Thanks.

pippin
2014-05-02, 19:49
You'd have to download it from downloads.slimdevices.com, it's no longer officially supported by Logitech.

That said, I don't think it would make a difference in your case. The YouTube plugin was developed for LMS 7.7.2 and if it doesn't work for you on 7.7.3 7.8 will probably not fix that.

tiggert
2014-05-05, 12:07
Thanks Pippin. But if the LMS version won't make a difference then I can't see why it plays stuff for slimchances but not for me. Any ideas? Thanks again.

Kris
2014-05-30, 21:38
Hi guys, im using 7.7.2 and 016 of the plugin, it goes to play and i can see the timer start for the track duration, it gets to 1 or 2 seconds but no audio comes out and then it stops

Everything else audio works, mp3s, radio etc

Please help

tephlon
2014-05-31, 09:19
Hi,

I've had a lot of problems with this plugin (again), always getting the "no more streams" message. Looking into the issue, I noticed that the plugin always got a 403 Forbidden response from the Youtube server. Having a very bad failure rate with this plugin the last year(s) I decided to have a stab at replacing the innards of it with youtube-dl. I failed miserably with this, since I'm very weak with perl and the plugin uses the server code's RemoteStream module to reencode and play the stream, which makes it really hard to do that kind of hack.

The problem the plugin had was (1) the "signature" query variable had been renamed to "s" (not that it helped renaming it...), (2) the stream URLs were all https, which the RemoteStream module doesn't support (I tried to make it support that - I want those hours back! :)), and (3) one does not simply replace "https" with "http" when talking to youtube... :p

What I did succeed in, was having youtube-dl retrieve the proper stream URLs, and now the plugin plays music again :) Here's the patch: 15992. Please note that you need the Perl IPC::Run module as well as the youtube-dl application installed for it to work.

tiggert
2014-06-04, 11:33
Oh Tephlon you give me some hope!
Would you be able to add a short step by step guide for a newbie like me (please)? I'll be SO happy if I can get this plugin to work again!

tephlon
2014-06-04, 12:08
Sure :) First you need to locate where LMS installs your plugins. It seems to be whatever you have --cachedir set to. From that folder you should be able to cd to InstalledPlugins/Plugins/YouTube/ in which you'll find a ProtocolHandler.pm file. Download the patch file I posted (or preferably the one in this post) and put it somewhere on the same machine. Then you issue

patch -p0 < path_to_patch_file
and restart LMS. Then you should be done :)

Here is a new version of the patch, which will (1) avoid the extra Youtube roundtrip the first patch made, (2) make the seeking work (again?), and (3) be more agnostic about what youtube URLs it accepts.

Again, please note that you need the Perl IPC::Run module as well as the youtube-dl application installed for it to work.

tiggert
2014-06-04, 15:26
Thanks! I'll try to find time to check it out and give it a go. BTW I'm running my LMS on a raspberry pi via Squeezeplug. And I've just checked the Squeezeplug website and see there have been lots of updates since I installed so I should probably try updating that too first. Will need to backup my image first.

tiggert
2014-06-07, 12:26
I'm planning on trying this tonight, but wonder about the IPS::Run module and the youtube-dl application that tephlon mentions you need. Are they just plugins from LMS or something else?
Thanks.

tiggert
2014-06-07, 16:30
OK so I updated Squeezeplug on my Pi to 7.09, that updated my LMS to 7.8. Installed the youtube plugin. Tested, and as expected got the "no more streams" symptom as before.
I then installed the IPS::Run module (I think: I did an "apt-get install libipc-run-perl"), and tephlon's patch, and tried again.
This time I don't get the "no more streams" message, and the LMS seems to think it's playing the stream (the time ticks forwards), but I'm getting no sound through my squeezelite player, and on my squeezebox radio it the time ticks forwards *very* slowly, but doesn't play any sound.

Any ideas what I've done wrong?

Cheers.

tiggert
2014-06-08, 02:12
I installed the youtube-dl application too (apt-get install youtube-dl) and restarted the squeezplug but still getting the same symptoms as last night (see previous post).
This is what I see in the logs:
[14-06-08 10:28:36.8396] Slim::Utils::Timers::__ANON__ (273) Error: Timer Slim::Web::Cometd::sendResponse failed: illegal file descriptor or filehandle (either no attached file descriptor or illegal value): at /usr/share/perl5/Slim/Networking/IO/Select.pm line 150.
[14-06-08 10:29:08.3126] Slim::Control::Request::execute (1888) Error: While trying to run function coderef [Slim::Control::Commands::playlistJumpCommand]: [malformed JSON string, neither array, object, number, string or atom, at character offset 0 (before "(end of string)") at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 390.
]
[14-06-08 10:29:26.1138] Slim::Utils::Timers::__ANON__ (273) Error: Timer Slim::Web::Cometd::sendResponse failed: illegal file descriptor or filehandle (either no attached file descriptor or illegal value): at /usr/share/perl5/Slim/Networking/IO/Select.pm line 150.
[14-06-08 10:30:09.3575] Slim::Utils::Timers::__ANON__ (273) Error: Timer Slim::Web::Cometd::sendResponse failed: illegal file descriptor or filehandle (either no attached file descriptor or illegal value): at /usr/share/perl5/Slim/Networking/IO/Select.pm line 150.
Not sure what to try next.
tephlon? Anyone?
Thanks!

TeraX
2014-06-27, 14:20
Hello.

with LMS 7.7.3 on an Raspberry installed libipc-run-perl and youtube-dl I have the follow error msg with yt.patch:


2014-06-27 22:52:43 squeezeboxserver_safe started.
[14-06-27 22:53:04.4459] main::init (354) Starting Logitech Media Server (v7.7.3, 1375965195, Mon Aug 12 03:09:39 PDT 2013) perl 5.014002
[14-06-27 22:53:46.1176] Plugins::YouTube::ProtocolHandler::__ANON__ (510) error: 403 Forbidden
[14-06-27 22:53:50.0189] Plugins::YouTube::ProtocolHandler::__ANON__ (510) error: 403 Forbidden
[14-06-27 22:54:41.0072] Slim::Control::Request::execute (1889) Error: While trying to run function coderef [Slim::Control::Commands::playlistJumpCommand]: [malformed JSON string, neither array, object, number, string or atom, at character offset 0 (before "(end of string)") at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 390.
]
[14-06-27 22:54:41.0146] Slim::Web::JSONRPC::requestMethod (413) Request failed with error: Bad dispatch!
[14-06-27 22:54:43.2948] Slim::Control::Request::execute (1889) Error: While trying to run function coderef [Slim::Control::Commands::playlistJumpCommand]: [malformed JSON string, neither array, object, number, string or atom, at character offset 0 (before "(end of string)") at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 390.
]
[14-06-27 22:54:43.3015] Slim::Web::JSONRPC::requestMethod (413) Request failed with error: Bad dispatch!
[14-06-27 22:54:46.6155] Plugins::YouTube::ProtocolHandler::__ANON__ (510) error: 403 Forbidden

The Forbidden Msg is displayed after start. The execute Error after Playing a file
After a while some brake/crypted sound is playing.



with LMS 7.7.3 on an Raspberry installed libipc-run-perl and youtube-dl I have the follow error msg with yt3.patch (over original file):


2014-06-27 23:16:56 squeezeboxserver_safe started.
[14-06-27 23:17:18.2080] main::init (354) Starting Logitech Media Server (v7.7.3, 1375965195, Mon Aug 12 03:09:39 PDT 2013) perl 5.014002
[14-06-27 23:18:00.6680] Plugins::YouTube::ProtocolHandler::__ANON__ (510) error: 403 Forbidden
[14-06-27 23:18:52.4462] Slim::Control::Request::execute (1889) Error: While trying to run function coderef [Slim::Control::Commands::playlistJumpCommand]: [malformed JSON string, neither array, object, number, string or atom, at character offset 0 (before "(end of string)") at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 390.
]


no sound is playing

Greetings
TeraX

RickBox
2014-07-02, 01:00
no sound is playing

TeraX

Hi !

I've just registered to the forum to thanks author of this plugin and tephlon for his patch.
It work well for me but, for that:
- I need to remove my "youtube-dl" version from ubuntu repository (sudo apt-get remove youtube-dl), it seems that that this version have some options missing (ie: --prefer-insecure).
- And install like that :

sudo curl https://yt-dl.org/latest/youtube-dl -o /usr/local/bin/youtube-dl
sudo chmod a+x /usr/local/bin/youtube-dl
see here: github.com/rg3/youtube-dl/

Thanks again for your work

Rick

tiggert
2014-07-03, 23:56
Thanks loads Rickbox! With your advice I finally have this plugin working again.
Just strange thing it keeps trying to play me "One Direction" tracks when I'm telling it to play other stuff like Sohn!!! (Nooooo!) ;-)

nervoteso
2014-07-04, 08:08
could this plugin make buffering and streaming probels due to video loading? buffering issue is my first enemy so i would like to be sure before installing it.
thanks

TeraX
2014-07-13, 03:22
@Rick: Thank you very much! The youtube-dl Version you posted is working fine!

Best Regards
TeraX

SlimChances
2014-07-15, 13:18
After a few hickups I was able to apply the Y3 patch to version 1.6, but is not working.
Thanks to Rick, finally got things working. Had to install curl

sudo apt-get install curl
and it all worked out

Noticed that Youtube videos(songs) will only play if play is selected a second time

marky
2014-08-03, 05:13
I would like to thanks all the people who brings the youtube plugin to life again. But i still have got the same problem. All songs are playing in low resolution (non-HD). What I have to do to get an HD quality? I have tried to add "&hd=1" in "my $url" in ProtocolHandler.pm but without any effect. Thanks in advance for any suggestions.

rockpilp
2014-08-28, 02:07
I would like to thanks all the people who brings the youtube plugin to life again. But i still have got the same problem. All songs are playing in low resolution (non-HD). What I have to do to get an HD quality? I have tried to add "&hd=1" in "my $url" in ProtocolHandler.pm but without any effect. Thanks in advance for any suggestions.

The URL parameter you're trying to use is for the main youtube URL, not the direct download URL.

I've tried changing the format selection to prioritize downloading audio-only high-quality stream, but the rest of the plugin then barfs because it's expecting an FLV container, and it's getting a raw audio stream.

This module really needs to be more fully rewritten to account for the fact that YouTube can now stream the audio and video steams independently.

SlimChances
2014-09-01, 16:55
After thinking that the YouTube plugin was working I still have problems with most links not playing : (

marky
2014-09-03, 10:48
The URL parameter you're trying to use is for the main youtube URL, not the direct download URL.

I've tried changing the format selection to prioritize downloading audio-only high-quality stream, but the rest of the plugin then barfs because it's expecting an FLV container, and it's getting a raw audio stream.

This module really needs to be more fully rewritten to account for the fact that YouTube can now stream the audio and video steams independently.

Thanks for your reply. I think it's nearly impossible to find someone to fully rewrite this plugin :(

roggae
2014-09-11, 10:38
i installed the app but i cant get ipeng to play any youtube links...am i doing it wrong? i keep getting error "bad youtube URL".:confused:

EDIT: actually it wont play a live mixmag stream: http://youtu.be/9SpjgI7Jz8g

any thoughts?

pippin
2014-09-11, 11:27
If the plugin doesn't work, iPeng won't help, too.
Did you try it through iPeng's browser or through the YouTube plugin's menu?

roggae
2014-09-11, 13:22
If the plugin doesn't work, iPeng won't help, too.
Did you try it through iPeng's browser or through the YouTube plugin's menu?


i just entered the URL in the ipeng app.

pippin
2014-09-11, 15:39
Under "Tune In URL"?
That actually works for me (with this stream).
That said: it took the plugin VERY long to start decoding it and during that time the whole server stalled so that some players disconnected.
So not a simple stream...

jspamc
2014-11-29, 20:22
My streams no longer seem to start.

Using the latest version of LMS.

Anyone else having issues?

Many thanks!

Mysliwy
2014-12-10, 00:53
Same problem here.
Can anyone help?
This is the most important plugin for me. Without it LMS is almost useless. ;(

caalami
2014-12-23, 09:18
For me, the solution to my player showing the video thumbnail but refusing to play the track was to install Perl SSL support (Google must now mandate SSL for youtube). My NAS runs Ubuntu, so it was just:

apt-get install libio-socket-ssl-perl

(You could also install with CPAN).

And then restart the music server.

Hope this helps someone.

t-force
2014-12-24, 03:54
Does anyone know what would be required to similarly fix a Windows install of LMS?


For me, the solution to my player showing the video thumbnail but refusing to play the track was to install Perl SSL support (Google must now mandate SSL for youtube). My NAS runs Ubuntu, so it was just:

apt-get install libio-socket-ssl-perl

(You could also install with CPAN).

And then restart the music server.

Hope this helps someone.

bilbosb
2015-01-03, 13:51
hi, I have just discovered squeezebox etc, it seems great.

With this youtube app, it works but the soundtracks are playing much faster, voices sound like chipmonks. Is there anything I can try?

bpa
2015-01-03, 14:15
With this youtube app, it works but the soundtracks are playing much faster, voices sound like chipmonks. Is there anything I can try?

Not sure about Youtube plugin specially but "chipmonks" are often caused by a player that cannot play the freq of the selectec track. Squeezeslave has this problem. Otherwise LMS usually resamples.

What type of player and what LMS & LMS server ?

bilbosb
2015-01-03, 14:59
The latest logitech media server running on windows 7, squeezecast running on ios. Squeezplay seems ok on another windows machine seems ok.

bpa
2015-01-03, 16:05
The latest logitech media server running on windows 7, squeezecast running on ios. Squeezplay seems ok on another windows machine seems ok.

If Squeezeplay works -then it looks like the problem is with Squeezecast as Windows LMS should have full install with resampling.

pippin
2015-01-04, 18:10
SqueezeCast should have the same issues like Squeezeslave so that's consistent with what bpa writes. iPeng should work fine, SqueezePad, too (although there I'm not 100% sure).

jspamc
2015-01-26, 22:44
Anyone get this working again on a Windows based server?

britcowboy
2015-01-28, 18:25
I think the switch to HTML5 today may have broken the plugin, I could be wrong but a couple of days ago everything worked fine and now today it doesn't, and YouTube have just made HTML5 the default...

Can anyone confirm?

DavidBulluss
2015-01-29, 21:18
Today I installed the YouTube plugin into LMS v7.9.0 running on a ReadyNas Duo V2. It appears to work in as much as I can search and select specific material, but it often shows that it is going to play a different YouTube clip than selected (sometimes it shows the selected clip), but it *always* tries to play the clip for a few seconds with no sound, and then briefly shows an error message saying that "the redirection limit has been reached", or something to that effect. Is this a common issue? I have tried looking through this thread but haven't seen it mentioned.

Cheers!

mh_
2015-02-07, 10:47
How to install IO::Socket::SSL on SSOTS? Would it help?

MongarEric
2015-02-07, 19:32
Today I installed the YouTube plugin into LMS v7.9.0 running on a ReadyNas Duo V2. It appears to work in as much as I can search and select specific material, but it often shows that it is going to play a different YouTube clip than selected (sometimes it shows the selected clip), but it *always* tries to play the clip for a few seconds with no sound, and then briefly shows an error message saying that "the redirection limit has been reached", or something to that effect. Is this a common issue? I have tried looking through this thread but haven't seen it mentioned.

Cheers!

The same thing is happening to me, any help would be greatly appreciated.

smitti_
2015-02-10, 09:28
The same problem for me and it really would be great if there is still one who can fix this awsome plugin :D
It is so convinient if you just want to listen some livesets, or some pre-releases that you don't get for download anywhere.

vryonid
2015-02-20, 10:01
The same problem for me and it really would be great if there is still one who can fix this awsome plugin :D
It is so convinient if you just want to listen some livesets, or some pre-releases that you don't get for download anywhere.

Stopped working since HTML5 update. PLEASE Triode have a look :confused:

MJS
2015-02-24, 14:47
Hi,

I recently reinstalled and reconfigured my Synology DS410j with Squeezebox server 7.7.3-040. On the squeezebox I installed firmware 7.7.3-r16676. I also installed the YouTube plugin on the squeezebox server on my Synology.

On the squeezebox I can access the plugin under 'my applications' and search for music, but none of the videos I try to play work and squeezebox shows message Networktest after a while. I can also access Logitech media server through my browser and search for music, but none of them will play.

I don't see the plugin at all when I use the squeezebox app on Android or iOS.

All of this used to work fine before. Any ideas?

MJS
2015-02-25, 13:56
Hi,

I recently reinstalled and reconfigured my Synology DS410j with Squeezebox server 7.7.3-040. On the squeezebox I installed firmware 7.7.3-r16676. I also installed the YouTube plugin on the squeezebox server on my Synology.

On the squeezebox I can access the plugin under 'my applications' and search for music, but none of the videos I try to play work and squeezebox shows message Networktest after a while. I can also access Logitech media server through my browser and search for music, but none of them will play.

I don't see the plugin at all when I use the squeezebox app on Android or iOS.

All of this used to work fine before. Any ideas?

The YouTube plugin now shows up in the android and iOS apps. From my squeezebox, I connected to my online account instead of the Synology.
However, songs still don't play. I can search for music, but when chosing a song to play it returns an error message: 'No streams found'.

buffettck
2015-03-02, 08:12
Is this Youtube plug-in now broken? It worked before. I haven't tried it in a while, but no Youtube links will play on the computer or SBR despite them still showing in my favorites list. Has something changed? Thanks!

Ah, it looks like the latest Youtube update broke the plug-in. Someone please fix this ASAP! :)

terjehaa
2015-03-04, 11:48
Is this Youtube plug-in now broken? It worked before. I haven't tried it in a while, but no Youtube links will play on the computer or SBR despite them still showing in my favorites list. Has something changed? Thanks!

Ah, it looks like the latest Youtube update broke the plug-in. Someone please fix this ASAP! :)
We will have to ask politely if Triode could have a look into this problem. Please.....
:)

buffettck
2015-03-04, 11:49
We will have to ask politely if Triode could have a look into this problem. Please.....
:)

Or, even better, someone else with much more experience than I have can write a new app. It's never good to have what's known as a "single point failure" with anything and that's exactly what we have with Triode's app. It's broken for the foreseeable future and here's no other alternative right now.

berrange
2015-03-08, 11:46
I spent a few hours investigating this and found a 3 immediate problems, and solved the 2 easyish ones....

First youtube considers SSL to be mandatory - any attempt to request a non-SSL page results in a redirect. So you need to have the IO::SOcket::SSL modules installed

Second there's a slight data format change that breaks a regex used by the plugin

Third there's a new protection system for the player that requires unobfuscating a signature parameter in a pretty damn hard manner.

berrange
2015-03-08, 11:48
The following are the steps I used to install the SSL perl modules on my QNap NAS install of the squeezebox server. Note the /share/MD0_DATA part of the path may be different on your server

#ipkg install openssl openssl-dev
#ipkg install make
#ipkg install gcc

#cd /share/MD0_DATA/.qpkg/LogitechMediaServer/
#mkdir tmp
#cd tmp

#wget http://search.cpan.org/CPAN/authors/id/A/AB/ABH/Mozilla-CA-20141217.tar.gz
#tar zxvf Mozilla-CA-20141217.tar.gz
#cd Mozilla-CA-20141217
#../../bin/perl Makefile.PL
#make
#make install
#cd ..


#wget http://search.cpan.org/CPAN/authors/id/M/MI/MIKEM/Net-SSLeay-1.68.tar.gz
#tar zxvf Net-SSLeay-1.68.tar.gz
#cd Net-SSLeay-1.68
#OPENSSL_PREFIX=/opt ../../bin/perl Makefile.PL
#make
#make install
#cd ..


#wget http://search.cpan.org/CPAN/authors/id/S/SU/SULLR/IO-Socket-SSL-2.012.tar.gz
#tar zxvf IO-Socket-SSL-2.012.tar.gz
#cd IO-Socket-SSL-2.012
#../../bin/perl Makefile.PL
#make
#make install
#cd ..


After doing this, test that it works by doing

# /share/MD0_DATA/.qpkg/LogitechMediaServer/bin/perl
use IO::Socket::SSL;

That should not give any errors if everything was successful.

berrange
2015-03-08, 11:49
For the second problem, we need to edit /share/MD0_DATA/.qpkg/LogitechMediaServer/var/home/SqueezeboxServer/Cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm

At line 401 there is a regex whicih no longer matches, because youtube removed a single space character ! So at that line find

($vars{url_encoded_fmt_stream_map}) = ($http->content =~ /\"url_encoded_fmt_stream_map\": \"(.*?)\"/);

And change it to

($vars{url_encoded_fmt_stream_map}) = ($http->content =~ /\"url_encoded_fmt_stream_map\":\s*\"(.*?)\"/);

Notice, i'm changing ' ' to '\s*' near the end - that lets it match 0 or more whitespace characters

berrange
2015-03-08, 11:53
The third problem is the hard one that I've been unable to solve so far.

On all the videos I've tried, youtube is using a new signature method. Previously the code would look for a parameter 'sig=' and in the downloaded video page and turn that into 'signature=' when requesting the video stream. The current video pages don't include any 'sig=' parameter in the data for videos I've tried, instead providing a 's=' parameter. Unfortunately the content in this parameter appears to be obfuscated using an ever changing algorithm.

The youtube-dl program has support for unobfuscating this, but it relies on them actually interpreting the javascript code for the video player. This is non-trivial - someone is going to have to write a mini javascript interpretor for this the squeezebox youtube plugin to be able todo the same if we want that approach :-(

A second alternative is to make use of an online webservice for unobfuscating the signature. http://api.gitnol.com/ is one such webservice, but it requires that every user sign up to get their own API key for their IP address, so it isn't something that would "just work" out of the box - it'd require users to sign up themselves.

I've run out of time to investigate solving this problem myself, but maybe this info is useful to someone else who can solve what is hopefully the final piece of the puzzle...

buffettck
2015-03-08, 12:08
The third problem is the hard one that I've been unable to solve so far.

So, in other words, we're no better off than before. I do appreciate the effort, though! Hopefully, this can be made into one slick Youtube plugin like before.

berrange
2015-03-09, 05:47
So, in other words, we're no better off than before. I do appreciate the effort, though! Hopefully, this can be made into one slick Youtube plugin like before.

Having thought about the problem a little more, I think it might not actually be as hard to solve as I first feared. The youtube-dl python program has some reasonably straightforward code for interpreting the javascript unobfuscation code in the HTML5 player. It ought to be possible to port this code to Perl without undue pain. Next time I get some free time I'll attempt this and see if it gets us to a working solution....

berrange
2015-03-15, 14:31
Having thought about the problem a little more, I think it might not actually be as hard to solve as I first feared. The youtube-dl python program has some reasonably straightforward code for interpreting the javascript unobfuscation code in the HTML5 player. It ought to be possible to port this code to Perl without undue pain. Next time I get some free time I'll attempt this and see if it gets us to a working solution....

I've spent many hours hacking on the code today. I rewrote the youtube-dl python code for interpreting javascript in Perl, and have integrated it into the YouTube slimserver plugin code. So when we see an encrypted youtube stream signature we can evaluate the actual youtube javascript player code to decrypt (well unobfuscate) the signature. This lets us fetch the raw data stream once again !

I've successfully played a number of youtube streams by Blur and Creedence Clearwater Revival. Obviously not an exhaustive test, but it shows enough signs of life that this is worth sharing for others to try...

As mentioned in my previous posting, you need to install Mozilla::CA, Net::SSLeay and IO::Socket::SSL from CPAN so that the plugin can deal with https URLs from youtube. My ported signature code requires that you install the JSON module too. So in addition to the instructions in my previous post, also run this.

# cd /opt/ssods4/tmp
# wget http://search.cpan.org/CPAN/authors/id/M/MA/MAKAMAKA/JSON-2.90.tar.gz
# tar zxvf JSON-2.90.tar.gz
# cd JSON-2.90
# ../../bin/perl Makefile.PL
# make
# make install
# cd ..


I have bundled the updated plugin code into a zip file for convenience, and attached it to this posting, as well as uploading it to

https://www.berrange.com/~dan/YouTube-html5player-v0.16.zip

So, recapping

First, install the youtube plugin on your slimserver normally

Second, make sure you have Mozilla::CA, Net::SSLeay, IO::Socket::SSL and JSON modules installed from CPAN (see instructions above or README.txt in my ZIP file)

Third, copy the ProtocolHandler.pm, Signature.pm and JSInterp.pm files from my updated ZIP file into your slimserver plugin directory (/opt/ssods4/var/home/SqueezeboxServer/Cache/InstalledPlugins/Plugins/YouTube on my QNap NAS), replacing the original ProtocolHandler.pm that came with the youtube plugin


I hope this works for other people too - I'm very unlikely to have any time to further hack on this myself if further problems are found, so perhaps the original author who wrote the youtube plugin will see this message and be able to integrate the changes into their officially hosted plugin in some nicer manner.

SlimChances
2015-03-15, 19:59
So, recapping

First, install the youtube plugin on your slimserver normally




I hope this works for other people too - I'm very unlikely to have any time to further hack on this myself if further problems are found, so perhaps the original author who wrote the youtube plugin will see this message and be able to integrate the changes into their officially hosted plugin in some nicer manner.

Greatly appreciate your effort but I am finding it difficult to locate the correct directory to put the plugin for Ubuntu. According to the wiki the plugins are located here:

For Linux servers, the plugins directory is typically
/usr/share/squeezecenter/Plugins, /usr/local/squeezecenter/Plugins or /opt/squeezecenter/P

These directories are no longer named as such and the directory that appears to contain plugins now is /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins

berrange
2015-03-16, 03:32
These directories are no longer named as such and the directory that appears to contain plugins now is /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins

Yep, that sounds reasonable - basically just look for a subdirectory in /var/lib named "YouTube" that contains a Plugin.pm file and that'll be the right place.

SlimChances
2015-03-16, 06:20
Works fine as far as I can tell. Much faster at starting play than before also.
I have Ubunntu 14.04 and all that was required was to place the unzipped pluginn folder "YouTube" in /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins and then reboot the computer. All the other dependencies were already met


Not quite sure how this is done but it would be good if this new version could be added to the extension downloader as I suspect doing it manually it may disappear on an update

doubleugk
2015-03-16, 06:55
Thx for your work.


#OPENSSL_PREFIX=/opt ../../bin/perl Makefile.PL

I use LMS on a Debian squeezeplug and because I'm only a how2applier ;-) I wonder if "=/opt" is platform depending?

Cheers wgk

berrange
2015-03-16, 07:07
Thx for your work.

I use LMS on a Debian squeezeplug and because I'm only a how2applier ;-) I wonder if "=/opt" is platform depending?

Cheers wgk

My install notes were describing setup for a QNap NAS. On a regular Linux distro you should just install the packages provided by the OS distro as they'll certainly have all this stuff available already. eg apt-get install ....blah... for the perl modules in question.

doubleugk
2015-03-16, 09:21
I hope this works for other people too -

Many thx it worked out of the box for Debian Linux 2.6.38.8-squeezeplug on armv5tel.
I'm using Webmin, so it was an easy task to update the required CPAN moduls.
At the end I only had to update the existing files from the provided ZIP.

For Windows too :-))))))))) With ActivePerl 5.16.3 Build 1603 (64-bit) all required packages were available. Just copied the files from the archive into the plugin folder and I was done!

Great job - me & my kids are very happy about that!!!

tmp_t1
2015-03-18, 03:43
Great! On my debian arm installation it works again now.
Thank you very much for your effort according to my family :)

rhenwood
2015-03-18, 14:29
+1 works for me on CentOS6, and much appreciated!

paulster
2015-03-18, 15:03
This is great news, and fantastic work to get this up and running again.

Is anyone out there able to package this up into a revision to the plugin? Also, I noticed sometime back that the web interface wasn't displaying the YouTube logo any longer, because it was pointing to a defunct URL. It would be great to get this all packaged up so there was a one-stop solution.

t-force
2015-03-24, 10:55
Many thanks!!

Works fine now on my Windows Home Server 2011 installation.

udovdh
2015-03-28, 06:07
Thanks for the plugin.
How to debug?
In upgraded to 7.8.1. nightly from 7.8.0.
In took the files from the plugin zip as explained but no sound yet.
Where can I see what goes wrong?
Or how can I check?
server.log doesn't really show much...

Hmm. I found it does this:

[root@.. YouTube]# perl ./Plugin.pm
Bareword "main::SLIM_SERVICE" not allowed while "strict subs" in use at /usr/lib64/perl5/vendor_perl/Slim/Utils/OSDetect.pm line 130.
Compilation failed in require at /usr/lib64/perl5/vendor_perl/Slim/Utils/Log.pm line 48.
BEGIN failed--compilation aborted at /usr/lib64/perl5/vendor_perl/Slim/Utils/Log.pm line 48.
Compilation failed in require at /usr/lib64/perl5/vendor_perl/Slim/Utils/Strings.pm line 52.
BEGIN failed--compilation aborted at /usr/lib64/perl5/vendor_perl/Slim/Utils/Strings.pm line 52.
Compilation failed in require at ./Plugin.pm line 16.
BEGIN failed--compilation aborted at ./Plugin.pm line 16.

How to fix?

jspamc
2015-03-29, 07:01
Many thanks!!

Works fine now on my Windows Home Server 2011 installation.

Could you post instructions on how to get this working in LMS running under Windows?

Thank you!

505
2015-04-04, 11:17
To keep track of all the changes to this plugin, I decided to set up a GitHub repo (https://github.com/danielvijge/squeezebox-youtube). I am trying to do the same thing as I did for the SoundClound plugin.

I forked the newest repo I could find on GitHub. This contained v0.11 - v0.14. I then imported v0.15 and v0.16. On top of that I applied the HTML5 fix by berrange and some other smaller fixes. This is now known as v0.17.

You can automatically update by adding the third party repository to LMS: http://danielvijge.github.io/squeezebox-youtube/public.xml
If a few people can test if everything works (or at least better than the current version), I can add this to my general repo file, so it will be automatically available to all LMS users (without having to add the third party repo link).

Of course everyone is welcome to fork this repo. Or to submit pull requests, and I'll release a new version.

pippin
2015-04-04, 13:36
Good idea. Please let me know when you consider it stable (will try it myself, too), then I'll take town the 0.16 repo I'm currently hosting.

pippin
2015-04-04, 21:28
Hm, I only get "plugin failed to load".
This is OSX, do I need to install anything besides the plugin?

505
2015-04-06, 08:51
Hm, I only get "plugin failed to load".
This is OSX, do I need to install anything besides the plugin?

Yes, berrage added one extra dependency: JSON. On Debian I could do "sudo apt-get install libjson-perl". On OSX, it's probably "sudo cpan JSON"
It's only used for the from_json() function, and only once, so I'll have to see if I can replace it by something without a dependency.

mherger
2015-04-06, 14:16
> Yes, berrage added one extra dependency: JSON. On Debian I could do
> "sudo apt-get install libjson-perl". On OSX, it's probably "sudo cpan
> JSON"

He should change that to "use JSON::XS::VersionOneAndTwo;" instead. LMS
comes with all required modules. No need to load more than one JSON
interpreting module, in particular when the faster version already is
installed.

--

Michael

alnames
2015-04-19, 13:29
Yes, berrage added one extra dependency: JSON. On Debian I could do "sudo apt-get install libjson-perl". On OSX, it's probably "sudo cpan JSON"
It's only used for the from_json() function, and only once, so I'll have to see if I can replace it by something without a dependency.

This worked for me on a Raspberry Pi2 running Max2play with one exception. I was still getting SSL errors and had to install Perl SSL support as per an earlier suggestion by "caalami".

After running "apt-get install libio-socket-ssl-perl" it's now working for me.

Thanks to caalami, berrage, 505, and of course Triode.

jaysung
2015-04-22, 04:50
Hello,
I want to thank all you contributed for theier work.
I can Play individual Songs on YouTube after installing all dependencies that Berrange listed.
However playlists do not seem to work.
I post the log file below:
2015-04-22 11:46:33 squeezeboxserver_safe stopped.
2015-04-22 11:46:33 squeezeboxserver_safe started.
[15-04-22 11:46:34.5790] main::init (354) Starting Logitech Media Server (v7.7.3, 1374126491, Tue Jul 30 00:58:39 PDT 2013) perl 5.014002
[15-04-22 11:46:34.9436] Slim::Utils::Misc::msg (1304) Warning: [11:46:34.9434] defined(@array) is deprecated at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/CDplayer/CDPLAY.pm line 481.
[15-04-22 11:46:34.9438] Slim::Utils::Misc::msg (1304) Warning: [11:46:34.9437] (Maybe you should just omit the defined()?)
[15-04-22 12:03:25.3779] Slim::Networking::IO::Select::__ANON__ (147) Error: Select task failed calling Slim::Web::HTTP::sendStreamingResponse: substr outside of string at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 199.
; fh=Slim::Web::HTTP::ClientConn=GLOB(0xb1efd98)
[15-04-22 12:40:05.3572] Slim::Networking::IO::Select::__ANON__ (147) Error: Select task failed calling Slim::Web::HTTP::sendStreamingResponse: substr outside of string at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 199.
; fh=Slim::Web::HTTP::ClientConn=GLOB(0xce47fc0)

Anyone who is better at perl than me might help.
Thanks
Jeronimo

doubleugk
2015-05-09, 18:21
I just realized, that even with the new changes I can't play YouTube anymore. I get the error message http:/youtube.com/devicesupport.
On this page YouTube informs about a change of the API on April 20th. Hence we need again support from someone who's able to implement the new API support.
Anybody out there?

gegen
2015-05-10, 00:20
I just realized, that even with the new changes I can't play YouTube anymore. I get the error message http:/youtube.com/devicesupport.
On this page YouTube informs about a change of the API on April 20th. Hence we need again support from someone who's able to implement the new API support.
Anybody out there?

+1 here......and just when it was all working so well!! :(

pascal!
2015-05-18, 06:08
So, recapping

First, install the youtube plugin on your slimserver normally

Second, make sure you have Mozilla::CA, Net::SSLeay, IO::Socket::SSL and JSON modules installed from CPAN (see instructions above or README.txt in my ZIP file)

Third, copy the ProtocolHandler.pm, Signature.pm and JSInterp.pm files from my updated ZIP file into your slimserver plugin directory (/opt/ssods4/var/home/SqueezeboxServer/Cache/InstalledPlugins/Plugins/YouTube on my QNap NAS), replacing the original ProtocolHandler.pm that came with the youtube plugin

I hope this works for other people too - I'm very unlikely to have any time to further hack on this myself if further problems are found, so perhaps the original author who wrote the youtube plugin will see this message and be able to integrate the changes into their officially hosted plugin in some nicer manner.[/QUOTE]

----------------------------
Thank you berrange and everybody for all of this

I have LMS on win7 and I don't understand how to install and fix this youtube pluging on it :(
Could somebody translate this Linux installation into a Win7 installation?

For instance: Mozilla::CA, Net::SSLeay, IO::Socket::SSL and JSON modules installed from CPAN => how to check or do?

doubleugk
2015-05-18, 07:03
I don't understand how to install and fix this youtube pluging on it :( ... how to check or do?

For the time being: Don't spend any effort on this, because the plugin won't work. Google changed the API and this has to be fix by someone.

Cheers wgk

505
2015-05-19, 13:56
Not sure how easy it is to migrate to YouTube APIv3, but I'll try to take a look at it. As always, any help is welcome through the GitHub repository.

For those that have the GitHub repo XML installed, you'll get an update message for the plugin. It will still not work. It is just there to remove the dependency on JSON (to remove any startup errors for LMS), and to add a warning that the plugin is broken.

pippin
2015-05-19, 18:32
But that's a good start (fixing the JSON dependency) :)

alexhurst
2015-05-22, 03:23
I am only a user of the youtube plug in... I use it on logitech media server... windows 7.

I don't have the knowledge or know-how to use PERL...

was hoping if anyone could talk me through how to get it working again?

thanks

505
2015-05-24, 03:58
I am only a user of the youtube plug in... I use it on logitech media server... windows 7.

I don't have the knowledge or know-how to use PERL...

was hoping if anyone could talk me through how to get it working again?

thanks

You can't get it working. Unless you rewrite it to use the YouTube APIv3. And no one has done that (yet).

HeadBanger
2015-06-07, 10:47
+1 for another that hopes that this great app gets fixed soon :(

tmp_t1
2015-06-17, 01:52
I now get a http statuscode 410: gone when trying a search on youtube.
Playing movies from the list recently played still works.
Is only the search api updated?

philippe_44
2015-07-11, 15:20
I had a question here for this plugin

http://forums.slimdevices.com/showthread.php?103915-play-Youtube-links&p=823869&viewfull=1#post823869

philippe_44
2015-08-29, 01:47
Hi - I've been able, with some great help, to update the YouTube plugin to the API v3. It is very preliminary and I've only tested on my Windows box. No install yet, just need to copy the files with the other plugins (I'll do one later). You need a YouTube API key to be generated (takes 5 min on google) or somebody to donate his key to the community.

Again, it is very alpha now and I won't have a lot of time for improvment in the coming days, so try at your risk, it might even crash your LMS. Code is in GitHub with the rest

18689

SlimChances
2015-08-29, 05:25
Hi - I've been able, with some great help, to update the YouTube plugin to the API v3. It is very preliminary and I've only tested on my Windows box. No install yet, just need to copy the files with the other plugins (I'll do one later). You need a YouTube API key to be generated (takes 5 min on google) or somebody to donate his key to the community.

Again, it is very alpha now and I won't have a lot of time for improvment in the coming days, so try at your risk, it might even crash your LMS. Code is in GitHub with the rest

18689


That's great progress. I tested it on my Linux PC and unfortunately it had some issues.
I had to change permissions in the plugin folder to activate the plugin, but once I did that PLUGIN_YOUTUBE appears in the main menu.
When I click on it from the Web IF it gives me the usual search options but they are not labelled. If I use the search I get 404 error.
I guess this is because I have not activated the YouTube API key but I am not sure how to do that.

philippe_44
2015-08-29, 10:12
That's great progress. I tested it on my Linux PC and unfortunately it had some issues.
I had to change permissions in the plugin folder to activate the plugin, but once I did that PLUGIN_YOUTUBE appears in the main menu.
When I click on it from the Web IF it gives me the usual search options but they are not labelled. If I use the search I get 404 error.
I guess this is because I have not activated the YouTube API key but I am not sure how to do that.

Ah ... this is usual dos / unix file conversion CR/LF ... Here is an updated strings.txt file to replace the existing one. Seems also that the Perl JSON module is not available on all platform, you'd need to add it (but if it starts, it means it is her on your plaform).

18696

For the YouTube APIkey, you have to go there https://console.developers.google.com/project, create a project, say you want to use YouTube data API and then follow the instruction to create identifier (a key). I know this is complicated and I'll see if there is way to get an "anonymous" key that can be shared. I think the amount of requests will be low enough so that it passes the criterias

pippin
2015-08-29, 10:24
If the JSON module is not available you are using the wrong one, LMS ships with one. Check what other plugins or LMS use

SlimChances
2015-08-29, 11:46
For the YouTube APIkey, you have to go there https://console.developers.google.com/project, create a project, say you want to use YouTube data API and then follow the instruction to create identifier (a key). I know this is complicated and I'll see if there is way to get an "anonymous" key that can be shared. I think the amount of requests will be low enough so that it passes the criterias

I have had a few tries at this and also tried following the directions at the google site to no avail. I get stuck at (see Screenshot)

philippe_44
2015-08-29, 12:20
I have had a few tries at this and also tried following the directions at the google site to no avail. I get stuck at (see Screenshot)

Create a browser key

SlimChances
2015-08-29, 13:26
Create a browser key

Thanks. I know this is another dumb question but how do I create the key? For example I tried http://127.0.0.1:9000/ as a guess but did not work

philippe_44
2015-08-29, 13:29
Thanks. I know this is another dumb question but how do I create the key? For example I tried http://127.0.0.1:9000/ as a guess but did not work

No worries - Just click on 'create browser key' on the Google site and it will create a key that you can then copy / paste. No need to do anything special on your PC

philippe_44
2015-08-29, 14:11
Changes strings.txt and JSON

18702

SlimChances
2015-08-29, 16:34
Philippe I am certainly grateful for your assistance and the work you have put into this. However In a search for music it will only play the first stream in the list of music it finds and more often than not will say "No Streams" for the track and not play at all. However this is a good step towards restoring the plugin again. Unless of course I have missed something. I have installed the latest set of files you posted

philippe_44
2015-08-29, 17:19
Thanks - well, that was just the ground work to move to json and https for streaming. This fits my own need but if there is interest, I can see how to enhance it. Did you use the previous version ? I think the management of tracks in streams was already complicated. There is a lot of parsing needed to analyze the content of the flv's and this is new to me, so not an easy job anyway

SlimChances
2015-08-29, 17:21
Thanks - well, that was just the ground work to move to json and https for streaming. This fits my own need but if there is interest, I can see how to enhance it. Did you use the previous version ? I think the management of tracks in streams was already complicated. There is a lot of parsing needed to analyze the content of the flv's and this is new to me, so not an easy job anyway

I did use the previous version and had similar results until it did not work at all

philippe_44
2015-08-29, 17:24
That's what I thought but I was not sure as I did not use the previous one. I will fix today the duration of track which is just parsing a iso8601 date and other than that, it will probably be a longer journey :) that will depend how many want to see this, to be honest

SlimChances
2015-08-29, 17:34
Thanks

philippe_44
2015-08-29, 22:31
Added duration and now available in sourceforge repository, but still need to install manually

https://sourceforge.net/projects/lms-youtube/files/

philippe_44
2015-08-31, 23:05
I've now a decent version of the plugin with API v3. Music search, Channels, and playlist are working with a number of searched items configurable. You still need an API key (goto https://console.developers.google.com/start) and choose a web key for YouTube API.

Favorite, Top Rated and Most Popular don't work yet. There is some refinement with iPeng that I've not studied yet

CrankyTom
2015-09-01, 09:03
Hi philippe_44, thanks for the effort on this, noob question how do I manually add your plugin to my LMS so I can test it? Thanks :D

Logitech Media Server Version: 7.7.5
Operating system: Windows 8
Perl Version: 5.14.1
Database Version: DBD::SQLite 1.34_01 (sqlite 3.7.7.1)

philippe_44
2015-09-01, 15:08
Hi philippe_44, thanks for the effort on this, noob question how do I manually add your plugin to my LMS so I can test it? Thanks :D

Logitech Media Server Version: 7.7.5
Operating system: Windows 8
Perl Version: 5.14.1
Database Version: DBD::SQLite 1.34_01 (sqlite 3.7.7.1)

On Windows, the hacky way is to copy the content of the zip file into C:\ProgramData\Squeezebox\Cache\InstalledPlugins\P lugins\YouTube and restart LMS. Remember to get a API key at https://console.developers.google.com/start. Choose a web key when asked

CrankyTom
2015-09-01, 23:15
Thanks philippe_44, got it working. Currently using YouTube-0.21.zip.

SlimChances
2015-09-02, 06:57
philippe
Version 2.1 is a good improvement on 2.0 as now with a search all the results are playable (if a stream exists) whereas before only the top selection played,
One thing though is the labels for the search bars has disappeared again (at least in Linux), see screenshot
Can I just replace the strings.txt with the one you had in post 366?

SlimChances
2015-09-02, 07:11
Replacing the strings.txt file worked
Thanks

philippe_44
2015-09-02, 08:10
Replacing the strings.txt file worked
Thanks

There is also a 2.2

[edit]: sorry I meant 0.23. The mistake was again a DOS format of the file. Corrected for good I hope

gegen
2015-09-02, 14:50
Hi Phillipe,

Thanks for all your work on this!! I've missed having this plugin!!

I'm running LMS 7.9 on an RPi2 using a Squeezeplug setup which is using Ubuntu 13.10.

I've copied the files from your 0.23 zip into the existing YouTube plugin folder
and the Plugin appears in 'My Apps' with the menu items showing,
it also appears as Version 0.2 in the Active Plugins section on the LMS Web settings page.

If I search from any of the search menus though, I get '400 Bad Request' .....but interestingly a couple of items in the 'Recently Played' list do play fine! (although without artwork).

I did generate an API key but wasn't sure if I then had to put it somewhere....... sorry about that, might this be causing the '400 Bad Request' problem do you think?

Any help would be much appreciated!

philippe_44
2015-09-02, 14:53
Hi Phillipe,

Thanks for all your work on this!! I've missed having this plugin!!

I'm running LMS 7.9 on an RPi2 using a Squeezeplug setup which is using Ubuntu 13.10.

I've copied the files from your 0.23 zip into the existing YouTube plugin folder
and the Plugin appears in 'My Apps' with the menu items showing,
it also appears as Version 0.2 in the Active Plugins section on the LMS Web settings page.

If I search from any of the search menus though, I get '400 Bad Request' .....but interestingly a couple of items in the 'Recently Played' list do play fine! (although without artwork).

I did generate an API key but wasn't sure if I then had to put it somewhere....... sorry about that, might this be causing the '400 Bad Request' problem do you think?

Any help would be much appreciated!

The lack of key is the reason for the 400 bad request. Go to LMS 'settings', 'advanced', select 'YouTube' and then you can enter the key

gegen
2015-09-02, 15:12
The lack of key is the reason for the 400 bad request. Go to LMS 'settings', 'advanced', select 'YouTube' and then you can enter the key

Thankyou very much that did it! I thought I had checked the 'Advanced Settings" page in LMS but obviously not!
Sorry to have wasted your time ........but thanks again for the help and the plugin being back!!!

gegen
2015-09-02, 16:47
Hi Phillipe

Have now installed your fixes on another LMS setup and all working great......I have noticed though that LMS tells me 'Plugin Updates are available (Youtube)' and on the LMS web plugins page it shows me an update to Version 0.18, is that something you're seeing?

gegen
2015-09-02, 16:59
Is it something to do with having some old repositorys installed in the Plugins web page?

philippe_44
2015-09-02, 17:44
Yes, there is a mistery with that that I've not solved yet :(. I have set a repository and probably for a similar reason, the install does not work (this is not my 1st plugin so I'm pretty sure that my repository is correct), hence you need to do the manual installation. Michael, would you know what happens ?

gegen
2015-09-02, 17:48
Yes, there is a mistery with that that I've not solved yet :(. I have set a repository and probably for a similar reason, the install does not work (this is not my 1st plugin so I'm pretty sure that my repository is correct), hence you need to do the manual installation. Michael, would you know what happens ?

OK I'll not touch anything...it's working so that's great!!!!!

mherger
2015-09-02, 21:29
> Yes, there is a mistery with that that I've not solved yet :(. I have
> set a repository and probably for a similar reason, the install does not
> work (this is not my 1st plugin so I'm pretty sure that my repository is
> correct), hence you need to do the manual installation. Michael, would
> you know what happens ?

I'll try to look into your issues. But I can't find a repository file.
If you had been using the original Youtube plugin from a repository,
then you'll have to uninstall it before installing yours manually.
Otherwise there will be some confusion...

--

Michael

philippe_44
2015-09-02, 23:41
> Yes, there is a mistery with that that I've not solved yet :(. I have
> set a repository and probably for a similar reason, the install does not
> work (this is not my 1st plugin so I'm pretty sure that my repository is
> correct), hence you need to do the manual installation. Michael, would
> you know what happens ?

I'll try to look into your issues. But I can't find a repository file.
If you had been using the original Youtube plugin from a repository,
then you'll have to uninstall it before installing yours manually.
Otherwise there will be some confusion...

--

Michael

Thanks Michael - The problem seems to be that there is a YouTube repository in the 3rd party plugins and when I try to add my own repository, it does not seem to superseed the 3rd party one (which is _not_ selected/installed) when refreshing the plugin list

Steiny
2015-09-03, 00:23
Hi Phillipe,

thank you so much for your hard work to fix this great plugin.
Currently i run Youtube-Plugin with LMS 7.9 (Repack) on my Synology DS213 NAS and use 2 RPI's (piCorePlayer) as players.

Steiny

Steiny
2015-09-03, 02:45
There is one thing I noticed:

I did the Plugin Installation in LMS threw WEB UI and repository URL: http://sourceforge.net/projects/lms-youtube/files/dev/repo-sf.xml
After Installation there is message that a Plugin Update to 0.23 is availiable which also persists even when i perform the update.
I take a look in Youtube-023.zip/install.xml and see there is still version 0.2 specified. After i changed Version to 0.23 in LMS-PluginDirectory/YouTube/install.xml the message was gone.

mherger
2015-09-03, 02:49
> version 0.2 specified. After i changed Version to 0.23 in
> LMS-PluginDirectory/install.xml the message was gone.

Yep, happened to me, too.

--

Michael

philippe_44
2015-09-03, 03:00
> version 0.2 specified. After i changed Version to 0.23 in
> LMS-PluginDirectory/install.xml the message was gone.

Yep, happened to me, too.

--

Michael

Thanks for noticing that - was an error in my packaging script. Correct now

Steiny
2015-09-03, 03:36
Thanks for noticing that - was an error in my packaging script. Correct now

Thx!

to see which customizations were done it would be great if you could provide a short Change-Log after each new Version.

+1 more for your time and effort in that matter!! ;-)

CrankyTom
2015-09-03, 04:20
Thanks for noticing that - was an error in my packaging script. Correct now

Updated to YouTube (v0.24), everything working great so far, thanks philippe_44.

mherger
2015-09-03, 06:58
> Thanks Michael - The problem seems to be that there is a YouTube
> repository in the 3rd party plugins and when I try to add my own
> repository, it does not seem to superseed the 3rd party one (which is
> _not_ selected/installed)

Yeah, that's a problem. You'd either have to take complete ownership of
the plugin and we'll replace the old one, or you create a new UUID for
yours.

--

Michael

pippin
2015-09-03, 07:10
Is there any sense in keeping the old, dysfunctional one around?

mherger
2015-09-03, 07:42
Is there any sense in keeping the old, dysfunctional one around?

I guess the answer is "No".

mherger
2015-09-03, 07:46
philippe_44 - how would you like to get modifications? When looking at the code I feel a strong urge to remove some of the legacy code... There's code in there which was supposed to deal with older LMS versions. But as you define 7.7 as the minimum in the install.xml manifest this is no longer needed.

18746 - that's a diff against 0.24.

And here are a few lines which would tidy up the category list (order alphabetically, get rid of duplicates - to be applied around line 295 in Plugin.pm):


my %seen;
$menu = [
sort {
uc($a->{name}) cmp uc($b->{name})
} grep {
!$seen{$_->{passthrough}->[2]}++
} @$menu
];


It does the de-duplication based on the url snippet (which is stored as the third passthrough parameter). I don't know whether this is working as expected in cases other than the category search. Maybe it should be moved to the categories parser instead.

philippe_44
2015-09-03, 07:56
You're totally correct, there is a need for tiding up the code. I'm just getting my arms around some of it and sometimes I have duplicated function to get things working easily. Same for 7.6 support. The SSL gave me a hard time and I still have that 2-levels menu problem that I cannot get to work ... so a lot to do

philippe_44
2015-09-03, 10:03
And here are a few lines which would tidy up the category list (order alphabetically, get rid of duplicates - to be applied around line 295 in Plugin.pm):


my %seen;
$menu = [
sort {
uc($a->{name}) cmp uc($b->{name})
} grep {
!$seen{$_->{passthrough}->[2]}++
} @$menu
];


It does the de-duplication based on the url snippet (which is stored as the third passthrough parameter). I don't know whether this is working as expected in cases other than the category search. Maybe it should be moved to the categories parser instead.

Thanks Michael - I think there is a problem that is linked to the question I asked in developer section if I sort the menu:

1- At the toplevel, LMS makes a 1st query for 20 items, index 0
2- I grab a YouTube search for 50 items (I have forced paging to deal with item 5-)
3- I fill the $menu structure with up to 20 items where for each of them {url}, {type} and {passtrhough} are set
4- User selects an item, say 10th,
5- LMS sends again the same toplevel query search and asks for only 1 item, index 9 - huh ?
6- My previous menu context is then lost *and* in YouTube API v3, there is *no* direct indexing of items, so all can do is grab again (with cache soon, thank you) the same YouTube search and return only one menu item that is the 10th element.
7- Then, and only then, LMS executes what has been set in the one-item-menu context using {url} and {passtrhough}

So if I re-order menu items, I'm stuck, I think as the menu index does not match anymore the youtube search index and my stop criteria that are based on such matching are wrong. I'm not saying this is impossible, but all this paging thing is done. That was different in API v2 as you could do direct indexing as search result and ask for item n1 N directly

What would be great is that LMS would simply execute what has been set in 10th menu item context and do not do steps 5 (and force me to do 6)

philippe_44
2015-09-03, 12:46
I've re-integrated signature management that I initially forgot to include in version 0.25 so more file should play, added Michael's cleaning to remove legacy (https://sourceforge.net/projects/lms-youtube/files/dev) and ... a changelog.

You still need to press 'next' 90% of times to have the track to actually play, I'll look into that later

SlimChances
2015-09-03, 13:14
I've re-integrated signature management that I initially forgot to include in version 0.25 so more file should play, added Michael's cleaning to remove legacy (https://sourceforge.net/projects/lms-youtube/files/dev) and ... a changelog.

You still need to press 'next' 90% of times to have the track to actually play, I'll look into that later

Not noticing the "No Streams Available" any more, seems to be working very well

CrankyTom
2015-09-03, 13:26
0.25 also working well here. no issues.

gegen
2015-09-03, 15:05
I've re-integrated signature management that I initially forgot to include in version 0.25 so more file should play, added Michael's cleaning to remove legacy (https://sourceforge.net/projects/lms-youtube/files/dev) and ... a changelog.

You still need to press 'next' 90% of times to have the track to actually play, I'll look into that later

All working fine, no issues on OdroidU3 Ubuntu10.3 LMS 7.9 ....... thanks a lot.

Also on RPi2 Raspbian 7 (wheezy) LMS 7.9

Herman1234
2015-09-03, 15:06
Hi,
i really appreciate you guys for bringing this plugin back to life. :)
I got my center (7.9.0) running in a vmware (ubuntu server), installed 0.25 and all packages in this forum (even all CPAN sockets), filled the API. The plugin seems to play the songs but there is no sound... Log error:
[15-09-03 23:38:05.2717] Slim::Networking::IO::Select::__ANON__ (131) Error: Select task failed calling Slim::Networking::Async::HTTP::_http_read_body: SSL_verify_mode must be a number and not a string at /usr/local/share/perl/5.18.2/IO/Socket/SSL.pm line 2130. ; fh=Slim::Networking::Async::Socket::HTTPS=GLOB(0x9 86d658)
What did i miss? its driving me crazy..
thx for your help.
greetings,
Herman

castalla
2015-09-03, 15:50
Just getting a 0.25 failed to load now - was working with 0.24

philippe_44
2015-09-03, 15:56
Just getting a 0.25 failed to load now - was working with 0.24

What do you have in the server log ?

philippe_44
2015-09-03, 15:58
Hi,
i really appreciate you guys for bringing this plugin back to life. :)
I got my center (7.9.0) running in a vmware (ubuntu server), installed 0.25 and all packages in this forum (even all CPAN sockets), filled the API. The plugin seems to play the songs but there is no sound... Log error:
[15-09-03 23:38:05.2717] Slim::Networking::IO::Select::__ANON__ (131) Error: Select task failed calling Slim::Networking::Async::HTTP::_http_read_body: SSL_verify_mode must be a number and not a string at /usr/local/share/perl/5.18.2/IO/Socket/SSL.pm line 2130. ; fh=Slim::Networking::Async::Socket::HTTPS=GLOB(0x9 86d658)
What did i miss? its driving me crazy..
thx for your help.
greetings,
Herman

What kind of Linux do you have ?

castalla
2015-09-03, 16:03
What do you have in the server log ?

Something lke this?


[15-09-03 23:37:33.1487] Slim::bootstrap::tryModuleLoad (286) Warning: Module [Plugins::YouTube::Plugin] failed to load:
Can't locate JSON.pm in @INC (you may need to install the JSON module) (@INC contains: /var/lib/squeezeboxserver/cache/InstalledPlugins /usr/share/squeezeboxserver/CPAN/arch/5.18/i386-linux-thread-multi-64int /usr/share/squeezeboxserver/CPAN/arch/5.18/i386-linux-thread-multi-64int/auto /usr/share/squeezeboxserver/CPAN/arch/5.18.2/i686-linux-gnu-thread-multi-64int /usr/share/squeezeboxserver/CPAN/arch/5.18.2/i686-linux-gnu-thread-multi-64int/auto /usr/share/squeezeboxserver/CPAN/arch/5.18/i686-linux-gnu-thread-multi-64int /usr/share/squeezeboxserver/CPAN/arch/5.18/i686-linux-gnu-thread-multi-64int/auto /usr/share/squeezeboxserver/CPAN/arch/i686-linux-gnu-thread-multi-64int /usr/share/squeezeboxserver/CPAN/arch/5.18 /usr/share/squeezeboxserver/lib /usr/share/squeezeboxserver/CPAN /usr/share/squeezeboxserver /usr/share/squeezeboxserver/CPAN /usr/share/squeezeboxserver /usr/sbin /etc/perl /usr/local/lib/perl/5.18.2 /usr/local/share/perl/5.18.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.18 /usr/share/perl/5.18 /usr/local/lib/site_perl .) at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/JSInterp.pm line 21.
BEGIN failed--compilation aborted at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/JSInterp.pm line 21.
Compilation failed in require at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/Signature.pm line 15.
BEGIN failed--compilation aborted at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/Signature.pm line 15.
Compilation failed in require at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 18.
BEGIN failed--compilation aborted at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 18.
Compilation failed in require at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/Plugin.pm line 20.
BEGIN failed--compilation aborted at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/Plugin.pm line 20.
Compilation failed in require at (eval 1089) line 1.
BEGIN failed--compilation aborted at (eval 1089) line 1.

philippe_44
2015-09-03, 16:29
Something lke this?

Yes - I added back the possibility to decode signed videos and it seems that some Linux platform where missing some Perl libraries. You can try 0.26 now

2string1
2015-09-03, 17:08
Sorry what does all this mean?
<?xml version="1.0" standalone="true"?>

-<extensions>


-<details>

<title lang="EN">Philippe's squeezecenter plugins</title>

</details>


-<plugins>


-<plugin version="0.26" name="YouTube" maxTarget="7.*" minTarget="7.7">

<title lang="EN">YouTube</title>

<url>http://sourceforge.net/projects/lms-youtube/files/dev/YouTube-0.26.zip</url>

<link>http://sourceforge.net/projects/lms-youtube</link>

<email>philippe_44@outlook.com</email>

<sha>83ee9353acb0e433a348ffdba850e9d8e532248c</sha>

<creator>Triode + Philippe for API v3</creator>

<desc lang="EN">Play YouTube video</desc>

</plugin>

</plugins>

</extensions>

philippe_44
2015-09-03, 19:52
Sorry what does all this mean?
<?xml version="1.0" standalone="true"?>
...
</extensions>

This is the file needed for automatic installation (you enter that url http://sourceforge.net/projects/lms-youtube/files/dev/repo-sf.xml in the "settings", "plugin" page of LMS). As of today, there is probably a conflict on auto install with the old plugin, you need to download the latest zip file found here http://sourceforge.net/projects/lms-youtube/files/dev and manually unzip it on your computer. Usually C:\Program Files (x86)\Squeezebox\server\Plugins for Windows and /var/lib/squeezeboxserver/Plugins for Linux

philippe_44
2015-09-03, 20:46
I guess the answer is "No".

Should the old one still work I'd be hesitant, but knowing that it does not any more, things can't be worse if I try to take care of it :)

pippin
2015-09-03, 22:29
I noticed you changed the menu id of the plugin's top-level menu. Can you tell me what the new id is?
Edit: forget it, isn't changed.

castalla
2015-09-04, 00:08
Yes - I added back the possibility to decode signed videos and it seems that some Linux platform where missing some Perl libraries. You can try 0.26 now

Fixed - works! Thanks.

gegen
2015-09-04, 02:56
Hi all, does anyone know a way of clearing the recently played list?

2string1
2015-09-04, 05:27
Sorry I don't understand computers and all this plugin stuff. Can someone explain in laymen terms what I should do to get this plugin to work? Thanks

CrankyTom
2015-09-04, 07:26
Sorry I don't understand computers and all this plugin stuff. Can someone explain in laymen terms what I should do to get this plugin to work? Thanks

What OS are you running your LMS on?

SlimChances
2015-09-04, 07:55
I tried putting a mixed playlist together with YouTube tracks and tracks from my own library and it worked. This has not worked for a long time with the old plugin.

Thanks Philippe

mherger
2015-09-04, 08:10
> Is there any sense in keeping the old, dysfunctional one around?

Oh, is this yours? I just noticed the old one was pointing to your
repository. Please pull it :-).

--

Michael

Herman1234
2015-09-04, 08:25
What kind of Linux do you have ?
Ubuntu server 14.04.3 LTS
uname -a:
Linux squeezeboxserver 3.19.0-26-generic #28~14.04.1-Ubuntu SMP Wed Aug 12 14:09:17 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

Unzipped/overwrote files with plugin 0.26. Still gives no sound, log-error when playing a stream is still the same:
[15-09-04 17:03:54.4855] Slim::Networking::IO::Select::__ANON__ (131) Error: Select task failed calling Slim::Networking::Async::HTTP::_http_read_body: SSL_verify_mode must be a number and not a string at /usr/local/share/perl/5.18.2/IO/Socket/SSL.pm line 2130. ; fh=Slim::Networking::Async::Socket::HTTPS=GLOB(0x8 0dcde8)

all test within CPAN shell worked, what does "SSL_verify_mode must be a number and not a string" mean? :confused:
thx!

2string1
2015-09-04, 09:59
What OS are you running your LMS on?

Win 10

philippe_44
2015-09-04, 10:06
Ubuntu server 14.04.3 LTS
uname -a:
Linux squeezeboxserver 3.19.0-26-generic #28~14.04.1-Ubuntu SMP Wed Aug 12 14:09:17 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

Unzipped/overwrote files with plugin 0.26. Still gives no sound, log-error when playing a stream is still the same:
[15-09-04 17:03:54.4855] Slim::Networking::IO::Select::__ANON__ (131) Error: Select task failed calling Slim::Networking::Async::HTTP::_http_read_body: SSL_verify_mode must be a number and not a string at /usr/local/share/perl/5.18.2/IO/Socket/SSL.pm line 2130. ; fh=Slim::Networking::Async::Socket::HTTPS=GLOB(0x8 0dcde8)

all test within CPAN shell worked, what does "SSL_verify_mode must be a number and not a string" mean? :confused:
thx!

oh I see, sorry. Can you open file "ProtocolHandler.pm" go to line 73 and simply remove it ? It was an early try/mistake that should have been removed, my bad

Herman1234
2015-09-04, 10:26
oh I see, sorry. Can you open file "ProtocolHandler.pm" go to line 73 and simply remove it ? It was an early try/mistake that should have been removed, my bad

Bingo! you solved another mystery philippe! :)
removing the line "SSL_verify_mode => 'SSL_VERIFY_NONE'," worked!
I can sleep now :)
thx!

badboygolf16v
2015-09-04, 13:07
I've installed the plugin from the repo and I'm getting the following message:

[15-09-04 21:02:53.8337] Plugins::YouTube::Plugin::__ANON__ (305) error: 403 Forbidden

I've tried using a YouTube Data API Server key and also a Browser key (couldn't find a Web option) but no joy.

Any help appreciated!

Thanks

philippe_44
2015-09-04, 18:53
With the advices of 'magic' Michael, the redirection is now working, no need to press 'next' to get playback starting. Use version 0.27

philippe_44
2015-09-04, 19:04
I've installed the plugin from the repo and I'm getting the following message:

[15-09-04 21:02:53.8337] Plugins::YouTube::Plugin::__ANON__ (305) error: 403 Forbidden

I've tried using a YouTube Data API Server key and also a Browser key (couldn't find a Web option) but no joy.

Any help appreciated!

Thanks

Can you add a bit more of your server.log ? Maybe as well enable the debug level in YouTube plugin (settings, advanced, logging) ?

badboygolf16v
2015-09-05, 03:16
Can you add a bit more of your server.log ? Maybe as well enable the debug level in YouTube plugin (settings, advanced, logging) ?

Hi Phillipe

The version has updated to 0.27 today. I've updated the log level to Debug. When restarting the server I get this message:


[15-09-04 21:00:34.8281] Slim::Utils::Misc::msg (1220) Warning: [21:00:34.8267] Async::HTTP: Unable to load IO::Socket::SSL, will try connecting to SSL servers in non-SSL mode

The plugin Debug log is:


[15-09-05 11:11:47.9428] Plugins::YouTube::Plugin::searchHandler (215) search: q=, feed: videoCategories, parser :CODE(0x5f91368), term:
$VAR1 = {
'quantity' => 50,
'library_id' => undef,
'wantMetadata' => 1,
'isWeb' => 1,
'index' => undef,
'wantIndex' => 1,
'search' => undef,
'params' => undef
};
[15-09-05 11:11:47.9455] Plugins::YouTube::Plugin::__ANON__ (249) fetching: https://www.googleapis.com/youtube/v3/videoCategories?regionCode=us&pageToken=&maxResults=50&v=2&alt=json&part=id,snippet&key=AIzaSyACo5YVGcvbtFnicz-O0980chA36Hp6rpE
[15-09-05 11:11:47.9477] Plugins::YouTube::Plugin::_debug (342) $VAR1 = [
'Plugins::YouTube::Plugin',
'/opt/logitechmediaserver/cache/InstalledPlugins/Plugins/YouTube/Plugin.pm',
250,
'queryUrl',
'videoCategories',
'https://www.googleapis.com/youtube/v3/videoCategories?regionCode=us&pageToken=&maxResults=50&v=2&alt=json&part=id,snippet&key=AIzaSyACo5YVGcvbtFnicz-O0980chA36Hp6rpE'
];
[15-09-05 11:11:48.0301] Plugins::YouTube::Plugin::__ANON__ (293) error: 403 Forbidden

Wondering Jew
2015-09-05, 04:32
Hi Phillipe

The version has updated to 0.27 today. I've updated the log level to Debug. When restarting the server I get this message:


[15-09-04 21:00:34.8281] Slim::Utils::Misc::msg (1220) Warning: [21:00:34.8267] Async::HTTP: Unable to load IO::Socket::SSL, will try connecting to SSL servers in non-SSL mode

The plugin Debug log is:


[15-09-05 11:11:47.9428] Plugins::YouTube::Plugin::searchHandler (215) search: q=, feed: videoCategories, parser :CODE(0x5f91368), term:
$VAR1 = {
'quantity' => 50,
'library_id' => undef,
'wantMetadata' => 1,
'isWeb' => 1,
'index' => undef,
'wantIndex' => 1,
'search' => undef,
'params' => undef
};
[15-09-05 11:11:47.9455] Plugins::YouTube::Plugin::__ANON__ (249) fetching: https://www.googleapis.com/youtube/v3/videoCategories?regionCode=us&pageToken=&maxResults=50&v=2&alt=json&part=id,snippet&key=AIzaSyACo5YVGcvbtFnicz-O0980chA36Hp6rpE
[15-09-05 11:11:47.9477] Plugins::YouTube::Plugin::_debug (342) $VAR1 = [
'Plugins::YouTube::Plugin',
'/opt/logitechmediaserver/cache/InstalledPlugins/Plugins/YouTube/Plugin.pm',
250,
'queryUrl',
'videoCategories',
'https://www.googleapis.com/youtube/v3/videoCategories?regionCode=us&pageToken=&maxResults=50&v=2&alt=json&part=id,snippet&key=AIzaSyACo5YVGcvbtFnicz-O0980chA36Hp6rpE'
];
[15-09-05 11:11:48.0301] Plugins::YouTube::Plugin::__ANON__ (293) error: 403 Forbidden

I'm getting the same Forbidden error on any search. I'm using the 0.26 version on SqueezePlug. Many thanks in advance!

badboygolf16v
2015-09-05, 04:37
I think the error may be related to the startup server log message which is defaulting to HTTP.

When I browse the URL directly in Chrome I get the info back, when I switch the protocol to HTTP I get {"error":{"errors":[{"domain":"global","reason":"sslRequired","message":"SSL is required to perform this operation."}],"code":403,"message":"SSL is required to perform this operation."}}

Wondering Jew
2015-09-05, 05:07
I think the error may be related to the startup server log message which is defaulting to HTTP.

When I browse the URL directly in Chrome I get the info back, when I switch the protocol to HTTP I get {"error":{"errors":[{"domain":"global","reason":"sslRequired","message":"SSL is required to perform this operation."}],"code":403,"message":"SSL is required to perform this operation."}}

Hmm. So I tried the URL from your log and it also worked for me in the browser, but then when I switched to using my own generated key, I got that 403 error. So when I "borrowed" the key from your URL and applied it to the plugin settings, I'm getting response!

So I take back my complaint. I'm not sure what I did wrong when I generated my own key, but I hope it's OK that I'm using yours :-)

Thanks.

mherger
2015-09-05, 05:13
I guess you're using some flavour of Linux. Try to install IO::Socket::SSL.



> Am 05.09.2015 um 12:16 schrieb badboygolf16v <badboygolf16v.72qqzz (AT) no-mx (DOT) forums.slimdevices.com>:
>
>
> philippe_44 wrote:
>> Can you add a bit more of your server.log ? Maybe as well enable the
>> debug level in YouTube plugin (settings, advanced, logging) ?
>
> Hi Phillipe
>
> The version has updated to 0.27 today. I've updated the log level to
> Debug. When restarting the server I get this message:
>
>
> Code:
> --------------------
> [15-09-04 21:00:34.8281] Slim::Utils::Misc::msg (1220) Warning: [21:00:34.8267] Async::HTTP: Unable to load IO::Socket::SSL, will try connecting to SSL servers in non-SSL mode
> --------------------
>
>
> The plugin Debug log is:
>
>
> Code:
> --------------------
> [15-09-05 11:11:47.9428] Plugins::YouTube::Plugin::searchHandler (215) search: q=, feed: videoCategories, parser :CODE(0x5f91368), term:
> $VAR1 = {
> 'quantity' => 50,
> 'library_id' => undef,
> 'wantMetadata' => 1,
> 'isWeb' => 1,
> 'index' => undef,
> 'wantIndex' => 1,
> 'search' => undef,
> 'params' => undef
> };
> [15-09-05 11:11:47.9455] Plugins::YouTube::Plugin::__ANON__ (249) fetching: https://www.googleapis.com/youtube/v3/videoCategories?regionCode=us&pageToken=&maxResults=50&v=2&alt=json&part=id,snippet&key=AIzaSyACo5YVGcvbtFnicz-O0980chA36Hp6rpE
> [15-09-05 11:11:47.9477] Plugins::YouTube::Plugin::_debug (342) $VAR1 = [
> 'Plugins::YouTube::Plugin',
> '/opt/logitechmediaserver/cache/InstalledPlugins/Plugins/YouTube/Plugin.pm',
> 250,
> 'queryUrl',
> 'videoCategories',
> 'https://www.googleapis.com/youtube/v3/videoCategories?regionCode=us&pageToken=&maxResults=50&v=2&alt=json&part=id,snippet&key=AIzaSyACo5YVGcvbtFnicz-O0980chA36Hp6rpE'
> ];
> [15-09-05 11:11:48.0301] Plugins::YouTube::Plugin::__ANON__ (293) error: 403 Forbidden
> --------------------
>
>
> ------------------------------------------------------------------------
> badboygolf16v's Profile: http://forums.slimdevices.com/member.php?userid=19486
> View this thread: http://forums.slimdevices.com/showthread.php?t=87731
>
>

badboygolf16v
2015-09-05, 06:28
Thanks Michael.

I'm using Arch Linux installed from SoA. I did find the instructions to install the Perl module from CPAN, but I thought I'd hold fire until someone said to try it.

Would you know if there is there any chance it could affect my SoA install?

mherger
2015-09-05, 06:58
On Linux I'd always try to install using the system's software management first. Google for arch Linux and perl module installation.



> Am 05.09.2015 um 15:28 schrieb badboygolf16v <badboygolf16v.72qzvz (AT) no-mx (DOT) forums.slimdevices.com>:
>
>
> Thanks Michael.
>
> I'm using Arch Linux installed from SoA. I did find the instructions to
> install the Perl module from CPAN, but I thought I'd hold fire until
> someone said to try it.
>
> Would you know if there is there any chance it could affect my SoA
> install?
>
>
> ------------------------------------------------------------------------
> badboygolf16v's Profile: http://forums.slimdevices.com/member.php?userid=19486
> View this thread: http://forums.slimdevices.com/showthread.php?t=87731
>
>

ChrisNY
2015-09-05, 07:37
Just wanted to throw my thanks in for getting this PlugIn working again! I've been playing around and it seems to be working great.

One thing which might make it easier for new users is to either have the API key be added via the Settings on the Plugins tab or add a note to the Description on the Plugins tab alerting to the need to add the API key via Advanced/Plugins. Took me a little while to figure that out.

Thanks again! I've been gushing to my wife about how great it is to have the Squeezebox still evolving even though the official hardware has been orphaned!

-Chris

garym
2015-09-05, 08:54
Just wanted to throw my thanks in for getting this PlugIn working again! I've been playing around and it seems to be working great.

One thing which might make it easier for new users is to either have the API key be added via the Settings on the Plugins tab or add a note to the Description on the Plugins tab alerting to the need to add the API key via Advanced/Plugins. Took me a little while to figure that out.

Thanks again! I've been gushing to my wife about how great it is to have the Squeezebox still evolving even though the official hardware has been orphaned!

-Chris

Where do I find API to include in settings?

SlimChances
2015-09-05, 09:20
Where do I find API to include in settings?



http://forums.slimdevices.com/showthread.php?87731-Announce-YouTube-Plugin/page37

POST 366

garym
2015-09-05, 09:57
http://forums.slimdevices.com/showthread.php?87731-Announce-YouTube-Plugin/page37

POST 366

Aha. Thanks. And thanks to all for getting this plugin working again. Working well on my end.

505
2015-09-05, 09:58
Very nice to see that someone continues working on on the YouTube plugin. I did some changes on the previous version, and hosted it on GitHub, but I couldn't find the time to update it to APIv3. Glad to see philippe_44 did. Great job!

philippe_44
2015-09-05, 13:06
For some unknown reason I started from a version without your modifications to handle signatures. I've re-integrated them in 0.26. Thanks for that part, this is a piece of art !

Aleksander
2015-09-05, 15:43
Hi All, I'm wondering, if it's only me: seems like I'm getting lower resolution streams using the plugin, checking/unchecking the option in settings doesn't seems to have any impact on the sound quality.
any ideas? Using v0.26, Server runs on Windows 7, LMS version 7.9.0 - 1440747495...

juno604
2015-09-05, 15:48
Thanks and cong for this nice and long awaited add-on !
Got it installed and functionally working, API key etc. but experience some cracking, crunches etc. all along playback, like all YT files were vinyl rips !
I suspect a bandwidth/buffer issue but still wonder if blanks wouldn't occur instead if it's really that.
I can't find any adjustment parameters at the same time neither.
Does anyone get similar issue and think a proper setting combination on the file format panel (attached SC) can help for lighten the stream and fix it ?

/\

18762

castalla
2015-09-05, 15:57
Thanks and cong for this nice and long awaited add-on !
Got it installed and functionally working, API key etc. but experience some cracking, crunches etc. all along playback, like all YT files were vinyl rips !
I suspect a bandwidth/buffer issue but still wonder if blanks wouldn't occur instead if it's really that.
I can't find any adjustment parameters at the same time neither.
Does anyone get similar issue and think a proper setting combination on the file format panel (attached SC) can help for lighten the stream and fix it ?

/\

18762

I've also experienced some grungy audio - switching to another source, and then replaying seems to fix the quality. Strange.

philippe_44
2015-09-05, 19:20
I don't know what is LMS and players behavior if data are not coming fast enough. What is true is that this is now using SSL so some overhead has been added compared to the initial version. Still, if YouTube videos play well on your browser, then this is something else. I think there is an option in LMS to say the minimum amount of time you want to have buffered before playback actually starts - can't remember where exactly while I'm writing this

[edit]: this is in settings, advanced, network

tmp_t1
2015-09-09, 02:15
Hi..
Thank you very very much for getting this great plugin back up.
I tried v.0.27 on my debian installation, added a browser api-key (is that the correct one, couldn't find a web-key!) and the plugin works somewhat..
Searching works... adding to playlist, but music doesn't start.
Log shows: [15-09-09 11:11:09.2190] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/xxxxxxx].
I tried several songs

garym
2015-09-09, 05:20
Hi..
Thank you very very much for getting this great plugin back up.
I tried v.0.27 on my debian installation, added a browser api-key (is that the correct one, couldn't find a web-key!) and the plugin works somewhat..
Searching works... adding to playlist, but music doesn't start.
Log shows: [15-09-09 11:11:09.2190] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/xxxxxxx].
I tried several songs

I added the "server key API". It works for me on vortexbox install (fedora linux)

philippe_44
2015-09-09, 07:55
Hi..
Thank you very very much for getting this great plugin back up.
I tried v.0.27 on my debian installation, added a browser api-key (is that the correct one, couldn't find a web-key!) and the plugin works somewhat..
Searching works... adding to playlist, but music doesn't start.
Log shows: [15-09-09 11:11:09.2190] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/xxxxxxx].
I tried several songs

What is your system ? You might miss the io::socket:SSL Perl library. Do you have a bit more log that talk about error 403 ?

tmp_t1
2015-09-09, 12:15
What is your system ? You might miss the io::socket:SSL Perl library. Do you have a bit more log that talk about error 403 ?

I run Linux 3.2.0-4-kirkwood #1 Debian 3.2.68-1+deb7u3 armv5tel GNU/Linux on a pogoplug.
The log does not show more information. Can I tune the debug level somewhere?

I think the SSL library is installed. At least I have libio-socket-ssl-perl installed.

lafontaj
2015-09-10, 08:06
I'm very happy to see that plugin alive again but i experiment some problem with it.

First i installed the plugin and configured it with the api key from https://console.developers.google.com

Ref: see image attach

you can also see the graph of all the error reported in the api report (see attach) and the server log

I can listen the recently played files but every others option gave me errors (see attach)

The libio-socket-ssl-perl is installed

My system is running Ubuntu 12.04 64bits.


Can it be about the access previlege of the API or something about my youtube account preference?

Thanks for youre help.

philippe_44
2015-09-10, 10:41
I'm very happy to see that plugin alive again but i experiment some problem with it.

First i installed the plugin and configured it with the api key from https://console.developers.google.com

Ref: see image attach

you can also see the graph of all the error reported in the api report (see attach) and the server log

I can listen the recently played files but every others option gave me errors (see attach)

The libio-socket-ssl-perl is installed

My system is running Ubuntu 12.04 64bits.


Can it be about the access previlege of the API or something about my youtube account preference?

Thanks for youre help.

You might want to set the logging level to debug for the youtube plugin and take the server log from that. You can PM it to me if you don't want your key to be exposed, or edit the log before posting it.

K.Clemens
2015-09-10, 14:33
philippe_44

Big thumbs up for all the work.

Unfortualy I have little trouble with installing the plugin.
I use a Raspberry PI 2, so I downloaded the ZIP and extracted it into "/var/lib/squeezeboxserver/Plugins"
I keep on getting the error "could not load plugin". Any idea?

Started from a fresh installation, so no earlier plugin was installed.

Logitech Media Server Versie: 7.7.2 - r33893 @ Wed Mar 14 05:46:46 PDT 2012
Hostnaam: ------
IP-adres van server: ------
HTTP-poortnummer van server: 9000
Besturingssysteem: Debian - NL - utf8
Platformarchitectuur: armv7l-linux
Perl-versie: 5.14.2 - arm-linux-gnueabihf-thread-multi-64int
Databaseversie: DBD::SQLite 1.34_01 (sqlite 3.7.7.1)
Totaalaantal herkende muzieksystemen: 2

Man in a van
2015-09-10, 15:20
I keep a LMS on my Windows laptop (just in case).

Started it up today and got the "plug in updated, restart" message.

So I did a couple of restarts, and the defunct Triode You Tube logo in My Apps changed like magic.:confused:

Did the API key thing and off she goes.

Many thanks philippe_44.

Top Bloke!!:p

atb

Ronnie


Does the Country for categories actually do anything? and can one have more than one?

philippe_44
2015-09-10, 15:51
philippe_44

Big thumbs up for all the work.

Unfortualy I have little trouble with installing the plugin.
I use a Raspberry PI 2, so I downloaded the ZIP and extracted it into "/var/lib/squeezeboxserver/Plugins"
I keep on getting the error "could not load plugin". Any idea?

Started from a fresh installation, so no earlier plugin was installed.

Logitech Media Server Versie: 7.7.2 - r33893 @ Wed Mar 14 05:46:46 PDT 2012
Hostnaam: ------
IP-adres van server: ------
HTTP-poortnummer van server: 9000
Besturingssysteem: Debian - NL - utf8
Platformarchitectuur: armv7l-linux
Perl-versie: 5.14.2 - arm-linux-gnueabihf-thread-multi-64int
Databaseversie: DBD::SQLite 1.34_01 (sqlite 3.7.7.1)
Totaalaantal herkende muzieksystemen: 2

You did unzip into a 'YouTube' folder, right ? other than that, can you send a server log extract so I can see what's happening ?

lafontaj
2015-09-10, 15:53
You might want to set the logging level to debug for the youtube plugin and take the server log from that. You can PM it to me if you don't want your key to be exposed, or edit the log before posting it.

Here is my edited server.log with debugging enabled.

I played a recently played youtube and then i tried to reach another function of the youtube plugin.

Thanks

philippe_44
2015-09-10, 16:10
Here is my edited server.log with debugging enabled.

I played a recently played youtube and then i tried to reach another function of the youtube plugin.

Thanks

Definitely a google API reject. Are you sure to have selected a 'browser key' when you created one ?

lafontaj
2015-09-10, 17:04
Definitely a google API reject. Are you sure to have selected a 'browser key' when you created one ?



Yes i'm sure of that and already tried to regenarate the key. I also delete the key and create a new one and it's always the same issue. I also tried to restrict the key to my domain and without restriction

lafontaj
2015-09-10, 17:47
Yes i'm sure of that and already tried to regenarate the key. I also delete the key and create a new one and it's always the same issue. I also tried to restrict the key to my domain and without restriction

Well,

I deleted everything from https://console.developers.google.com and started over for a another time and now everything is working perfectly. Sorry for the stress. I just began a good glass of wine to make me feel better.

Thanks!

mherger
2015-09-10, 21:11
I use a Raspberry PI 2, so I downloaded the ZIP and extracted it into "/var/lib/squeezeboxserver/Plugins"

Don't download & unzip manually. Just use the web UI's Settings/Plugins tab to install it.

gegen
2015-09-11, 00:11
philippe_44

Big thumbs up for all the work.

Unfortualy I have little trouble with installing the plugin.
I use a Raspberry PI 2, so I downloaded the ZIP and extracted it into "/var/lib/squeezeboxserver/Plugins"
I keep on getting the error "could not load plugin". Any idea?

Started from a fresh installation, so no earlier plugin was installed.

Logitech Media Server Versie: 7.7.2 - r33893 @ Wed Mar 14 05:46:46 PDT 2012
Hostnaam: ------
IP-adres van server: ------
HTTP-poortnummer van server: 9000
Besturingssysteem: Debian - NL - utf8
Platformarchitectuur: armv7l-linux
Perl-versie: 5.14.2 - arm-linux-gnueabihf-thread-multi-64int
Databaseversie: DBD::SQLite 1.34_01 (sqlite 3.7.7.1)
Totaalaantal herkende muzieksystemen: 2


This is the path on my RPi2 (LMS 7.9) that the unzipped and renamed 'Youtube' folder is copied to /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/ .......all working fine.
(The unzipped folder will likely be called Youtube-0.27 or whichever version you're using so don't forget to rename)

K.Clemens
2015-09-11, 01:27
You did unzip into a 'YouTube' folder, right ? other than that, can you send a server log extract so I can see what's happening ?

Here is the log:
[15-09-11 10:14:18.8921] Slim::bootstrap::tryModuleLoad (285) Warning: Module [Plugins::YouTube::Plugin] failed to load:
Base class package "IO::Socket::SSL" is empty.
(Perhaps you need to 'use' the module which defines that package first,
or make that module available in @INC (@INC contains: /var/lib/squeezeboxserver/cache/InstalledPlugins /usr/share/squeezeboxserver/CPAN/arch/5.14/arm-linux-gnueabihf-thread-multi-64int /usr/share/squeezeboxserver/CPAN/arch/5.14/arm-linux-gnueabihf-thread-multi-64int/auto /usr/share/squeezeboxserver/CPAN/arch/5.14.2/arm-linux-gnueabihf-thread-multi-64int /usr/share/squeezeboxserver/CPAN/arch/5.14.2/arm-linux-gnueabihf-thread-multi-64int/auto /usr/share/squeezeboxserver/CPAN/arch/5.14/arm-linux-gnueabihf-thread-multi-64int /usr/share/squeezeboxserver/CPAN/arch/5.14/arm-linux-gnueabihf-thread-multi-64int/auto /usr/share/squeezeboxserver/CPAN/arch/arm-linux-gnueabihf-thread-multi-64int /usr/share/squeezeboxserver/lib /usr/share/squeezeboxserver/CPAN /usr/share/squeezeboxserver /usr/share/squeezeboxserver/CPAN /usr/share/squeezeboxserver /usr/sbin /etc/perl /usr/local/lib/perl/5.14.2 /usr/local/share/perl/5.14.2 /usr/lib/perl5 /usr/share/perl5 /usr/lib/perl/5.14 /usr/share/perl/5.14 /usr/local/lib/site_perl .).
at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 2
BEGIN failed--compilation aborted at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/ProtocolHandler.pm line 2.
Compilation failed in require at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/Plugin.pm line 20.
BEGIN failed--compilation aborted at /var/lib/squeezeboxserver/cache/InstalledPlugins/Plugins/YouTube/Plugin.pm line 20.
Compilation failed in require at (eval 999) line 2.
BEGIN failed--compilation aborted at (eval 999) line 2.

philippe_44
2015-09-11, 01:37
You miss the IO::Socket::SSL. Install it using CPAN

mherger
2015-09-11, 02:08
You miss the IO::Socket::SSL. Install it using CPAN

In your plugin you could check Slim::Networking::Async::HTTP::hasSSL() and act accordingly.

K.Clemens
2015-09-11, 02:29
Normal installation with "sudo cpan install IO::Socket::SSL" does not seem to work. Have to do a forced install, but don't know how:confused:

Edit: sudo apt-get install libio-socket-ssl-perl did the job.

Now ketting the key... :)

tmp_t1
2015-09-11, 03:25
Seems like I fixed my problem by updating to LMS 7.9 (nightly) (coming from 7.8.0)

K.Clemens
2015-09-11, 03:54
Ok, everthing works fine now, except playing of the files.

When I search, and press play on a result, it will only play 3-4 seconds (w/o sound) and then stops...

log: [15-09-11 12:56:45.8284] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/_CL6n0FJZpk].

Corelli45
2015-09-12, 01:15
Thank you taking the time for resurrecting this plug-in. Got the API key this morning and am now playing some Joanna Newsom.

Steve

badboygolf16v
2015-09-12, 01:30
I'd also like to thank Phillipe for resurrecting this plugin, hours of old Congolese music is now available to me again!

HeadBanger
2015-09-12, 09:35
A big thank you from me too!

HB

tmp_t1
2015-09-12, 10:33
Ok, everthing works fine now, except playing of the files.

When I search, and press play on a result, it will only play 3-4 seconds (w/o sound) and then stops...

log: [15-09-11 12:56:45.8284] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/_CL6n0FJZpk].


Please see my recent messages

philippe_44
2015-09-12, 15:55
Hi - I've just released a version 0.31 [edit:0.32] with the following changes

- add Guided Channels (categories)
- Major refactor by Michael
- Channel/Playlist can be played directly as playlist
- Get video icons in the search results
- Caching of searches (cache can be flushed in settings)
[edit]:0.32
- Guided Channels can contain playlist

Basically, it is a much cleaner version where Michael did 99% of the work of re-factoring the code and adding proper caching - thanks a lot for doing that

philippe_44
2015-09-12, 15:56
Please see my recent messages

I don't know, I would need a bit more server.log information but you might still have a SSL problem that would explain that opening of video fail

tmp_t1
2015-09-13, 09:55
I don't know, I would need a bit more server.log information but you might still have a SSL problem that would explain that opening of video fail

I'm sorry philippe. My problem is already solved.
My post was a reaction for K.Clemens, who seems to have the same problem, which I solved (as posted earlier) by updating LMS (to 7.9 nightly. I was using 7.8.1)

paulster
2015-09-13, 15:45
Does this require 7.9? I haven't been able to follow the entire recent threads, but I tried updating on 7.8.1 yesterday and just got a 'Plugin failed to load' error in my Plugins page.

philippe_44
2015-09-13, 15:49
No, my dev environment is 7.7.5. Look for more information in the server.log

garym
2015-09-13, 15:51
Does this require 7.9? I haven't been able to follow the entire recent threads, but I tried updating on 7.8.1 yesterday and just got a 'Plugin failed to load' error in my Plugins page.

I'm using it with 7.8.0.

paulster
2015-09-13, 18:20
No, my dev environment is 7.7.5. Look for more information in the server.log

Base class package "IO::Socket::SSL" is empty.

Are you expecting a package to be there that isn't supplied by the plugin?

philippe_44
2015-09-13, 23:56
Base class package "IO::Socket::SSL" is empty.

Are you expecting a package to be there that isn't supplied by the plugin?

it must be in the LMS distribution. Some Linux don't have it (some NAS) so it needs to be installed using CPAN

SlimChances
2015-09-14, 10:31
Is it possible to install/update the plugin through the plugin page in server settings? Will it be in the future?
This plugin is a great way of exploring new music...Thanks to Philippe_44

philippe_44
2015-09-14, 15:36
Is it possible to install/update the plugin through the plugin page in server settings? Will it be in the future?
This plugin is a great way of exploring new music...Thanks to Philippe_44

It is already - just add http://sourceforge.net/projects/lms-youtube/files/dev/repo-sf.xml to the list of "additional repository"

DavidBulluss
2015-09-14, 18:17
I have been watching the developments here for quite a while, and now I think it is time to try it out but I can not get the plugin to load into LMS. I enter http://sourceforge.net/projects/lms-youtube/files/dev/repo-sf.xml into "Additional Repositories" apply, and restart the NAS. The plugin shows up as available under "Philippe's squeezecenter plugins". I select it and apply, then restart. It shows up under the list of active plugins but un-ticked and reads "Plugin Unable To Load".

I have gone back through this thread about 20 pages but can not find anything specific about compatability with my ReadyNas. All I can think is that my Netgear ReadyNas Duo V2 is using a Marvell ARM CPU and this may not be compatible?

Any help or information appreciated.

David

philippe_44
2015-09-14, 18:23
I have been watching the developments here for quite a while, and now I think it is time to try it out but I can not get the plugin to load into LMS. I enter http://sourceforge.net/projects/lms-youtube/files/dev/repo-sf.xml into "Additional Repositories" apply, and restart the NAS. The plugin shows up as available under "Philippe's squeezecenter plugins". I select it and apply, then restart. It shows up under the list of active plugins but un-ticked and reads "Plugin Unable To Load".

I have gone back through this thread about 20 pages but can not find anything specific about compatability with my ReadyNas. All I can think is that my Netgear ReadyNas Duo V2 is using a Marvell ARM CPU and this may not be compatible?

Any help or information appreciated.

David

Do you have something in the server.log ? The CPU should not matter in that case as there is no "helper" (separated executable). What you might also have is an issue with SSL that is common on NAS using LMS. You then need to install IO:Socket::SSL using CPAN. I'm working on an updated version that at least informs the user through the webUI when SSL is missing

DavidBulluss
2015-09-14, 18:29
... install IO:Socket::SSL using CPAN...

Thanks for very quick reply! Is there anything back through the thread that describes how to install IO:Socket::SSL using CPAN? If there is I will trawl back and find it, otherwise it is unfortunately lost on me! :p

Cheers,

David

philippe_44
2015-09-14, 21:59
Thanks for very quick reply! Is there anything back through the thread that describes how to install IO:Socket::SSL using CPAN? If there is I will trawl back and find it, otherwise it is unfortunately lost on me! :p

Cheers,

David

You can try "sudo cpan IO::Socket::SSL" once you have logged into your NAS

paulster
2015-09-14, 22:40
it must be in the LMS distribution. Some Linux don't have it (some NAS) so it needs to be installed using CPAN

I'm using an off-the-shelf Debian installation on Intel hardware, so I think you may be assuming that more distributions have it than actually do.

mherger
2015-09-14, 22:43
It should be available on Debian:

https://packages.debian.org/de/sid/libio-socket-ssl-perl

paulster
2015-09-14, 22:45
It should be available on Debian:

https://packages.debian.org/de/sid/libio-socket-ssl-perl

Thanks, Michael. But shouldn't plugins install additional packages they require as a general rule? I've never had to go and install any third-party packages before when installing a plugin.

philippe_44
2015-09-14, 22:46
I'm using an off-the-shelf Debian installation on Intel hardware, so I think you may be assuming that more distributions have it than actually do.

I thought LMS was compensating during its own install as HTTPS is pretty usefull

philippe_44
2015-09-14, 22:48
Thanks, Michael. But shouldn't plugins install additional packages they require as a general rule? I've never had to go and install any third-party packages before when installing a plugin.

To some extend yes, but this is a bit too much extra for me currently

paulster
2015-09-14, 22:51
I thought LMS was compensating during its own install as HTTPS is pretty usefull

Guess this doesn't get installed by default. I just added the package from the Debian repository and we're all good now.

I know people have said that upgrading to 7.9 nightly has solved their issue, so I'm wondering if later LMS packages than the 7.8.1 I'm using include it then.

Regardless, thanks for taking on this plugin.

philippe_44
2015-09-15, 22:04
- Search now accepts multi-byte strings (chinese char)
- Cache flush option removed
- Channels and Playlists can be added to favorites
- Skip videos w/o a thumbnail (they are private or deleted)
- Channels are in bold and playlist in italic bold
- Add search in everything (channel, playlist and video)
- (B) play/add on a channel/playlist was limited to 1st 50 items
- (B) on LMS < 7.9 playlist played directly from channel/playlist was failing to get metadata

SlimChances
2015-09-16, 06:19
- Search now accepts multi-byte strings (chinese char)
- Cache flush option removed
- Channels and Playlists can be added to favorites
- Skip videos w/o a thumbnail (they are private or deleted)
- Channels are in bold and playlist in italic bold
- Add search in everything (channel, playlist and video)
- (B) play/add on a channel/playlist was limited to 1st 50 items
- (B) on LMS < 7.9 playlist played directly from channel/playlist was failing to get metadata

Not sure if this is a security issues regarding permissions on Linux. I notice that files in my other plugins are read only for "others" and "nogroup" whereas for Youtube they are read and write

smitti_
2015-09-18, 08:06
Hi philippe_44

great that you took over to get the plugin working again. It looks like it works already for many but I still have the problem that I can add the yt song to the playlist and when i click on the play button the time is counting up some seconds and then it stops again.

In the logfile i have



[15-09-18 11:32:04.8861] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/jCco5vvnH18].
[15-09-18 11:32:10.8547] Plugins::YouTube::ProtocolHandler::open (49) Couldn't find valid protocol, server or port in url: [https://r2---sn-uigxx50n-8pxs.googlevideo.com/videoplayback?key=yt5&sver=3&pcm2=no&requiressl=yes&sparams=dur%2Cgcr%2Cid%2Cinitcwndbps%2Cip%2Cipbits %2Citag%2Clmt%2Cmime%2Cmm%2Cmn%2Cms%2Cmv%2Cpcm2%2C pcm2cms%2Cpl%2Crequiressl%2Csource%2Cupn%2Cexpire&pcm2cms=yes&expire=1442590326&lmt=1425038099749066&upn=BIhihAYjjls&mt=1442568636&initcwndbps=826250&id=o-AMgQ6dRVnFRW43yVCV32T4jZVBS5x0a_mVOM_ARq1KRb&pl=18&dur=237.061&mime=video%2Fx-flv&ms=au&signature=92D75A30D5BF2466A9B9EE05EE93055F62A2D636 .490C4A3316A1F8C01F16D6F5C1D4F7D61B77889A&source=youtube&mv=m&mm=31&ipbits=0&mn=sn-uigxx50n-8pxs&itag=5&gcr=at&fexp=9407156%2C9407641%2C9408710%2C9409069%2C94132 09%2C9415365%2C9415485%2C9416023%2C9416126%2C94162 31%2C9416729%2C9416985%2C9417124%2C9417707%2C94177 62%2C9418153%2C9418405%2C9418448%2C9418997%2C94192 51%2C9419298%2C9420348%2C9420421%2C9421013&ip=178.112.103.80&signature=]
[15-09-18 11:32:10.8563] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/jCco5vvnH18].


I am using Vortexbox as Server and client. Do you have an idea what the problem is?:confused:

Edit: Today I got the udpate for v0.33 automatically, restarted the server, but still does not work.

psycho13
2015-09-18, 08:55
Same for me... :-(

philippe_44
2015-09-18, 10:34
Hi philippe_44

great that you took over to get the plugin working again. It looks like it works already for many but I still have the problem that I can add the yt song to the playlist and when i click on the play button the time is counting up some seconds and then it stops again.

In the logfile i have



[15-09-18 11:32:04.8861] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/jCco5vvnH18].
[15-09-18 11:32:10.8547] Plugins::YouTube::ProtocolHandler::open (49) Couldn't find valid protocol, server or port in url: [https://r2---sn-uigxx50n-8pxs.googlevideo.com/videoplayback?key=yt5&sver=3&pcm2=no&requiressl=yes&sparams=dur%2Cgcr%2Cid%2Cinitcwndbps%2Cip%2Cipbits %2Citag%2Clmt%2Cmime%2Cmm%2Cmn%2Cms%2Cmv%2Cpcm2%2C pcm2cms%2Cpl%2Crequiressl%2Csource%2Cupn%2Cexpire&pcm2cms=yes&expire=1442590326&lmt=1425038099749066&upn=BIhihAYjjls&mt=1442568636&initcwndbps=826250&id=o-AMgQ6dRVnFRW43yVCV32T4jZVBS5x0a_mVOM_ARq1KRb&pl=18&dur=237.061&mime=video%2Fx-flv&ms=au&signature=92D75A30D5BF2466A9B9EE05EE93055F62A2D636 .490C4A3316A1F8C01F16D6F5C1D4F7D61B77889A&source=youtube&mv=m&mm=31&ipbits=0&mn=sn-uigxx50n-8pxs&itag=5&gcr=at&fexp=9407156%2C9407641%2C9408710%2C9409069%2C94132 09%2C9415365%2C9415485%2C9416023%2C9416126%2C94162 31%2C9416729%2C9416985%2C9417124%2C9417707%2C94177 62%2C9418153%2C9418405%2C9418448%2C9418997%2C94192 51%2C9419298%2C9420348%2C9420421%2C9421013&ip=178.112.103.80&signature=]
[15-09-18 11:32:10.8563] Slim::Player::Song::open (471) Warning: stream failed to open [youtube://www.youtube.com/v/jCco5vvnH18].


I am using Vortexbox as Server and client. Do you have an idea what the problem is?:confused:

Edit: Today I got the udpate for v0.33 automatically, restarted the server, but still does not work.

This particular video is not playable (cannot find a good audio stream). Does it do the same for each and every video, when you take them one by one ? There is also a complaint that the url is wrong and I'll look into that, but anyway that video does not work