Page 1 of 2

VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 11 Jan 2019 08:24
by #thweiss
Hello together,

the VLC-Player Version 3.0.6 (32-Bit), installed in Windows 7 (64-Bit), do not play all youtube Streams.

Example Youtube Live-Stream:
https://www.youtube.com/watch?v=Ec7VUcdB-ww

Found in the the VLC verbose log:
lua error: Couldn't extract youtube video URL, please check for updates to this script

Hope someone can update the youtube.luac Script (http://git.videolan.org/?p=vlc.git;a=bl ... ua;hb=HEAD) for the VLC-Player.

Thanks
Thomas

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 11 Jan 2019 13:50
by anmaelo
i learned only a few days ago that VLC was able to record live streaming Youtube video.
yesterday afternoon (Jan 10 2019, at about noon GMT) this feature died. when i try to open the stream VLC seems to try opening the URL for a few seconds. then nothing happens.

usually i have used Potplayer to record live streaming webcameras from Youtube. since yesterday also Potplayer has been unable to do this. the Tube probably changed something.

are you aware of this change in the Tube? furthermore and more importantly: can you restore the live streaming recording feature to VLC?

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 11 Jan 2019 15:11
by unidan
Hi, it breaks quite often, each time google makes a change in Youtube. You just have to wait for someone to fix it. ;)

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 11 Jan 2019 19:05
by Hitchhiker
Hi, it breaks quite often, each time google makes a change in Youtube. You just have to wait for someone to fix it. ;)

Chill Your Mind radio which the OP's link leads to started streaming on December 12 last year, but the current youtube.luac file is dated 9-12-2018 so three days earlier. That's the problem in this particular case I guess.

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 13 Jan 2019 10:37
by anmaelo
is there anything that i or any other 'normal' person could do to fix this problem? or do we just have to wait till someone else does something (Youtube/Google or VLC-people)?

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 13 Jan 2019 21:47
by beetlesoup
youtube-dl suffered the same live streams issue as VLC, but were able to put out a fix the following day.

https://github.com/rg3/youtube-dl/issues/18825
https://github.com/rg3/youtube-dl/commi ... 0f936b81f1

I'm not a coder so I don't know what any of this means, but perhaps it can be of use to someone.

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 14 Jan 2019 10:38
by #thweiss
There is a simple Way to replace the installed youtube.luac File in the VLC-Directory.
1) Rename the youtube.luac (for Example youtube_luac).
2) Open Notepad-Editor and copy the youtube.luac Text from the Github Source.
- http://git.videolan.org/?p=vlc.git;a=bl ... ua;hb=HEAD
3) Save the copied Text-File in the Editor as youtube.luac File.
4) Copy of the new youtube.luac File in the VLC-Install Directory .../VLC/lua/playlist/
5) Restart the VLC-Player.

In the last Time this Workaround works fine with the VLC-Player and the actualized youtube.luac File from Github.

Thomas

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 15 Jan 2019 09:46
by seyedaed
Hi thanks for the help, I'm having the same issue and was looking for help.

However, it seems as though the current youtube.luac file in the git no longer works for streams. I believe there was a recent change youtube made that broke it again.

I don't know much about this but I managed to trace the error to something related to around line 367 in the youtube.lua code:

Code: Select all

if not path then -- If this is a live stream, the URL map will be empty -- and we get the URL from this field instead local hlsvp = string.match( line, "&hlsvp=([^&]*)" ) if hlsvp then hlsvp = vlc.strings.decode_uri( hlsvp ) path = hlsvp end end
The string &hlsvp seems to no longer exist in the url. The url for the get video looks like this:

Code: Select all

www.youtube.com/get_video_info?video_id=6Stj0jKBh8M&el=detail
This returns an error with invalid parameter.

Code: Select all

errorcode=2&reason=Invalid+parameters.&status=fail
I tried putting in the url without the el=detail and I received data but couldn't find the &hlsvp string in the file even after decoding. I also tried detailpage and it seems to download the data correctly.

I'll post again with a possible fix I made.

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 15 Jan 2019 09:48
by seyedaed
I made a quick fix because I use it for streaming and it seems to work but I haven't fully tested it. I made these changes to the youtube.lua file downloaded from the link above. After making these changes I removed the youtube.luac file and put the changed youtube.lua file in the plugins directory.

I changed line 334 from:

Code: Select all

path = vlc.access.."://www.youtube.com/get_video_info?video_id="..video_id.."&el=detail"..copy_url_param( vlc.path, "fmt" )
to

Code: Select all

path = vlc.access.."://www.youtube.com/get_video_info?video_id="..video_id.."&el=detailpage"..copy_url_param( vlc.path, "fmt" )
This will retrieve the data but it still won't find the hlsvp. As a workaround I changed lines:
371 - 378 which read:

