[PLUGIN] YouTube for Volumio

@Michelangelo,

Just saw there is a new stable version 2.368 out since a very short time.
I did the update that ended in an error with v2.362 - will retest this tommorow on v2.368 an report back.

  • Josef

Thank you! Great work, fixed my youtube plugin problems.

Canā€™t working again.
Today I got this message:

Mar 03 06:18:12 haloszoba volumio[1175]: info: CoreCommandRouter::executeOnPlugin: youtube , handleBrowseUri
Mar 03 06:18:12 haloszoba volumio[1175]: info: handleBrowseUri: youtube
Mar 03 06:18:12 haloszoba volumio[1175]: error: Access Not Configured. YouTube Data API has not been used in project 119103001349 before or it is disabled. Enable it by visiting console.developers.google.com/a ā€¦ 9103001349 then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.
Mar 03 06:18:12 haloszoba volumio[1175]: Error: Access Not Configured. YouTube Data API has not been used in project 119103001349 before or it is disabled. Enable it by visiting console.developers.google.com/a ā€¦ 9103001349 then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.
Mar 03 06:18:12 haloszoba volumio[1175]: at Request._callback (/data/plugins/music_service/youtube/node_modules/google-auth-library/lib/transporters.js:85:15)
Mar 03 06:18:12 haloszoba volumio[1175]: at Request.self.callback (/data/plugins/music_service/youtube/node_modules/request/request.js:186:22)
Mar 03 06:18:12 haloszoba volumio[1175]: at emitTwo (events.js:106:13)
Mar 03 06:18:12 haloszoba volumio[1175]: at Request.emit (events.js:191:7)
Mar 03 06:18:12 haloszoba volumio[1175]: at Request. (/data/plugins/music_service/youtube/node_modules/request/request.js:1163:10)
Mar 03 06:18:12 haloszoba volumio[1175]: at emitOne (events.js:96:13)
Mar 03 06:18:12 haloszoba volumio[1175]: at Request.emit (events.js:188:7)
Mar 03 06:18:12 haloszoba volumio[1175]: at IncomingMessage. (/data/plugins/music_service/youtube/node_modules/request/request.js:1085:12)
Mar 03 06:18:12 haloszoba volumio[1175]: at IncomingMessage.g (events.js:292:16)
Mar 03 06:18:12 haloszoba volumio[1175]: at emitNone (events.js:91:20)
Mar 03 06:18:12 haloszoba volumio[1175]: at IncomingMessage.emit (events.js:185:7)
Mar 03 06:18:12 haloszoba volumio[1175]: at endReadableNT (_stream_readable.js:974:12)
Mar 03 06:18:12 haloszoba volumio[1175]: at _combinedTickCallback (internal/process/next_tick.js:80:11)
Mar 03 06:18:12 haloszoba volumio[1175]: at process._tickCallback (internal/process/next_tick.js:104:9)
Mar 03 06:18:12 haloszoba volumio[1175]: info: CoreCommandRouter::volumioGetState
Mar 03 06:18:12 haloszoba volumio[1175]: info: CoreStateMachine::getState
Mar 03 06:18:12 haloszoba volumio[1175]: info: CorePlayQueue::getTrack 0
Mar 03 06:18:12 haloszoba volumio[1175]: info: Listing playlists
Mar 03 06:18:12 haloszoba volumio[1175]: info: Listing playlists
Mar 03 06:18:20 haloszoba volumio[1175]: error: TypeError: Cannot read property ā€˜0ā€™ of undefined
Mar 03 06:18:20 haloszoba volumio[1175]: at /volumio/app/plugins/music_service/upnp_browser/index.js:78:52
Mar 03 06:18:20 haloszoba volumio[1175]: at /volumio/app/plugins/music_service/upnp_browser/index.js:594:21
Mar 03 06:18:20 haloszoba volumio[1175]: at Parser. (/volumio/node_modules/xml2js/lib/xml2js.js:489:18)

They changed something in the Youtube API?
How can we solve it?

Hi,

the YouTube plugin donā€™t working for 3 daysā€¦

I tried uninstall it and install it again, same error message : ā€œan error occured while browsing the folderā€

thanks

Based on the log posted above it looks like Google has changed the terms of service for using the API and the dev just needs to go in and accept the new terms. I followed the link myself and it is asking me to accept but I didnā€™t want to accept on his behalf (assuming it would actually work anyway)

While starting the youtube-Plugin i get a red error in the upper right side:

Browse error An error occured while browsing the folder

i try reinstalling the plugin without success.

hello,
itā€™s not working anyway.

the dev of the plugin needs to accept the new terms of his project/api.
thanks.

Hello,

I have the same problem with youtube plugin : ā€œan error occurred while browsing the folderā€. I even reflash Volumio, the problem persist.
Here are the logs:

