YouTube.com 0.7 - GUI for youtube-dl

Discuss and share scripts and script files...
highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by highend »

I've tried it with URLSnooper which shows a few possible links but none of them plays the video but all of them just display a blank site. Atm (and without a valid link to compare the regex matches with it) it's too much work to debug it (at least for me). Sorry.
One of my scripts helped you out? Please donate via Paypal

RalphM
Posts: 1932
Joined: 27 Jan 2005 23:38
Location: Cairns, Australia

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by RalphM »

Did you try the URL in my last post?
(Which is valid and plays the movie.)
Ralph :)
(OS: W11 22H2 Home x64 - XY: Current beta - Office 2019 32-bit - Display: 1920x1080 @ 125%)

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by highend »

I was not talking about the normal url that any browser would play but the one that allows you to download it (in different formats (flv, mp4, etc.).
One of my scripts helped you out? Please donate via Paypal

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by highend »

Ok, thanks to http://youtube-dl.org/ (they have a nice command line tool to download youtube videos) I've fixed it...

- Open the Youtube.xys file with a text editor
- Search for this line:

Code: Select all

$Map = replacelist ($Map, '\u0026,sig', '&,signature', ",", 0);
- Replace it with:

Code: Select all

$Map = replace($Map, '\u0026', '&');
- Save it

I've only tested it with the "XY - Single option" but all the others should probably work, too.

The old script failed because it tried to replace "sig" with "signature" which lead to:
"signaturenature". The shortform "sig" was already replaced (with the long form) by youtube...
One of my scripts helped you out? Please donate via Paypal

RalphM
Posts: 1932
Joined: 27 Jan 2005 23:38
Location: Cairns, Australia

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by RalphM »

Thanks highend that did the trick, works a treat now.
Haven't tested it with the other options of the script but I'm happy to use the XY single option.
Ralph :)
(OS: W11 22H2 Home x64 - XY: Current beta - Office 2019 32-bit - Display: 1920x1080 @ 125%)

klownboy
Posts: 4109
Joined: 28 Feb 2012 19:27

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by klownboy »

Thanks highend, your change worked for me as well. It also worked using VLC (single) though for some reason VLC crashes at the end and requires a restart. Even though VLC crashes, the downloads have been fine and play using either VLC or my associated program MPC-HC. Thanks highend for taking the time to figure out why it wasn't working and updating. We haven't heard from 40K in a while.
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by highend »

Is it only me or is it broken again?

E.g.: http://www.youtube.com/watch?v=frPxeO7JP90

Trying to get "[022] 720p - MP4"

fails...
One of my scripts helped you out? Please donate via Paypal

klownboy
Posts: 4109
Joined: 28 Feb 2012 19:27

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by klownboy »

Hey highend, failed for me as well. "failed to create file". I can't be sure of course, but many or these errors in the past have been due to the symbols used in the title. Probably because the resultant file name is based on the darn title which in many cases has these @ symbols and brackets etc which can foul up the naming (regex possibly). If that's the case maybe something different should be done in the file naming convention.
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by highend »

Hi Ken,

yeah, you're right regarding this specific video.

The "|" in the title of the video is the problem.

To make it work, these two lines have to be replaced:

Code: Select all

 $g_MetaTitle = replacelist ($g_MetaTitle, '/-,-\-:-*-?-<->-"-|', , "-", 0);
 $g_MetaDescription = replacelist ($g_MetaDescription, '/-,-\-:-*-?-<->-"-|', , "-", 0);
with e.g.:

Code: Select all

 $g_MetaTitle = regexreplace($g_MetaTitle, "(\\|/|,|:|\*|\?|""|<|>|\|)");
 $g_MetaDescription = regexreplace($g_MetaDescription, "(\\|/|,|:|\*|\?|""|<|>|\|)");
But it fails on a few more videos (this time it's not about the title).

Mind to test e.g. this one as well?

http://www.youtube.com/watch?v=t5VRiNOnGQE

All available formats fail to download...
One of my scripts helped you out? Please donate via Paypal

40k
Posts: 234
Joined: 09 Dec 2011 21:25

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by 40k »

klownboy wrote:Thanks highend, your change worked for me as well. It also worked using VLC (single) though for some reason VLC crashes at the end and requires a restart. Even though VLC crashes, the downloads have been fine and play using either VLC or my associated program MPC-HC. Thanks highend for taking the time to figure out why it wasn't working and updating. We haven't heard from 40K in a while.
Somebody called? :D

I thought this project had been abandoned by the user base. In fairness, I have been working with Python for most of the past year.
Let me dig up my old sources and see what is going wrong.

The problem is that Youtube will arbitrarily change things on their site. That can cause problems for this script.
I develop scripts that integrate media functionality into Xyplorer.
Hash - Twitch.tv in VLC (NEW 2.0!) - FFmpeg GUI - Youtube downloading
XYplorer for Linux! Tutorial

klownboy
Posts: 4109
Joined: 28 Feb 2012 19:27

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by klownboy »

The previous link now worked with your change, but as you said the avatar link failed...Download failed for URL: " download ($g_PlayableUrl, "$g_Downloads\$g_MetaTitle$g_VersionsMenuChoiceExt", o);" I tried in a few formats. All no go.
I see 40K is still with us. :)
Windows 11, 22H2 Build 22621.1555 at 100% 2560x1440

40k
Posts: 234
Joined: 09 Dec 2011 21:25

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by 40k »

I've had a look at what changed with Youtube. The long and short of it is that there's way too many different scenarios for the script to deal with.

I would recommend moving to a program like youtube-dl. If you peek at their source you'll notice that their YT date extraction module alone is 2000 lines of python code.

VLC has issues with their parsing engine for youtube as well. They write their stuff in Lua and I have 0.0 level of knowledge of that language.
I develop scripts that integrate media functionality into Xyplorer.
Hash - Twitch.tv in VLC (NEW 2.0!) - FFmpeg GUI - Youtube downloading
XYplorer for Linux! Tutorial

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by highend »

One of my scripts helped you out? Please donate via Paypal

RalphM
Posts: 1932
Joined: 27 Jan 2005 23:38
Location: Cairns, Australia

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by RalphM »

highend wrote:I'd recommend http://mrs0m30n3.github.io/youtube-dl-gui/
Had a look at this but got a bit lost in the prerequisites and different Python versions.
Could you give a bit more info on installing this on W8.1-64?

Thanks in advance.
Ralph :)
(OS: W11 22H2 Home x64 - XY: Current beta - Office 2019 32-bit - Display: 1920x1080 @ 125%)

highend
Posts: 13274
Joined: 06 Feb 2011 00:33

Re: Youtube.com 0.6.5 - Update to VLC 2.1.2

Post by highend »

Just install & start it. All the requirements are fulfilled through the files in the installation dir, e.g.:

ffmpeg.exe
ffprobe.exe
python27.dll
wxbase30u_net_vc90.dll
wxbase30u_vc90.dll
wxmsw30u_adv_vc90.dll
wxmsw30u_core_vc90.dll
wxmsw30u_html_vc90.dll
etc.

It's running fine on Windows Server 2012 R2 x64
One of my scripts helped you out? Please donate via Paypal

Post Reply