Code: Select all

if not path then -- If this is a live stream, the URL map will be empty -- and we get the URL from this field instead local hlsvp = string.match( line, "&hlsvp=([^&]*)" ) if hlsvp then hlsvp = vlc.strings.decode_uri( hlsvp ) path = hlsvp end end
To:

Code: Select all

local hlsvp = string.match( line, 'hlsManifestUrl.+m3u8' ) if hlsvp then --hlsvp = vlc.strings.decode_uri( hlsvp ) hlsvp = vlc.strings.decode_uri( hlsvp ) path = hlsvp path = string.match(path, "https.+m3u8") end
It seems to load the streams now. I don't know if this is an adequate solution but I think it will serve my purposes, so I'm sharing this in case anyone else wants to play with it.

I can upload the file if someone can suggest where. I'll be testing it on my stream and see how it works tonight.

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 15 Jan 2019 10:09
by unidan
Hi, if it fixes the issue, you can send the patch to the vlc-devel mailing list to include it into the next release. If you need help for this, I can help.

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 16 Jan 2019 20:52
by #thweiss
@seyedaed
Thanks for the fast help and the suggested Code-Change in the youtube.luac-File, which work fine with the Youtube Link above.

I add the new "Youtube.luac"-File for downloading in the follow Link as "youtube.luac.txt"-File.
Please remove the *.txt File-Extension after Download and follow the workaround above.

https://www.vlc-forum.de/wcf/attachment ... -luac-txt/

@unidan
I don't know how to add the Code-Change in the VLC-Devel Mailing List.
Perhaps You can do this and send the Code-Change to the Mailing List.

Thomas

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 19 Jan 2019 11:39
by seyedaed
@unidan and @Thomas thanks! If you can share it to the list that would be great! Sorry for the late response.

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 21 Jan 2019 16:10
by unidan
Hi, this has been merged into nightly and for next 3.0 release

https://github.com/videolan/vlc-3.0/com ... 9f1d932608

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 22 Jan 2019 05:37
by Claybern
Worked great.
Thank you.
Clay-

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 22 Jan 2019 17:05
by VLCFanNumber1
Works like a charm. Thank you Seyedaed :P

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 23 Jan 2019 08:06
by nandini30
nice!!!!!

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 26 Jan 2019 21:11
by Dae
Thank you good sirs, you're great!

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 22 Mar 2019 13:35
by FiLinX
Unfortunately, Google has changed something again in Youtube, and the broadcasts are not reproduced again ..
Example, NASA Live Permanent Link: Official Stream of NASA TV - https://www.youtube.com/watch?v=21X5lGlDOfg

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 24 Mar 2019 04:41
by Sigbots
Im having the same issue ,youtube changes something as It was working and now it does not ,

LOGFILE

"lua debug: Trying Lua playlist script C:\Program Files (x86)\VideoLAN\VLC\lua\playlist\youtube.luac
lua warning: error loading script C:\Program Files (x86)\VideoLAN\VLC\lua\playlist\youtube.luac: C:\Program Files (x86)\VideoLAN\VLC\lua\playlist\youtube.luac:1: '=' expected near 'to'
main debug: no stream_filter modules matched
main debug: looking for stream_directory module matching "any": 1 candidates
main debug: no stream_directory modules matched
main debug: attachment of directory-extractor failed "

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 24 Mar 2019 12:25
by VLCFanNumber1
It still works for me

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 25 Mar 2019 09:57
by unidan
Im having the same issue ,youtube changes something as It was working and now it does not ,

LOGFILE

"lua debug: Trying Lua playlist script C:\Program Files (x86)\VideoLAN\VLC\lua\playlist\youtube.luac
lua warning: error loading script C:\Program Files (x86)\VideoLAN\VLC\lua\playlist\youtube.luac: C:\Program Files (x86)\VideoLAN\VLC\lua\playlist\youtube.luac:1: '=' expected near 'to'
main debug: no stream_filter modules matched
main debug: looking for stream_directory module matching "any": 1 candidates
main debug: no stream_directory modules matched
main debug: attachment of directory-extractor failed "
Hi, this looks like a syntax error, did you modify the lua script ?

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 25 Mar 2019 11:17
by Lotesdelere
It still works for me

Not for me.
I can see the pic of the video but the live stream never starts.

Code: Select all

