Kodi Community Forum
YouTube Plug-in Thread - 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: YouTube Plug-in Thread (/showthread.php?tid=353278)



RE: YouTube Plug-in Thread - registeringisnotfun - 2018-04-09

(2018-04-08, 16:45)blueribb Wrote:
(2018-04-08, 15:59)registeringisnotfun Wrote: can anyone please address the issue of live tv channels on youtube only playing for a few seconds and then kicking you out.  i tried turning on the MPEG-DASH but it makes no difference.  This happens for many arabic live tv stations on YT.  This has been an issue for several weeks now so hoping someone can look at this.  I have version 5.5.1 on Kodi 17.6 on a windows 10 pc.

Thanks for the efforts.
Did you try the latest development version ?

https://github.com/jdf76/plugin.video.youtube/releases/tag/6.0.0-dev 
thanks blueribb...i looked at the github and i see it requires input.adaptive of 2.0.28   - where would i get this? my version of Kodi 17.6 has 2.0.19.  

thanks


RE: YouTube Plug-in Thread - blueribb - 2018-04-09

(2018-04-09, 16:48)registeringisnotfun Wrote:
(2018-04-08, 16:45)blueribb Wrote:
(2018-04-08, 15:59)registeringisnotfun Wrote: can anyone please address the issue of live tv channels on youtube only playing for a few seconds and then kicking you out.  i tried turning on the MPEG-DASH but it makes no difference.  This happens for many arabic live tv stations on YT.  This has been an issue for several weeks now so hoping someone can look at this.  I have version 5.5.1 on Kodi 17.6 on a windows 10 pc.

Thanks for the efforts.
Did you try the latest development version ?

https://github.com/jdf76/plugin.video.youtube/releases/tag/6.0.0-dev  
thanks blueribb...i looked at the github and i see it requires input.adaptive of 2.0.28   - where would i get this? my version of Kodi 17.6 has 2.0.19.  

thanks 
 I'm not sure but I think this is the source for the latest inputstream.adaptive: https://github.com/peak3d/inputstream.adaptive


RE: YouTube Plug-in Thread - TB22 - 2018-04-09

Hi.

I'm having trouble playing certain youtube videos. I get a message 'Playback failed - One or more items failed to play. Check the log for more information about this message.'. Here's my debug log after a fresh start trying to play a failing video: http://ix.io/17kw
I tried installing the latest youtube plugin from GitHub (plugin.video.youtube-6.0.0.beta8.zip) but it makes no difference.

How do I fix this? Or: how do I even find out what's wrong, since the debug log isn't very helpful at all, giving no indication of what the error actually is.

Thanks!


RE: YouTube Plug-in Thread - registeringisnotfun - 2018-04-09

(2018-04-09, 17:06)blueribb Wrote:
(2018-04-09, 16:48)registeringisnotfun Wrote:
(2018-04-08, 16:45)blueribb Wrote: Did you try the latest development version ?

https://github.com/jdf76/plugin.video.youtube/releases/tag/6.0.0-dev  
thanks blueribb...i looked at the github and i see it requires input.adaptive of 2.0.28   - where would i get this? my version of Kodi 17.6 has 2.0.19.  

thanks  
 I'm not sure but I think this is the source for the latest inputstream.adaptive: https://github.com/peak3d/inputstream.adaptive 
 thanks for offering that up...unfortunately Kodi 17.6 fails to insall the zip so that unfortunately will not resolve the issues.  pity.  hopefully someone can resolve these issues soon cause there's some great live tv on YT.  thanks again.


RE: YouTube Plug-in Thread - anxdpanic - 2018-04-09

@misc123 Looks like a network/Internet issue, a debug_log (wiki) may reveal more.

@DjDiabolik The live stream isn't available to test currently

@registeringisnotfun As with DjDiabolik's issue, I will need a video id so I can hopefully reproduce. InputStream Adaptive >=2.0.12 is required for Live, 2.0.28 was for Purchases and is now 2.2.12 for Purchases. InputStream Adaptive cannot be installed from zip, it can be installed at Kodi installation, in some cases can be updated via apt, otherwise requires compiling.

@TB22 It wasn't finding any available streams(why I can't be sure), I just tested here and it is finding them.

@dabisu Settings - General - Thumbnail size

I've updated post #2 with ~beta9
[upd] Purchases
        - requires Kodi 18
        - requires inputstream.adaptive >= 2.2.12
        - if a purchase fails after 10 seconds
            - provide a debug log
            - set InputStream Adaptive -> Settings -> Stream selection -> manual
            - change video stream during playback to preferred working resolution
        - huge thanks to peak3d


RE: YouTube Plug-in Thread - sisypheantask - 2018-04-09

Broken livestream video IDs (using 17.6 stock, basically nothing installed that isn't official other than Yatse)

https://www.youtube.com/watch?v=wJUwiWwKUNc
https://www.youtube.com/watch?v=00CSlKmSvwU
https://www.youtube.com/watch?v=Rs4dBCOmoP0
https://www.youtube.com/watch?v=Z90p8T5DW7Q

I don't know what adaptivestream I do or don't have or how to upgrade. This is a new stock install of Kodi on Ubuntu 17.04.


RE: YouTube Plug-in Thread - anxdpanic - 2018-04-09

@sisypheantask All of those work fine here.

To check your version and that inputstream.adaptive is installed: Add-ons - My add-ons - VideoPlayer InputStream
I believe to update/install inputstream.adaptive on Ubuntu is 'sudo apt-get install kodi-inputstream-adaptive'

Ensure Settings - MPEG-DASH - Use MPEG-DASH is enabled


RE: YouTube Plug-in Thread - sisypheantask - 2018-04-09

I was able to install kodi-inputstream-adaptive 2.0.19 with that apt-get command, turned on MPEG-DASH, went into its settings to configure inputstream settings and it asked me to enable it which I did. The streams are working now! Big Grin Hopefully this will work out of the box with version 18, I'm very new to Kodi and quite impressed with it.


RE: YouTube Plug-in Thread - DjDiabolik - 2018-04-10

@anxdpanic thanks for info.... now know it's not my only issue Smile

Tomorrow i can update to beta 9......


RE: YouTube Plug-in Thread - TB22 - 2018-04-10

(2018-04-09, 18:07)anxdpanic Wrote: @TB22 It wasn't finding any available streams(why I can't be sure), I just tested here and it is finding them.
Well, it doesn't work for me. What can I do?

