Kodi Community Forum

Full Version: YouTube Plug-in Thread
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Running plugin ver. 5.50 on Krypton 17.6, Windows 7, 10, Android

Lately I cannot get a live video to play. It used to. My specific example is the live stream of the PBS Newshour. I can view the recorded video fine when it's all over, but the live stream is my fall-back for days on which my primary live source (The Wisconsin Channel) is down.

The live stream takes longer to load than it used to, then starts, freezes, and eventually drops out. It doesn't matter whether I opt for 720p, 480p or 360p (or lower!). All behave in the same way.

Any one else with live stream issues? Or maybe it's just this one?
@Thinaran The next alpha will have a change in this area as well as more detailed logging. If it's not resolved we should be able narrow down the video so we can resolve it.

@DjDiabolik It's due to the 2to3 conversion, should have an update with that resolved soon.

@pa786 debug_log (wiki)

@nmyshkin HLS live streams are currently not working. Currently for working live streams you must have InputStream Adaptive >= 2.0.12 and have Settings - MPEG-DASH enabled.
Updated post #2 with alpha2

~alpha2
  • [add] Settings -> API -> Enable API configuration page
    • when enabled, visit http://ipaddress:port/api to configure API keys from a web browser
    • port is configured in Settings - HTTP Server - Port
  • [chg] Python 3 compat. module from future to six
  • [upd] Greek strings [twilight0]
I have right now install the alpha2 of 6.0.0-unofficial:
Thanks @anxdpanic because now apparently all section it's works and apparently all video it's ok from all section but there's another addictional little trouble.

When i open the "My Subscription" (filter or not) the list of video it's correctly loaded but immediatelly after it, on my tv, appears a notification say again to see the log and report this error:
Code:
03:09:47.409 T:1294140160  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:09:49.640 T:1294140160   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.NameError'>
                                            Error Contents: global name 'xbmc' is not defined
                                            Traceback (most recent call last):
                                              File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/default.py", line 7, in <module>
                                                runner.run(__provider__)
                                              File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube_plugin/kodion/runner.py", line 41, in run
                                                __RUNNER__.run(provider, context)
                                              File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube_plugin/kodion/impl/xbmc/xbmc_runner.py", line 64, in run
                                                xbmc.executebuiltin('Container.SetViewMode(%d)' % view_mode)
                                            NameError: global name 'xbmc' is not defined
                                            -->End of Python script error report<--

I hope always to do somethigs pleasant when i report this personal feedback..........

*EDIT*
After some test......... i have found the possibly cause.
From the preferences i have disabled the option for FORCE Setview. Previously i have set both value to 55 and all works. But if enable the forceviews i obtain this errors........
This is my settings:
Code:
    <setting id="kodion.view.default" value="55" />
    <setting id="kodion.view.episodes" value="55" />
    <setting id="kodion.view.override" value="true" />
Whit view override disable no errors....... whit override activate i obtain the errors on log posted above..... it's a invalid id the cause ? I don't have idea Smile


*EDIT 2*
From original post it's a new day right now... in italy it's around 10:30AM and i have some bad news.
Last night, beforse i go to sleep, i have report this feedback whit alpha2 unofficial 6.0.0.... apparently all works whitout any problems (whitout the ovveride feature no errors notification appears) but now i have some troubles.
I have turned on my Pi2 about 5 minutes ago and from addons all video i try to reproduce nothigs append..... i can see the "blue spin" on tv for about 1 or 2 sec and nothings. Simply back to the all video list....... this append in all section........ on log it's appears a message say somethigs about unplayable id 0 or similar (i can't post the parts of log right uppers right now.... try to do this later).