main debug: `https://www.youtube.com/watch?v=21X5lGlDOfg' successfully opened http debug: in DATA (0x00) frame of 16377 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 15367 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 8122 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 241 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16213 bytes, flags 0x00, stream 1 http debug: out (priority) WINDOW_UPDATE (0x08) frame of 4 bytes, flags 0x00, global http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 6926 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 11098 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 0 bytes, flags 0x01, stream 1 http debug: stream 1 closed by peer http debug: in PING (0x06) frame of 8 bytes, flags 0x00, global http debug: out (priority) PING (0x06) frame of 8 bytes, flags 0x01, global prefetch debug: end of stream lua warning: Couldn't extract video URL, falling back to alternate youtube API lua debug: Path: https://www.youtube.com/get_video_info?video_id=21X5lGlDOfg&el=detailpage lua debug: Name: NASA Live: Official Stream of NASA TV lua debug: Artist: NASA lua debug: Description: Direct from America's space program to YouTube, watch NASA TV live streaming here to get the latest from our exploration of the universe and learn how we discover our home planet. NASA TV airs a variety of regularly scheduled, pre-recorded educational and public relations programming 24 hours a day on its various channels. The network also provides an array of live programming, such as coverage of missions, events (spacewalks, media interviews, educational broadcasts), press conferences and rocket launches. In the United States, NASA Television's Public and Media channels are MPEG-2 digital C-band signals carried by QPSK/DVB-S modulation on satellite AMC-3, transponder 15C, at 87 degrees west longitude. Downlink frequency is 4000 MHz, horizontal polarization, with a data rate of 38.86 Mhz, symbol rate of 28.1115 Ms/s, and ¾ FEC. A Digital Video Broadcast (DVB) compliant Integrated Receiver Decoder (IRD) is needed for reception. lua debug: ArtURL: https://i.ytimg.com/vi/21X5lGlDOfg/maxresdefault_live.jpg main debug: deleting item `watch?v=21X5lGlDOfg' main debug: EOF reached

Code: Select all

main debug: `https://www.youtube.com/get_video_info?video_id=21X5lGlDOfg&el=detailpage' successfully opened http debug: in DATA (0x00) frame of 11378 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 0 bytes, flags 0x01, stream 1 http debug: stream 1 closed by peer http debug: in PING (0x06) frame of 8 bytes, flags 0x00, global http debug: out (priority) PING (0x06) frame of 8 bytes, flags 0x01, global prefetch debug: end of stream main debug: removing module "prefetch" main debug: removing module "access" http debug: local stream 1 shut down http debug: out RST_STREAM (0x03) frame of 4 bytes, flags 0x00, stream 1 http debug: local shutdown http debug: out GOAWAY (0x07) frame of 8 bytes, flags 0x00, global http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 16384 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 441 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 232 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 2945 bytes, flags 0x00, stream 1 http debug: in DATA (0x00) frame of 0 bytes, flags 0x01, stream 1 http debug: stream 1 closed by peer http debug: in PING (0x06) frame of 8 bytes, flags 0x00, global http debug: out (priority) PING (0x06) frame of 8 bytes, flags 0x01, global prefetch debug: end of stream

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 25 Mar 2019 14:17
by unidan
It might depend on the version of GnuTLS, but it's not the same error as for sigbots.

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 26 Mar 2019 10:44
by #thweiss
For open the Youtube-Address I get in the VLC-Player Logfile the following Segments.

Code: Select all

... gnutls debug: using GnuTLS version 3.5.19 gnutls debug: loaded 293 trusted CAs from system main debug: using tls client module "gnutls" main debug: resolving www.youtube.com ... gnutls debug: TLS handshake: Resource temporarily unavailable, try again. gnutls debug: TLS handshake: Resource temporarily unavailable, try again. gnutls debug: TLS handshake: Resource temporarily unavailable, try again. gnutls debug: TLS handshake: Success. gnutls debug: - safe renegotiation (RFC5746) enabled gnutls debug: - extended master secret (RFC7627) enabled gnutls debug: - false start (RFC7918) enabled ...
The VLC-Player Version 3.0.6 use the GnuTLS Version 3.5.19. of the secure communication library, right.

Probably a newer GnuTLS Version will avoid the communication trouble with the latest Change for Youtube.
https://www.gnutls.org/ Version 3.6.6 (2019-01-25) apparently is the lastest GnuTLS Version.

Hope someone can change the GnuTLS Version for the next VLC-Player Release or Version.
Perhaps there is a simple workaround to Change the GnuTLS-Library for the VLC-Player 3.0.6?

Re: VLC 3.0.6 - Youtube Live-Stream trouble

Posted: 11 Jun 2019 13:55
by Claybern
Worked great.
Thank you.
Clay-
Just letting you guys know.
My VLC player is up to date, and mine also stopped being able to stream YouTube videos.
Trouble started for me a few days ago (sometime around June 7, 2019), consistent with past periodic internal changes by YouTube.
When this happens I am able to stream some videos, with an increasing number of videos becoming unplayable in VLC.
Please post a fix when you guys figure it out.
Thanks very much.
Clay-