Mar 11 07:25:59 volumio volumio[825]: info: handleBrowseUri: youtube
Mar 11 07:25:59 volumio volumio[825]: error: Access Not Configured. YouTube Data API has not been used in project 119103001349 before or it is disabled. Enable it by visiting console.developers.google.com/a ā€¦ 9103001349 then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.
Mar 11 07:25:59 volumio volumio[825]: Error: Access Not Configured. YouTube Data API has not been used in project 119103001349 before or it is disabled. Enable it by visiting console.developers.google.com/a ā€¦ 9103001349 then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.
Mar 11 07:25:59 volumio volumio[825]: at Request._callback (/data/plugins/music_service/youtube/node_modules/google-auth-library/lib/transporters.js:85:15)
Mar 11 07:25:59 volumio volumio[825]: at Request.self.callback (/data/plugins/music_service/youtube/node_modules/request/request.js:186:22)
Mar 11 07:25:59 volumio volumio[825]: at emitTwo (events.js:106:13)
Mar 11 07:25:59 volumio volumio[825]: at Request.emit (events.js:191:7)
Mar 11 07:25:59 volumio volumio[825]: at Request. (/data/plugins/music_service/youtube/node_modules/request/request.js:1163:10)
Mar 11 07:25:59 volumio volumio[825]: at emitOne (events.js:96:13)
Mar 11 07:25:59 volumio volumio[825]: at Request.emit (events.js:188:7)
Mar 11 07:25:59 volumio volumio[825]: at IncomingMessage. (/data/plugins/music_service/youtube/node_modules/request/request.js:1085:12)
Mar 11 07:25:59 volumio volumio[825]: at IncomingMessage.g (events.js:291:16)
Mar 11 07:25:59 volumio volumio[825]: at emitNone (events.js:91:20)

Hi all,

the source of the problem is the used API key.

I have informed Cris about this issue.

The plugin works as it should when you grant volumio access to your youtube account because then a different authentication mechanism is used.

Again: when you grant volumio access to your youtube account all it does is listing channels, playlists and vidoes you have subscribed. We are not collecting data or use it in any other way. You can take a look at the source code.

With best regards,
Stefan

Dear Stefan,

How can I grant the access to the Youtube plugin? I try to add the code (what I see in the pluginā€™s config) on the google.com/device site but I get an invalid code, try again error.

Thanks.
Peter

Awesome, thanks for the information it is working now. I was always too lazy to enable my account but I will from now on.

I had the same error and the easy fix was to go to the installed plugins page and disable the Youtube plugin, wait about 5 seconds and turn it back on. This made it generate a new code which was valid - it must need to generate a new code every so often after a reboot or after activating the plugin.

Dear Rees,

Thanks my friend, as you described it was succeeded me too.

It would be advisable to write down the solution in the description of the plugin so that me have to ask for fewer unnecessary questions. :slight_smile:

There are no unnecessary question. It only shows that the usability of the plugin is not that good at the moment.

But to be honest I had to do a workaround when I have implemented the Google OAuth stuff because there were no features like opening an URL from the configuration page and stuff like that. Now volumio supports that

Seems to be a bug. When I have tested it I have always tried to grant permissions immediately and never waited for several seconds. This could be fixed by calling self.getAccessToken(); before displaying the configuration.

But after the configuration was successful you donā€™t have to grant volumio access after a reboot, right?

Hi! First of all congratulations for the plugin, it is brilliant!

I have only a questionā€¦ I have a playlist with more then 50 songs. Whatever i do, I see only the first 50 songsā€¦

Can you help me?

Tanks a lot

PS
Sorry for my englischā€¦ :unamused:

Have you tried to increase the number of shown videos in the settings?

Thanks for the answer!

How can I do it? :confused: :slight_smile:

Hello, iā€™d like to use x86 version of Volumio but Main plugins are missing, is there some guide or walthrough to build them ? Or thereā€™s online version ?

Thank you and Happy Easter :wink:

Bad news again.
I got that error:

Apr 01 18:53:30 nappali volumio[872]: error: Daily Limit Exceeded. The quota will be reset at midnight Pacific Time (PT). You may monitor your quota usage and adjust limits in the API Console: console.developers.google.com/a ā€¦ 3050398935
Apr 01 18:53:30 nappali volumio[872]: Error: Daily Limit Exceeded. The quota will be reset at midnight Pacific Time (PT). You may monitor your quota usage and adjust limits in the API Console: console.developers.google.com/a ā€¦ 3050398935

I donā€™t understand that because I barely used Youtube today.
Have any suggestions for someone?
Thanks.

Hi To Allā€¦

since yesterday my youtube plugin stopped workingā€¦ api key is validā€¦ but the plugin says something about. " An error occured while browsing folder "

i did renew the api code i already uninstalled the plugin and reinstalledā€¦ reboot the device but nothing seems to workā€¦
is there any fix for thisā€¦??

best regards Osdiemanā€¦

Go to Plugins -> Installed Plugins and there you find Youtube Settings. :slight_smile:

I have never tried to use the plugin on an x86 platform. What do you mean with Main plugin?

Yes, I can explain that to you. Currently the youtube plugin uses the free to use Google Youtube v3 API. All users of the plugin use the same API key. That means we (all volumio youtube plugin user) are allowed to create 1.000.000 queries per day. Yesterday we have done 1.000.000 queries. Normally we have about 200.000 to 300.000 (on weekends). So wow. I would never expect that so many people are using my plugin. :open_mouth:

To be able to increase this quota I would have to pay for it and I wonā€™t do that, I am sorry. I have already told this Michelangelo a long time ago but I cannot tell you whether the volumio team is willing to to pay for the API usage.

When I have developed the plugin my first idea was that each user has to generate a own key but I think that you cannot expect that from every user for usability reasons.

But when the usage of the plugin will increase and the quota will be reached more often AND the volumio team is not willing to pay for the API usage I will change this.

I will talk with Michelangelo again and explain him the situation.

To decrease the number of queries automatically done I will move the activities list into a folder and query it only when the user wants to see it. That should also improve the usage of the plugin.

Can you send me some logs? On my installation the plugin works as expected. Here are the instructions how to get the log files: volumio.github.io/docs/User_Man ā€¦ oting.html