**EDIT 3**
This is the part of log when try to reproduce some video, and goes in errors, from "My Subscriction":
Code:
03:28:42.229 T:1310917376  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:28:59.409 T:1925683712  NOTICE: Previous line repeats 1 times.
03:28:59.409 T:1925683712   ERROR: Playlist Player: skipping unplayable item: 0, path [plugin://plugin.video.youtube/play/?video_id=OpjJRUWq9Go]
03:29:37.201 T:1925683712   ERROR: Control 55 in window 10025 has been asked to focus, but it can't
03:29:40.360 T:1294140160  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:32:07.291 T:1925683712  NOTICE: Previous line repeats 3 times.
03:32:07.291 T:1925683712   ERROR: GetDirectory - Error getting plugin://plugin.video.youtube/video/more/?refresh_container=0&logged_in=1&video_id=8SyWJIv3fc4
03:32:07.308 T:1925683712   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.youtube/video/more/?refresh_container=0&logged_in=1&video_id=8SyWJIv3fc4) failed
03:33:41.192 T:1310917376  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:40:08.440 T:1925683712  NOTICE: Previous line repeats 8 times.
03:40:08.440 T:1925683712   ERROR: GetDirectory - Error getting plugin://plugin.video.youtube/video/more/?refresh_container=0&logged_in=1&video_id=xU6NzGFQQLg
03:40:08.456 T:1925683712   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.youtube/video/more/?refresh_container=0&logged_in=1&video_id=xU6NzGFQQLg) failed
03:40:18.250 T:1294140160  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:40:21.819 T:1925683712  NOTICE: VideoPlayer: Opening:
03:40:21.819 T:1925683712 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
03:40:21.820 T:1310917376  NOTICE: Creating InputStream
03:40:21.835 T:1310917376   ERROR: Error on dvdnav_open
03:40:21.835 T:1310917376   ERROR: CVideoPlayer::OpenInputStream - error opening
03:40:21.835 T:1310917376  NOTICE: CVideoPlayer::OnExit()
03:40:21.846 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:40:21.846 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:40:21.846 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:40:21.846 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:40:21.846 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:40:21.846 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:40:25.038 T:1294140160  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:40:47.056 T:1925683712  NOTICE: Previous line repeats 1 times.
03:40:47.056 T:1925683712  NOTICE: VideoPlayer: Opening:
03:40:47.056 T:1925683712 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
03:40:47.057 T:1294140160  NOTICE: Creating InputStream
03:40:47.058 T:1294140160   ERROR: Error on dvdnav_open
03:40:47.058 T:1294140160   ERROR: CVideoPlayer::OpenInputStream - error opening
03:40:47.058 T:1294140160  NOTICE: CVideoPlayer::OnExit()
03:40:47.067 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:40:47.067 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:40:47.067 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:40:47.068 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:40:47.068 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:40:47.068 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:40:50.312 T:1310917376  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:40:57.363 T:1925683712  NOTICE: Previous line repeats 1 times.
03:40:57.364 T:1925683712  NOTICE: VideoPlayer: Opening:
03:40:57.364 T:1925683712 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
03:40:57.365 T:1294140160  NOTICE: Creating InputStream
03:40:57.366 T:1294140160   ERROR: Error on dvdnav_open
03:40:57.367 T:1294140160   ERROR: CVideoPlayer::OpenInputStream - error opening
03:40:57.367 T:1294140160  NOTICE: CVideoPlayer::OnExit()
03:40:57.368 T:1925683712   ERROR: Playlist Player: skipping unplayable item: 0, path [plugin://plugin.video.youtube/play/?video_id=xU6NzGFQQLg]
03:40:57.369 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:40:57.369 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:40:57.369 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:40:57.370 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:40:57.370 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:40:57.370 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:41:00.628 T:1310917376  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:41:09.673 T:1925683712  NOTICE: Previous line repeats 1 times.
03:41:09.674 T:1925683712  NOTICE: VideoPlayer: Opening:
03:41:09.674 T:1925683712 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
03:41:09.675 T:1628418816  NOTICE: Creating InputStream
03:41:09.676 T:1628418816   ERROR: Error on dvdnav_open
03:41:09.676 T:1628418816   ERROR: CVideoPlayer::OpenInputStream - error opening
03:41:09.676 T:1628418816  NOTICE: CVideoPlayer::OnExit()
03:41:09.677 T:1925683712   ERROR: Playlist Player: skipping unplayable item: 0, path [plugin://plugin.video.youtube/play/?video_id=x2Vv6oBlCWM]
03:41:09.691 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:41:09.691 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:41:09.691 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:41:09.692 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:41:09.692 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:41:09.692 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:41:12.947 T:1310917376  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:41:22.285 T:1925683712  NOTICE: Previous line repeats 1 times.
03:41:22.285 T:1925683712  NOTICE: VideoPlayer: Opening:
03:41:22.285 T:1925683712 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
03:41:22.286 T:1628418816  NOTICE: Creating InputStream
03:41:22.287 T:1628418816   ERROR: Error on dvdnav_open
03:41:22.287 T:1628418816   ERROR: CVideoPlayer::OpenInputStream - error opening
03:41:22.287 T:1628418816  NOTICE: CVideoPlayer::OnExit()
03:41:22.288 T:1925683712   ERROR: Playlist Player: skipping unplayable item: 0, path [plugin://plugin.video.youtube/play/?video_id=xU6NzGFQQLg]
03:41:22.302 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:41:22.302 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:41:22.302 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:41:22.302 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:41:22.303 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:41:22.303 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:41:25.475 T:1310917376  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:41:26.972 T:1925683712   ERROR: GetDirectory - Error getting plugin://plugin.video.youtube/kodion/search/list/
03:41:26.989 T:1925683712   ERROR: CGUIMediaWindow::GetDirectory(plugin://plugin.video.youtube/kodion/search/list/) failed
03:41:29.357 T:1294140160  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:42:06.513 T:1925683712   ERROR: Control 55 in window 10025 has been asked to focus, but it can't
03:42:14.937 T:1310917376  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:42:29.490 T:1925683712  NOTICE: Previous line repeats 1 times.
03:42:29.490 T:1925683712  NOTICE: VideoPlayer: Opening:
03:42:29.490 T:1925683712 WARNING: CDVDMessageQueue(player)::Put MSGQ_NOT_INITIALIZED
03:42:29.491 T:1319305984  NOTICE: Creating InputStream
03:42:29.495 T:1319305984   ERROR: Error on dvdnav_open
03:42:29.495 T:1319305984   ERROR: CVideoPlayer::OpenInputStream - error opening
03:42:29.495 T:1319305984  NOTICE: CVideoPlayer::OnExit()
03:42:29.496 T:1925683712   ERROR: Playlist Player: skipping unplayable item: 0, path [plugin://plugin.video.youtube/play/?video_id=1wubsZDPH9s]
03:42:29.497 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:42:29.497 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:42:29.497 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:42:29.498 T:1925683712  NOTICE: CVideoPlayer::CloseFile()
03:42:29.498 T:1925683712  NOTICE: VideoPlayer: waiting for threads to exit
03:42:29.498 T:1925683712  NOTICE: VideoPlayer: finished waiting
03:42:29.499 T:1059255040   ERROR: GetDirectory - Error getting /home/osmc/.kodi/temp/plugin.video.youtube/
03:42:29.499 T:1059255040   ERROR: GetDirectory - Error getting special://temp/plugin.video.youtube/
03:42:32.796 T:1294140160  NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~alpha2) on Krypton (Kodi-17.6) with Python 2.7.13
03:52:41.552 T:1925683712  NOTICE: stop all
03:52:41.553 T:1925683712  NOTICE: stop player
03:52:41.553 T:1925683712  NOTICE: ES: Stopping event server
It's a part of last night test.................. at 3:52AM it's goin to sleep after try to see some video Smile

Ah.... i don't use DASH..... i don't have tryed whit dash enabled because after the recent changes it's not most clearly on my head how i need to set all preferences Smile
Today and tomorrow will be much busier than usual so I've bumped the alpha version early with some fixes, please include debug_log (wiki) with any issues.

See post #2 
  • [fix] known alpha2 issues
To anyone testing, thanks for your patience and feedback. Adding python 3 compatibility means changes to most files so there is lots of room to break things.

@DjDiabolik This should resolve the views override in unofficial, and fix the playback issue of non-dash content
OMG thanks..... tonigh i can test this newest alpha 3. Thanks Smile


*EDIT*
@anxdpanic 

I have right now install alpha3-unofficial............. if i understand correctly for the live show it's works only whit DASH enabled ?? I have tryed to access to one and it's start a for 1 or 2 seconds..... make somethigs like a loop and after exactly 4 seconds the stream it's stop and it's back to video list title. it's correct ? The live show it's work only whit dash enabled and correctly setted ?
@DjDiabolik Correct, see the first 2 posts of this page.
Within the last couple of days I started getting a login exception, unauthorized client error on kodi 17.6 LibreElec.  Looks like it started around the latest update to 5.5 on the 29th of January.  Any idea what this is all about?
The last few days im getting errors about the videos being flagged for mature content when trying to watch trailers of god of war ps4 for example. I dont know the exact english term for it because i got it in german. I have set settings "age gate" disabled and "allow mature content" enabled.

What am I doing wrong?
@garydebergerac 
if when signing in you get -- invalid_client : oauth client not found -- the client id is incorrect.
if when signing in you get -- invalid_client : unauthorized -- the client secret is incorrect.
if you try to access anything that requires api(ie. Popular right now) and get an error it's the api key.

@Arokhaerr
Im going to guess you're on 5.4.5 and the "allow mature content" you're referring to is "Allow offensive content" 
"allow offensive content" was removed in 5.5.0, and the "age gate" setting is to enforce the age gate on some age-gated content when not signed it.
There are a few different ways content is age-gated by YouTube and some require login.
If you're on 5.5.0, signed in and still unable to view the video. Please provide at least the video id so I can attempt to reproduce, a debug_log (wiki) could be helpful too.
(2018-02-03, 16:16)anxdpanic Wrote: [ -> ]@garydebergerac 
if when signing in you get -- invalid_client : oauth client not found -- the client id is incorrect.
if when signing in you get -- invalid_client : unauthorized -- the client secret is incorrect.
if you try to access anything that requires api(ie. Popular right now) and get an error it's the api key.
Ok, I assume this means I have to set up all the API stuff on the first page?  I haven't done any of that at this point.

Edit, for anyone else coming across this, even though I hadn't activated the API keys in the configuration, I was still getting this error.  Activating the API keys in the configuration and then adding the keys fixed it.
(2018-02-03, 16:16)anxdpanic Wrote: [ -> ]@Arokhaerr
Im going to guess you're on 5.4.5 and the "allow mature content" you're referring to is "Allow offensive content" 
"allow offensive content" was removed in 5.5.0, and the "age gate" setting is to enforce the age gate on some age-gated content when not signed it.
There are a few different ways content is age-gated by YouTube and some require login.
If you're on 5.5.0, signed in and still unable to view the video. Please provide at least the video id so I can attempt to reproduce, a debug_log (wiki) could be helpful too.
 https://youtu.be/rW-BArWIpD8 is one of the videos which wont play for me.

I am running the latest 5.5.0 on milhouse LE9

Location is germany. Video runs fine on android yt app an in browser.
Where can I post feature requests for this plugin ? Thanks
Hi All!

I just ran into the YouTube 'Daily Limit Exceeded-YouTube quota Exceeded' error today and I registered to this forum only to say thanks for the awesome, simple and useful description in this topic that not only solved the issue, but also provided some explanation. I'm running the latest OSMC on a Rasperry PI 3 and I use the latest YouTube add-on from Bromix. So, thank you very much and I hope that if I stick around I'll be able to contribute to the community. Wink

Cheers,
Loky
Thank you for your appreciation, enjoy Smile