EDIT: well I went ahead and littered methods.py with logging statements. Here's my modified source: http://ix.io/17tK And here's the logging output that produces: https://bpaste.net/raw/c43a063a6ea9

Seems like the problem is with this comprehension:

python:
stream_data_list = [item for item in stream_data_list
   if (item.get('dash/audio', False) and
   not item.get('dash/video', False))]
Seems to filter all streams.

Disabling audio_only in the settings solved the problem. But this must be a bug nonetheless, or I'm misunderstanding the 'audio only' setting. I don't need video, just audio. And there are plenty of streams available that could provide audio. Not sure why they're all filtered.


RE: YouTube Plug-in Thread - anxdpanic - 2018-04-10

@TB22  Thanks for following up and investigating further. Audio only explains the issue. For that video there are only audio+video streams. I've added a fix to GitHub master that will fail over to video stream if no audio only streams are available.


RE: YouTube Plug-in Thread - TB22 - 2018-04-12

(2018-04-10, 17:44)anxdpanic Wrote: @TB22 For that video there are only audio+video streams. I've added a fix to GitHub master that will fail over to video stream if no audio only streams are available.
 Thank you. However, I don't quite understand why it would not be possible to just play the audio from the audio+video stream. For me, playing video is a problem (*complicated details below) and as far as I understand it, audio and video are always separate in these container formats. I.e., the streams listed in https://bpaste.net/raw/c43a063a6ea9 have AAC and Vorbis audio components. Is it not possible to playback only the audio component, even if the stream also carries video? Worst case, could the video component simply be "blacked out" or something, so it does not need to be rendered on-screen?

* The machine is headless - there is no display connected. There might be a bug in X or in the intel driver, but I cannot get video acceleration to work properly like this, and this is a known problem: If I don't connect a display, the intel driver is used but connecting via x11vnc is extremely, excruciatingly slow and if I create a dummy display to solve this, then the intel driver cannot be used and X will use software rendering, which is to slow even for a youtube video and then the audio stutters as well. But nevermind all this, I think it should technically be possible to only play back audio from a youtube stream; is this incorrect?


Scheduling a download - RKCRLR - 2018-04-13

Hello
I live in a rural area where only metered internet is available.  I'm allowed 10 GB per month during the day but have an additional 50 GB during the hours of 2 am to 8 am that I rarely use.  Is it possible to schedule downloads of YouTube videos in Kodi?  I'm running LibreELEC on an Android box.  I can do it in Windows using a download manager but it would be nice to be able to do this from Kodi.  
Thanks in advance for any help.


RE: YouTube Plug-in Thread - misc123 - 2018-04-14

Quote:@misc123 Looks like a network/Internet issue, a debug_log (wiki) may reveal more.
@anxdpanic Thank you for your reply.

I fresh installed Kodi 17.6 and Youtube 5.5.1 and randomly played a video from "Popular right now"
Here is my debug_log :
https://paste.kodi.tv/iqijijameh

Thank you again for your time.


RE: YouTube Plug-in Thread - Arokhaerr - 2018-04-15

Today I again got a video which cannot be played again. I'll send a complete log when I have local  access and am back at home.

The log related to that video is this so far though if it helps:
Code:
01:45:48.106 T:1471148784 NOTICE: [plugin.video.youtube] Running: YouTube (6.0.0~beta9) on Leia (Kodi-18.0) with Python 2.7.13
Path: /play/
Params: {'video_id': 'QNgyopA2vWI'}
01:45:50.136 T:1471148784 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <type 'exceptions.UnicodeEncodeError'>
Error Contents: 'ascii' codec can't encode character u'\xf6' in position 40: ordinal not in range(128)
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 43, 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 23, in run
results = provider.navigate(context)
File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube_plugin/kodion/abstract_provider.py", line 87, in navigate
result = method(context, re_match)
File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube_plugin/kodion/register_provider_path.py", line 11, in wrapper
return func(*args, **kwargs)
File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube_plugin/youtube/provider.py", line 505, in on_play
return yt_play.play_video(self, context, re_match)
File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube_plugin/youtube/helper/yt_play.py", line 80, in play_video
context.get_ui().show_notification(message, time_milliseconds=15000)
File "/home/osmc/.kodi/addons/plugin.video.youtube/resources/lib/youtube_plugin/kodion/impl/xbmc/xbmc_context_ui.py", line 122, in show_notification
"Notification(%s, %s, %d, %s)" % (_header, _message, time_milliseconds, _image))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xf6' in position 40: ordinal not in range(128)
-->End of Python script error report<--
01:45:50.386 T:1922703696 ERROR: Playlist Player: skipping unplayable item: 0, path [plugin://plugin.video.youtube/play/?video_id=QNgyopA2vWI]

[Edit]
With the logfile updater it was easier than i thought. Heres the full log:
http://paste.kodi.tv/noyaluzova