0xced / XCDYouTubeKit

YouTube video player for iOS, tvOS and macOS
MIT License
2.92k stars 627 forks source link

-2 The operation couldn’t be completed. (XCDYouTubeVideoErrorDomain error -2.) #382

Closed sixty8 closed 6 years ago

sixty8 commented 6 years ago

Is this the end of XCDYouTubeVideo?

SoneeJohn commented 6 years ago

It appears to be an issue with a JavaScript function. A possible fix was proposed here

https://github.com/rg3/youtube-dl/pull/17464

I will work on implementing this fix and running the unit tests that the library contains to confirm. However, I won’t be able to until this weekend. Maybe @0xced might have it fixed by then. :-)

SoneeJohn commented 6 years ago

See #383 by @marktgodfrey

yangjianwei2015 commented 6 years ago

https://github.com/0xced/XCDYouTubeKit/pull/383/files

yangjianwei2015 commented 6 years ago

thank you marktgodfrey

darkForestCat commented 6 years ago

@yangjianwei2015 does this work right now, still getting the errors also after @marktgodfrey fix in the XCDYouTubePlayerScript.m file.May be I am doing something in a wrong way?

darkForestCat commented 6 years ago

Figured out that this is working in the demo project, so that is only my problem that this is not working in mine.

dimacorp commented 6 years ago

@darkForestCat hey, how do you request this specific commit/pull request with a podfile? I tried the following: pod "XCDYouTubeKit", :git => 'https://github.com/0xced/XCDYouTubeKit.git', :branch => 'master', :commit => 'bf5cfb4'

pod update worked ok but it looks the code is still original (don't see the proposed fix).

darkForestCat commented 6 years ago

@dimacorp Firstly I did it in the Xcode, just edited the file, but Xcode as the best app for programming had some problems and my macbook went down, after re-opening it I figured out that nothing changed, so I just downloaded the original file, edited it and moved it inside the folder of project.Now everything is working well, so I can go eat my strudel, yeah;)

JmyW commented 6 years ago

Can 0xced help to add the solution in code for cocoapod? thank you so much!

JmyW commented 6 years ago

Same as @darkForestCat, moved all lib. files into my project for resolving it. :-)

JmyW commented 6 years ago

Are you guys still workable? I'm getting error again today :-(

JmyW commented 6 years ago

Thanks, @SoneeJohn. Your solution is worked fine. Thank you.

SoneeJohn commented 6 years ago

Fixed in version 2.6.0