YoutubeExtractor icon indicating copy to clipboard operation
YoutubeExtractor copied to clipboard

Could not parse the Youtube page for URL http://youtube.com/watch?v=

Open hazemkut1993 opened this issue 7 years ago • 15 comments

i'm using YoutubeExtractor in my vb.net project to download the youtube

but i'm getting this erorr

Could not parse the Youtube page for URL http://youtube.com/watch?v=YQHsXMglC9A This may be due to a change of the Youtube page structure. Please report this bug at www.github.com/flagbug/YoutubeExtractor/issues

this image for the erorr

https://i.imgur.com/g8bUrlk.png

my code is

Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
        Dim vInfos As IEnumerable(Of VideoInfo)
        vInfos = DownloadUrlResolver.GetDownloadUrls(TextBox1.Text, False)


        ComboBox1.Items.Clear()

        Dim listDL As New List(Of String)
        Dim listExt As New List(Of String)

        Dim blnFlag As Boolean = True
        For Each vi As VideoInfo In vInfos
            If blnFlag = True Then
                strDefTitle = vi.Title
                blnFlag = False
            End If
            Dim strQuality As String
            strQuality = "Resoultion: " & vi.Resolution & " Format: " & vi.VideoExtension
            ComboBox1.Items.Add(strQuality)

            'If the video has a decrypted signature, decipher it
            If vi.RequiresDecryption Then
                DownloadUrlResolver.DecryptDownloadUrl(vi)
            End If

            listDL.Add(vi.DownloadUrl)
            listExt.Add(vi.VideoExtension)

        Next
        strArrayLinks = listDL.ToArray
        strArrayExts = listExt.ToArray

    End Sub

hazemkut1993 avatar Dec 10 '18 19:12 hazemkut1993

Hi hazemkut1993, I am also facing the same issue right now. Please let me know if you get any solution. Thanks

janakiram-a avatar Dec 12 '18 07:12 janakiram-a

I am working with c# and get the same error:

YoutubeExtractor.YoutubeParseException: 'Could not parse the Youtube page for URL http://youtube.com/watch?v=MwjsO6aniig This may be due to a change of the Youtube page structure. Please report this bug at www.github.com/flagbug/YoutubeExtractor/issues'

janluijk avatar Dec 13 '18 07:12 janluijk

I faced the same issue, here how I fixed it:

Replace GetHtml5PlayerVersion() in DownloadUrlResolver.cs with this:

private static string GetHtml5PlayerVersion(JObject json) { var regex = new Regex(@"player_ias-(.+?).js");

    string js = json["assets"]["js"].ToString();

    Match match = regex.Match(js);
    if (match.Success) return match.Result("$1");

    regex = new Regex(@"player-(.+?).js");
    
    return regex.Match(js).Result("$1");
}

You will then need to rebuild the YoutubeExtractor.dll and it should be good!

johnalp avatar Dec 13 '18 19:12 johnalp

I faced the same issue, here how I fixed it:

Replace GetHtml5PlayerVersion() in DownloadUrlResolver.cs with this:

private static string GetHtml5PlayerVersion(JObject json) { var regex = new Regex(@"player_ias-(.+?).js");

    string js = json["assets"]["js"].ToString();

    Match match = regex.Match(js);
    if (match.Success) return match.Result("$1");

    regex = new Regex(@"player-(.+?).js");
    
    return regex.Match(js).Result("$1");
}

You will then need to rebuild the YoutubeExtractor.dll and it should be good!

Hi johnalp, Your suggestion really helped me a lot. Many thanks and good wishes to you.

janakiram-a avatar Dec 14 '18 10:12 janakiram-a

Today: could not decipher signature issue

SoftwareMagicIT avatar Dec 15 '18 16:12 SoftwareMagicIT

Today: could not decipher signature issue

Try another youtube url to download. I had the same issue with my old test url. I tried new one and it worked.

janakiram-a avatar Dec 17 '18 04:12 janakiram-a

Please look at pull request #333 , I hope it will solve your problems.

anilgit90 avatar Dec 17 '18 08:12 anilgit90

I faced the same issue, here how I fixed it: Replace GetHtml5PlayerVersion() in DownloadUrlResolver.cs with this: private static string GetHtml5PlayerVersion(JObject json) { var regex = new Regex(@"player_ias-(.+?).js");

    string js = json["assets"]["js"].ToString();

    Match match = regex.Match(js);
    if (match.Success) return match.Result("$1");

    regex = new Regex(@"player-(.+?).js");
    
    return regex.Match(js).Result("$1");
}

You will then need to rebuild the YoutubeExtractor.dll and it should be good!

Hi johnalp, Your suggestion really helped me a lot. Many thanks and good wishes to you.

Can you help me? I don't know how to fix it! Hope you help me! My FB: https://www.facebook.com/phong.truong.1990

kumkumbum001 avatar Jan 03 '19 16:01 kumkumbum001

I faced the same issue, here how I fixed it:

