Kodi Community Forum
Release YouTube (IMPORTANT - READ FIRST POST) - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Video Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=154)
+---- Thread: Release YouTube (IMPORTANT - READ FIRST POST) (/showthread.php?tid=200735)



RE: YouTube (IMPORTANT - READ FIRST POST) - misty01 - 2016-03-08

Since I wrote the new API key entry in add-on settings I can tell you that you should not include " .apps.googleusercontent.com " if you enter the keys via GUI or if you manually edit the kodi/userdata/addon_data/plugin.video.youtube/settings.xml file. If you are including " .apps.googleusercontent.com ", then you will have something that looks like 871556748454-d6dlm3lg05idd8npdk18k6be4ba3oc68.apps.googleusercontent.com.apps.googleusercontent.com which is not right.

Code:
from login_client.py

'youtube-for-kodi-15': {
     'system': 'Isengard',
     'key': '%s' % api_key,
     'id': '%s.apps.googleusercontent.com' % api_id,  <<< Here you see I did not remove " .apps.googleusercontent.com " from the key string
     'secret': '%s' % api_secret



RE: YouTube (IMPORTANT - READ FIRST POST) - nickr - 2016-03-08

(2016-03-07, 12:57)mandricus Wrote: Hi guys. First of all, thank you for your great efforts on the plugin. I really appreciate it, as you are trying to restore this important Kodi functionality. Please don't mind useless people ranting about the fact that the plugin is not working. I see that you are trying to do your best in order to find a viable solution and a viable approach. This is not easy but I'm pretty sure a solution will be found.

As far as I can understand, there is still a pretty amount of work to be done before the plugin can be declared stable and pushed into the Kodi repository.

From an user perspective: if you want to have a working Youtube plugin in Kodi, there are two options at the moment:

1) Wait for the development of the plugin. Some day this plugin will be pushed in the main Kodi repository, and people will receive the update via the usual Kodi plugins update method.

2) Try to manually update the plugin with the version still in development (it will require a certain amount of skills).

Regarding point 2), I think would be useful for the users to have a reference post always updated with latest install instructions.

There are a lot of post in this thread from different users providing install instructions. I think a reference post, regularly updated by the developers, would be useful for all users wondering what they have to do in order to install and test the plugin.

This could also help to spread plugin usage, and to gather more feedback from users (but please make clear to the users that the plugin is still a work in progress)

AFAIK at the moment these are the steps needed in order to install the plugin:


1)

Delete

$KODI/userdata/addon_data/plugin.video.youtube folder

$KODI/addons/plugin.video.youtube

2) restart kodi.


3) Download latest version of the plugin in development from https://github.com/Kolifanes/plugin.video.youtube/releases . Put the .zip file into a folder readable by Kodi. Install the plugin from the .zip file (Settings → Add-ons → Install from zip file -> Navigate to the ZIP file)


you should be gold at that point, if it still doesn't work go ahead and get the kodi.log file.

see http://kodi.wiki/view/Log_file/Easy


Please correct / integrate steps if needed.
Stuff like this belongs on the wiki.


RE: YouTube (IMPORTANT - READ FIRST POST) - garfin - 2016-03-08

(2016-03-08, 03:29)misty01 Wrote: Since I wrote the new API key entry in add-on settings I can tell you that you should not include " .apps.googleusercontent.com "

Cheers misty01, That is what i had thought, based on what i could see as far as 'Default" info was showing in the new API tab in GUI.

Unsure why it is not authenticating with my keys though.. I think i'll need to logout, uninstall the plug-in, delete the $KODI/userdata/addon_data/plugin.video.youtube
& $KODI/addons/plugin.video.youtube folders, and install once more from zip. Reading further it seems i then need to get my keys into the plug-in BEFORE i ever login or perform the 2 x http://youtube.com/activate

(which is what i thought i did, but maybe I pooched a step.)


