mozilla / popcorn-js

The HTML5 Media Framework. (Unmaintained. See https://github.com/menismu/popcorn-js for activity)
MIT License
2.14k stars 631 forks source link

Removed dependency on deprecated Youtube data API v2. #441

Closed syl22-00 closed 9 years ago

syl22-00 commented 9 years ago

This is a fix for issue #440 . Instead of using Youtube's data API, duration can be retrieved from the player itself.

stevemao commented 9 years ago

This needs to be quickly merged as YouTube is not working at all.

syl22-00 commented 9 years ago

Indentation fix is done.

cadecairos commented 9 years ago

I'm not sure why the data api was used initially, perhaps @ScottDowne can speak to that, but why not update it to use the latest V3 API? https://developers.google.com/youtube/v3/docs/videos#contentDetails.duration

mjschranz commented 9 years ago

99% certain the original reason was to ensure proper duration data because of all the inconsistencies they have had. Perhaps things are better now?

syl22-00 commented 9 years ago

Youtube data API v3 seems to require an API token or authentication, and there is a usage quota. So it might not be great to rely on it.

mjschranz commented 9 years ago

Perhaps. I'll poke/prod at @ScottDowne to try and remember why (although I think I'm correct) and hopefully we can get something fixed soon.

oligibson commented 9 years ago

@ScottDowne can this merge be tagged as anyone using bower to manage their versions won't get this fix.

westis commented 9 years ago

Is there any way to update manually with a fix for YouTube, before there is another release? We depend on this for a solution for city council meetings, and they are wondering why it's not working.

ScottDowne commented 9 years ago

I tagged v1.5.11 for the youtube fix.

westis commented 9 years ago

Thanks. I suppose I then need to compile popcorn.min.js with the make-file somehow? For a "beginner" it's not quite clear what I need to do, as simply downloading the library did not work, but I still need a popcorn.min.js file. I'd be really grateful for some guidance.

kreynen commented 9 years ago

Downloading "the latest" release of Popcorn.js is confusing. Latest Release tag is pinned to 1.5.2 on GitHub. When users visit https://github.com/mozilla/popcorn-js/releases, they have to know to click on the ". . . 9 newer tags" to see any releases after that.

selection_031

http://popcornjs.org/download points to 1.5.6.

mjschranz commented 9 years ago

I'm not really sure why that is happening in the Github UI as the newer tags clearly exist.

I don't believe we ever will get an up to date http://popcornjs.org website so the main means for pulling in the script files now will either be downloading the zip from Github itself or from bower and then running the Make file.

In truth we really should just include a minified version in the root of the repo for people to make the bower use case much simpler.

kreynen commented 9 years ago

Releases and tags are not the same on GitHub. If the 1.5.2 "release" is deleted, all of the tags will be listed with the newest on top. If you don't want to delete that, someone had to add a release for each tag.

https://help.github.com/articles/editing-and-deleting-releases/

cemerson commented 8 years ago

Can anyone help a Makefile noob get a build of 1.5.11 (or close)? I've wasted 2 hours with cygwin, mingw, vstudio command prompt etc and just can't get this Makefile to run (closest I get is some Interrupt/Exception error after a handful of File not founds for popcorn.*.unit.js. Super frustrating! Anyone care to help a noob out? I'd use that build tool but it only uses 1.5.6 and doesn't seem to have this YouTube fix.

cadecairos commented 8 years ago

@cemerson I've got an old build tool running here: http://popcorn-js.chrisdecairos.ca/ but it's building v1.5.7

cemerson commented 8 years ago

Thanks @cadecairos I was trying that ... but I'm not sure if the YouTube fix is in 1.5.7. Initial tests look like it's not.

cadecairos commented 8 years ago

I'll see if I can get an updated version up there

cemerson commented 8 years ago

Thank you @cadecairos - much appreciated!

cadecairos commented 8 years ago

@cemerson okay, http://popcorn-js.chrisdecairos.ca/ is now serving up popcorn-js v1.5.11

I even took the time to update all the apps dependencies, so it's using the latest uglify-js to minify.

source code of the build tool is here: https://github.com/cadecairos/popcorn-build-tool

cemerson commented 8 years ago

@cadecairos you are my hero man! Thank you! I can confirm YouTube happiness w/this 1.5.11 version! (at least so far). Again - thank you sir! All of us noobs who can't figure out Makefile stuff owe you!

cadecairos commented 8 years ago

Don't worry, makefiles are the worst - especially on Windows.

Popcorn should really be using a node powered build system...