Discussion:
Bug#632922: Fails to extract audio from file whose name begins with hyphen
(too old to reply)
Matt Kraai
2011-07-07 02:20:01 UTC
Permalink
Package: youtube-dl
Version: 2011.02.25b-1

Hi,

When I ran

youtube-dl --extract-audio


youtube-dl failed with the following error:

WARNING: unable to obtain file audio codec with ffprobe

I believe that this occurs because the file downloaded by youtube-dl
is -8PwoNXXE3M.flv so ffprobe interprets the file name as an option.
--
Matt Kraai
https://ftbfs.org/kraai
--
To UNSUBSCRIBE, email to debian-bugs-dist-***@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact ***@lists.debian.org
Rogério Brito
2011-07-07 02:30:01 UTC
Permalink
Hi, Matt.
Post by Matt Kraai
I believe that this occurs because the file downloaded by youtube-dl
is -8PwoNXXE3M.flv so ffprobe interprets the file name as an option.
Yes, the fix is probably simple, depending on how ffprobe/ffmpeg
parses the command line (with -- or prefixing the filename with ./).

I will see if upstream has something on the way or I will fix that myself.

Thanks for reporting it.
--
Rogério Brito : rbrito@{ime.usp.br,gmail.com} : GPG key 4096R/BCFCAAAA
http://rb.doesntexist.org : Packages for LaTeX : algorithms.berlios.de
DebianQA: http://qa.debian.org/developer.php?login=rbrito%40ime.usp.br
--
To UNSUBSCRIBE, email to debian-bugs-dist-***@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact ***@lists.debian.org
Matt Kraai
2011-07-07 02:30:01 UTC
Permalink
Post by Rogério Brito
Hi, Matt.
Post by Matt Kraai
I believe that this occurs because the file downloaded by youtube-dl
is -8PwoNXXE3M.flv so ffprobe interprets the file name as an option.
Yes, the fix is probably simple, depending on how ffprobe/ffmpeg
parses the command line (with -- or prefixing the filename with ./).
I will see if upstream has something on the way or I will fix that myself.
Thanks for reporting it.
I'm currently testing the attached fix.
--
Matt Kraai
https://ftbfs.org/kraai
Rogério Brito
2011-07-07 02:40:01 UTC
Permalink
Hi, Matt.
Post by Matt Kraai
Post by Rogério Brito
Yes, the fix is probably simple, depending on how ffprobe/ffmpeg
parses the command line (with -- or prefixing the filename with ./).
I'm currently testing the attached fix.
Oh, great. I think that the ./ is indeed the most robust option anyway... :-)

I will push that patch upstream, if you license it under the public domain.
--
Rogério Brito : rbrito@{ime.usp.br,gmail.com} : GPG key 4096R/BCFCAAAA
http://rb.doesntexist.org : Packages for LaTeX : algorithms.berlios.de
DebianQA: http://qa.debian.org/developer.php?login=rbrito%40ime.usp.br
--
To UNSUBSCRIBE, email to debian-bugs-dist-***@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact ***@lists.debian.org
Matt Kraai
2011-07-07 03:40:01 UTC
Permalink
tag 632922 patch
thanks
Post by Rogério Brito
Hi, Matt.
Post by Matt Kraai
Post by Rogério Brito
Yes, the fix is probably simple, depending on how ffprobe/ffmpeg
parses the command line (with -- or prefixing the filename with ./).
I'm currently testing the attached fix.
And it doesn't work. The path to the file generated by ffmpeg also
needs to be escaped. I verified that the attached patch does work.
Post by Rogério Brito
Oh, great. I think that the ./ is indeed the most robust option anyway... :-)
I will push that patch upstream, if you license it under the public domain.
I'm happy to license the patch under the public domain. Is this email
sufficient?
--
Matt Kraai
https://ftbfs.org/kraai
Rogério Brito
2011-07-07 04:00:02 UTC
Permalink
Hi, Matt.
And it doesn't work.  The path to the file generated by ffmpeg also
needs to be escaped.  I verified that the attached patch does work.
Yes, escaped in more than one place.
I'm happy to license the patch under the public domain.  Is this email
sufficient?
AFAIK, it is. I will put it in my git tree and put it upstream.


Regards,
--
Rogério Brito : rbrito@{ime.usp.br,gmail.com} : GPG key 4096R/BCFCAAAA
http://rb.doesntexist.org : Packages for LaTeX : algorithms.berlios.de
DebianQA: http://qa.debian.org/developer.php?login=rbrito%40ime.usp.br
--
To UNSUBSCRIBE, email to debian-bugs-dist-***@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact ***@lists.debian.org
Loading...