RE: YouTube (IMPORTANT - READ FIRST POST) - garfin - 2016-03-08

Nope... retried and still same issue... it bawks at initial sign in , after performing the first http://youtube.com/activate ..


RE: YouTube (IMPORTANT - READ FIRST POST) - *Spider* - 2016-03-08

(2016-03-08, 04:15)garfin Wrote: Reading further it seems i then need to get my keys into the plug-in BEFORE i ever login or perform the 2 x http://youtube.com/activate

That is plain wrong and will result in an authentication failure error msg. Your first ever login with the 2 x authentication is done 'before' adding your 3 strings of keys. Then you add the keys, click OK, logout, login again with the second 2 x authentication and you're done.
It's really not that hard to do.


RE: YouTube (IMPORTANT - READ FIRST POST) - garfin - 2016-03-08

(2016-03-08, 04:34)*Spider* Wrote: It's really not that hard to do.

Hi, apparently it IS that hard to do. I've followed your steps to the letter , and its not working (for me).

Should it matter that i chose ENGLISH and Worldwide(ALL) for language , during setup ?

Should it matter that the API keys I generated, were generated by me, whilst logged into my Youtube (gmail) account, the same account that i have the Plug-in associated with ?

(other than that, i'm damned if i can figure out why the .4/.5 plugins are not working with my GUI entered API keys.)


*Update* - So, I generated yet another set of keys, from a gmail account that is *NOT* the gmail account that i use within Kodi/YouTube , and NOW it works.. (a worthy gotcha?)


RE: YouTube (IMPORTANT - READ FIRST POST) - olinart - 2016-03-08

Hi Mandricus,
Excuse me for just starting with kodi, so perhaps I've done something stupid, but your procedure seemed straighforward.
I tried it without success with plugin.video.youtube-5.1.20.4 obtained from github.
Message that flashed on the screen was approximately

Failed to load zip file - bad structure.

kodi.log extract :
18:24:09 13.210279 T:1957691952 NOTICE: WebServer: Started the webserver
18:24:09 13.210688 T:1957691952 NOTICE: starting upnp client
18:24:22 25.713184 T:1957691952 ERROR: Window Translator: Can't find window settingsprofile
18:24:22 26.126221 T:1771623408 WARNING: CSkinInfo: failed to load skin settings
18:24:26 30.172968 T:1957691952 ERROR: Window Translator: Can't find window settingsprofile
18:24:45 49.026840 T:1957691952 ERROR: GetDirectory - Error getting zip://%2fhome%2fosmc%2fplugin.video.youtube-5.1.20.4.zip/
18:25:29 93.056496 T:1957691952 NOTICE: Storing total System Uptime
18:25:29 93.057236 T:1957691952 NOTICE: Saving settings
18:25:29 93.095650 T:1957691952 NOTICE: stop all

Possibly related: Nothing seems to work with plugin.video.youtube-5.1.17. Live error says "deleted project" and browse error
has illegal content".

Not sure if the substitution of %2f for / in the log file is a concern.

Thanks for any insight into this.

(2016-03-07, 12:57)mandricus Wrote: ....
2) Try to manually update the plugin with the version still in development (it will require a certain amount of skills).

....

AFAIK at the moment these are the steps needed in order to install the plugin:


1)

Delete

$KODI/userdata/addon_data/plugin.video.youtube folder

$KODI/addons/plugin.video.youtube

2) restart kodi.


3) Download latest version of the plugin in development from https://github.com/Kolifanes/plugin.video.youtube/releases . Put the .zip file into a folder readable by Kodi. Install the plugin from the .zip file (Settings → Add-ons → Install from zip file -> Navigate to the ZIP file)


you should be gold at that point, if it still doesn't work go ahead and get the kodi.log file.

see http://kodi.wiki/view/Log_file/Easy


Please correct / integrate steps if needed.



RE: YouTube (IMPORTANT - READ FIRST POST) - jdf76 - 2016-03-08