Replace GetHtml5PlayerVersion() in DownloadUrlResolver.cs with this:

private static string GetHtml5PlayerVersion(JObject json) { var regex = new Regex(@"player_ias-(.+?).js");

    string js = json["assets"]["js"].ToString();

    Match match = regex.Match(js);
    if (match.Success) return match.Result("$1");

    regex = new Regex(@"player-(.+?).js");
    
    return regex.Match(js).Result("$1");
}

You will then need to rebuild the YoutubeExtractor.dll and it should be good!

Give me the file please YoutubeExtractor.dll can you fix the error? My mail: [email protected]

kumkumbum001 avatar Jan 03 '19 16:01 kumkumbum001

I faced the same issue, here how I fixed it: Replace GetHtml5PlayerVersion() in DownloadUrlResolver.cs with this: private static string GetHtml5PlayerVersion(JObject json) { var regex = new Regex(@"player_ias-(.+?).js");

    string js = json["assets"]["js"].ToString();

    Match match = regex.Match(js);
    if (match.Success) return match.Result("$1");

    regex = new Regex(@"player-(.+?).js");
    
    return regex.Match(js).Result("$1");
}

You will then need to rebuild the YoutubeExtractor.dll and it should be good!

Hi johnalp, Your suggestion really helped me a lot. Many thanks and good wishes to you.

Give me the file please YoutubeExtractor.dll can you fix the error? My mail: [email protected]

kumkumbum001 avatar Jan 03 '19 16:01 kumkumbum001

Hi kumkumbum001, you can stop to SPAM this thread? If you don't know how to solve, because info is very easy to this, we can't help you. Simply you need to edit DownloadUrlResolver.cs file in source code project, replace GetHtml5PlayerVersion() with piece of code suggested, recompile and use. If you don't know to made this, we can't help you!

SoftwareMagicIT avatar Jan 03 '19 17:01 SoftwareMagicIT

I don't know how to open the file DownloadUrlResolver.cs . Can you help me open that file?

Vào Th 6, 4 thg 1, 2019 vào lúc 00:13 Software Magic < [email protected]> đã viết:

Hi kumkumbum001, you can stop to SPAM this thread? If you don't know how to solve, because info is very easy to this, we can't help you. Simply you need to edit DownloadUrlResolver.cs file in source code project, replace GetHtml5PlayerVersion() with piece of code suggested, recompile and use. If you don't know to made this, we can't help you!

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/flagbug/YoutubeExtractor/issues/329#issuecomment-451211342, or mute the thread https://github.com/notifications/unsubscribe-auth/AsNG6aRub9faKg0suiTUHBWT93L9JhAVks5u_josgaJpZM4ZMBwb .

kumkumbum001 avatar Jan 04 '19 02:01 kumkumbum001

I don't want to spam, but I'm really having trouble! Can you send me YoutubeExtractor-Fix?

Vào Th 6, 4 thg 1, 2019 vào lúc 09:53 Trương Hoài Phong < [email protected]> đã viết:

I don't know how to open the file DownloadUrlResolver.cs . Can you help me open that file?

Vào Th 6, 4 thg 1, 2019 vào lúc 00:13 Software Magic < [email protected]> đã viết:

Hi kumkumbum001, you can stop to SPAM this thread? If you don't know how to solve, because info is very easy to this, we can't help you. Simply you need to edit DownloadUrlResolver.cs file in source code project, replace GetHtml5PlayerVersion() with piece of code suggested, recompile and use. If you don't know to made this, we can't help you!

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/flagbug/YoutubeExtractor/issues/329#issuecomment-451211342, or mute the thread https://github.com/notifications/unsubscribe-auth/AsNG6aRub9faKg0suiTUHBWT93L9JhAVks5u_josgaJpZM4ZMBwb .

kumkumbum001 avatar Jan 04 '19 03:01 kumkumbum001

No! On github the source code is shared to be improved by developers. If you do not know how to do it, you need to use stable release. If the stable release does not work, you have to wait for the owner to release a stable version. Alternatively you install Visual Studio Community, you download the source and you fill it in yourself, after the appropriate modifications. I do not want to be responsible for providing a dll compiled by me. If you repeat same message or similar message, you generate SPAM! If you need you can use edit function of comment

SoftwareMagicIT avatar Jan 04 '19 08:01 SoftwareMagicIT

I faced the same issue, here how I fixed it:

Replace GetHtml5PlayerVersion() in DownloadUrlResolver.cs with this:

private static string GetHtml5PlayerVersion(JObject json) { var regex = new Regex(@"player_ias-(.+?).js");

    string js = json["assets"]["js"].ToString();

    Match match = regex.Match(js);
    if (match.Success) return match.Result("$1");

    regex = new Regex(@"player-(.+?).js");
    
    return regex.Match(js).Result("$1");
}

You will then need to rebuild the YoutubeExtractor.dll and it should be good!

Thanks, you really helped a lot

rafadante avatar Feb 08 '19 16:02 rafadante