gst-launch-1.0 YouTube fails with gst_base_src_loop:<souphttpsrc0> error: Internal data stream error
Hello.
I tried to use gst-launch-1.0 to test YouTube video as instructed here: http://lifestyletransfer.com/how-to-watch-youtube-videos-with-gstreamer/
However it does not work and gives "Internal data stream error" in gstbasesrc.c:3072:gst_base_src_loop:
My Linux distro is 64-bit Gentoo and I have the following gst* packages & versions installed:
gst-python-1.16.2
gst-plugins-bad-1.16.2
gst-plugins-base-1.16.2
gst-plugins-good-1.16.2
gst-plugins-ugly-1.16.2
gstreamer-1.16.2
gst-plugins-gtk-1.16.2
gst-plugins-libav-1.14.4
And here's the complete error:
GST_DEBUG="*:2" gst-launch-1.0 -v souphttpsrc is-live=true method=get location="$(youtube-dl
--format "best[ext=mp4][protocol=https]" --get-url https://www.youtube.com/watch?v=ndl1W4ltcmg)" !
decodebin ! videoconvert ! autovideosink
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
0:00:00.015278918 17150 0x55c294c10030 WARN structure
gststructure.c:1861:priv_gst_structure_append_to_gstring: No value transform to serialize field
'session' of type 'SoupSession'
Got context from element 'souphttpsrc0': gst.soup.session=context, session=(SoupSession)NULL, force=
(boolean)false;
Setting pipeline to PLAYING ...
New clock: GstSystemClock
0:00:00.140221724 17150 0x55c294adeb70 WARN basesrc
gstbasesrc.c:3072:gst_base_src_loop:<souphttpsrc0> error: Internal data stream error.
0:00:00.140280433 17150 0x55c294adeb70 WARN basesrc
gstbasesrc.c:3072:gst_base_src_loop:<souphttpsrc0> error: streaming stopped, reason error (-5)
0:00:00.140351666 17150 0x55c294adeb70 WARN typefind
gsttypefindelement.c:986:gst_type_find_element_chain_do_typefinding:<typefind> error: Stream doesn't
contain enough data.
0:00:00.140373016 17150 0x55c294adeb70 WARN typefind
gsttypefindelement.c:986:gst_type_find_element_chain_do_typefinding:<typefind> error: Can't typefind
stream
ERROR: from element /GstPipeline:pipeline0/GstSoupHTTPSrc:souphttpsrc0: Internal data stream error.
Additional debug info:
/var/tmp/portage/media-libs/gstreamer-1.16.2/work/gstreamer-1.16.2/libs/gst/base/gstbasesrc.c(3072):
gst_base_src_loop (): /GstPipeline:pipeline0/GstSoupHTTPSrc:souphttpsrc0:
streaming stopped, reason error (-5)
Execution ended after 0:00:00.125129037
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...