When i asked Bromix what the keys did he told me this.

(2015-08-02, 20:57)bromix Wrote: Thanks Smile and sure I can answer that.

The first key is for YouTube TV for TVs. We need that key for one function only -> My Subscribtions (new uploaded videos by all your subscribed channels), because the official new APIv3 for developer doesn't know such a thing, but users demand it. So that's my solution.

The second key is for the official APIv3 so we can use all the other stuff.

If Google/YouTube hasn't don't such a bad job with the new API we would not need two logins.

Jeff


(2016-03-08, 04:34)*Spider* Wrote:
(2016-03-08, 04:15)garfin Wrote: Reading further it seems i then need to get my keys into the plug-in BEFORE i ever login or perform the 2 x http://youtube.com/activate

That is plain wrong and will result in an authentication failure error msg. Your first ever login with the 2 x authentication is done 'before' adding your 3 strings of keys. Then you add the keys, click OK, logout, login again with the second 2 x authentication and you're done.
It's really not that hard to do.



RE: YouTube (IMPORTANT - READ FIRST POST) - garfin - 2016-03-08

(2016-03-08, 08:24)jdf76 Wrote: When i asked Bromix what the keys did he told me this.

(2015-08-02, 20:57)bromix Wrote: Thanks Smile and sure I can answer that.

The first key is for YouTube TV for TVs. We need that key for one function only -> My Subscribtions (new uploaded videos by all your subscribed channels), because the official new APIv3 for developer doesn't know such a thing, but users demand it. So that's my solution.

The second key is for the official APIv3 so we can use all the other stuff.

If Google/YouTube hasn't don't such a bad job with the new API we would not need two logins.

Jeff

Hi Jeff, Yes, misty01 explained how he uses the 3 API keys , in his post.. (and doesn't touch the YouTube TV Key)
http://forum.kodi.tv/showthread.php?tid=200735&pid=2270600#pid2270600


What wasnt immediately apparent to me, was, there seems to be an issue when the keys you personally generate, are generated from the SAME gmail account as you have associated with the add-on.
(In other words, Best to create a dummy gmail account to create your keys with.. And don't use the one you sign into YouTube normally with, and have all your subscribed channels tied to.)


RE: YouTube (IMPORTANT - READ FIRST POST) - *Spider* - 2016-03-08

(2016-03-08, 08:39)garfin Wrote: What wasnt immediately apparent to me, was, there seems to be an issue when the keys you personally generate, are generated from the SAME gmail account as you have associated with the add-on.
(In other words, Best to create a dummy gmail account to create your keys with.. And don't use the one you sign into YouTube normally with, and have all your subscribed channels tied to.)

Wrong again @garfin. That is misleading information which will confuse anyone who thinks you know what you are doing.
I have a single Gmail account associated with my Kodi YouTube addon.
I created my keys while logged into my single Gmail account.
I carefully copied my generated keys to my Raspberry Pi and Nexus Player and now YouTube is golden.

I believe the *only* reason it worked for you after creating a dummy gmail acct is because you were more careful the 2nd time around with your newly generated keys and no other reason.
No one should be creating a dummy gmail account, that is completely ridiculous.

Your previous questions would make a perfect FAQ.

Should it matter that i chose ENGLISH and Worldwide(ALL) for language , during setup ?

Those are my exact settings.

Should it matter that the API keys I generated, were generated by me, whilst logged into my Youtube (gmail) account, the same account that i have the Plug-in associated with ?

It is supposed to be associated with your same account. That is why it works so perfectly.


RE: YouTube (IMPORTANT - READ FIRST POST) - garfin - 2016-03-08

Ok,happy to be proven wrong. Well done.

I retract any suggestion that i know what i'm doing, or that keys need to be created under a different account, however..

Browser API key
Use this key in your web application
API requests are sent directly to Google from your users' browser. Learn more

API key
AIzaSyCPCQqyuev0wSi5236lbfLC1F0d4VC7Acw
Creation date Mar 7, 2016, 3:46:03 PM

for whatever reason, THIS original key i created simply does not work (for me)... I have subsequently generated a new key , under my same gmail account that Kodi/add-in is associated with.. (see pic)
https://dl.dropboxusercontent.com/u/3516400/Keys.JPG
and that subsequent key works, so maybe its youtube/google that gets key generation wrong sometimes .. (still using same Oauth pair i had generated y'day.. those seem ok)


RE: YouTube (IMPORTANT - READ FIRST POST) - mandricus - 2016-03-08

(2016-03-08, 02:52)jdf76 Wrote: Looking back i think i found the guy who wrote the API instructions

2213129 (post)

Thanks. Useful post.


RE: YouTube (IMPORTANT - READ FIRST POST) - mandricus - 2016-03-08

(2016-03-08, 06:08)olinart Wrote: Hi Mandricus,
Excuse me for just starting with kodi, so perhaps I've done something stupid, but your procedure seemed straighforward.
I tried it without success with plugin.video.youtube-5.1.20.4 obtained from github.
Message that flashed on the screen was approximately

Failed to load zip file - bad structure.

kodi.log extract :
18:24:09 13.210279 T:1957691952 NOTICE: WebServer: Started the webserver
18:24:09 13.210688 T:1957691952 NOTICE: starting upnp client
18:24:22 25.713184 T:1957691952 ERROR: Window Translator: Can't find window settingsprofile
18:24:22 26.126221 T:1771623408 WARNING: CSkinInfo: failed to load skin settings
18:24:26 30.172968 T:1957691952 ERROR: Window Translator: Can't find window settingsprofile
18:24:45 49.026840 T:1957691952 ERROR: GetDirectory - Error getting zip://%2fhome%2fosmc%2fplugin.video.youtube-5.1.20.4.zip/
18:25:29 93.056496 T:1957691952 NOTICE: Storing total System Uptime
18:25:29 93.057236 T:1957691952 NOTICE: Saving settings
18:25:29 93.095650 T:1957691952 NOTICE: stop all

Possibly related: Nothing seems to work with plugin.video.youtube-5.1.17. Live error says "deleted project" and browse error
has illegal content".

Not sure if the substitution of %2f for / in the log file is a concern.

Thanks for any insight into this.

Looks like you are downloading from a wrong path.
This is the link to the 5.1.20.4 version:

https://github.com/Kolifanes/plugin.video.youtube/releases/download/5.1.20.4/plugin.video.youtube-5.1.20.4.zip

You need to download the zip from a computer, put it on a filesystem accessible via KODI, then install the plugin from the .zip file


RE: YouTube (IMPORTANT - READ FIRST POST) - Edgeshark - 2016-03-08

(2016-03-07, 18:28)gitman Wrote: thanks for the update, hope to see it in the official repo soon.

question - the "Recommended for You" list has always shown up empty for me, even on the original Youtube 5.x. does anyone else have this problem?

Yes, we have the same problem with the "Recommended for You" list. This is the one item that keeps my wife from using the app compared to the PS3 Youtube app. Is this fixed with the API issue that is discussed here?


RE: YouTube (IMPORTANT - READ FIRST POST) - jdf76 - 2016-03-09

You'd have to try it to see if it's fixed. I noticed different people have different results.

Jeff

(2016-03-08, 17:32)Edgeshark Wrote:
(2016-03-07, 18:28)gitman Wrote: thanks for the update, hope to see it in the official repo soon.

question - the "Recommended for You" list has always shown up empty for me, even on the original Youtube 5.x. does anyone else have this problem?

Yes, we have the same problem with the "Recommended for You" list. This is the one item that keeps my wife from using the app compared to the PS3 Youtube app. Is this fixed with the API issue that is discussed here?