ytdl-org / youtube-dl

Command-line program to download videos from YouTube.com and other video sites
http://ytdl-org.github.io/youtube-dl/
The Unlicense
132.28k stars 10.03k forks source link

metadata from title not passed to metadata #8658

Closed keabro closed 8 years ago

keabro commented 8 years ago

The metadata from title argument changes file name, but does not add meta data to file. --add-metadata only adds the title as metadata.

verbose output

youtube-dl -v https://www.youtube.com/watch?v=81uHlxzM6KE
[debug] System config: [u'-x', u'--metadata-from-title', u'%(artist)s - %(title)s', u'--output', u'/media1/Media/Music/youtube/%(uploader)s/%(title)s.%(ext)s', u'--no-overwrites', u'--download-archive', u'/media1/Media/Music/youtube/dlarchive', u'--yes-playlist', u'--ignore-errors', u'--netrc', u'--ffmpeg-location', u'/usr/local/bin/ffmpeg', u'--audio-format', u'm4a', u'--audio-quality', u'0', u'--embed-thumbnail', u'--add-metadata']
[debug] User config: []
[debug] Command-line args: [u'-v', u'https://www.youtube.com/watch?v=81uHlxzM6KE']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2016.02.22
[debug] Python version 2.7.10 - Linux-4.2.0-27-generic-x86_64-with-Ubuntu-15.10-wily
[debug] exe versions: ffmpeg 3.0.git, ffprobe 3.0.git
[debug] Proxy map: {}
[youtube] Downloading login page
[youtube] Logging in
[youtube] 81uHlxzM6KE: Downloading webpage
[youtube] 81uHlxzM6KE: Downloading video info webpage
[youtube] 81uHlxzM6KE: Extracting video information
[youtube] 81uHlxzM6KE: Downloading MPD manifest
[youtube] 81uHlxzM6KE: Downloading thumbnail ...
[youtube] 81uHlxzM6KE: Writing thumbnail to: /media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'Donnell - It's All On U.jpg
[debug] Invoking downloader on u'https://r2---sn-n0qqxoapo3-jaae.googlevideo.com/videoplayback?requiressl=yes&lmt=1455312617758488&source=youtube&dur=204.201&gir=yes&key=yt6&signature=BC513F7E4F8CFE8EC92E840925612BE8C807C494.113186D9B37477CB99A10E2DD1851665A7A48509&fexp=9407117%2C9407610%2C9408212%2C9410705%2C9416126%2C9419452%2C9420452%2C9422596%2C9423060%2C9423661%2C9423662%2C9424724%2C9425731%2C9427000%2C9427365%2C9427614%2C9428649%2C9428709%2C9429152%2C9429298%2C9429599&clen=3352056&pcm2cms=yes&sparams=clen%2Cdur%2Cgir%2Cid%2Cinitcwndbps%2Cip%2Cipbits%2Citag%2Ckeepalive%2Clmt%2Cmime%2Cmm%2Cmn%2Cms%2Cmv%2Cpcm2cms%2Cpl%2Crequiressl%2Csource%2Cupn%2Cexpire&ipbits=0&initcwndbps=1927500&mime=audio%2Fwebm&pl=22&ip=50.24.189.72&ms=au&mt=1456369596&mv=m&id=o-AEhZpF1t3M9LPjvgH_HtnsnRyiQUHs6wPaSNNOr22py7&mm=31&mn=sn-n0qqxoapo3-jaae&keepalive=yes&sver=3&upn=FRI7afO_CbQ&expire=1456391340&itag=251&ratebypass=yes'
[download] Destination: /media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'Donnell - It's All On U.webm
[download] 100% of 3.20MiB in 00:00
[fromtitle] parsed artist: Illenium ft. Liam O'Donnell
[fromtitle] parsed title: It's All On U
[ffmpeg] Adding metadata to '/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'Donnell - It's All On U.webm'
[debug] ffmpeg command line: /usr/local/bin/ffmpeg -y -i 'file:/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.webm' -c copy -metadata 'comment=♫ Get it on iTunes: http://apple.co/1OmQT39
♫ Get it on Bandcamp: http://bit.ly/1OmR3aG

Illenium is back with his brand new album called '"'"'Ashes'"'"' including '"'"'It'"'"'s All On U ft. Liam O'"'"'Donnell'"'"'! OUT NOW!
[Genre: Melodic Dubstep/Electronic]

►Illenium:
https://soundcloud.com/illeniumofficial
https://twitter.com/ILLENIUMMUSIC
http://www.facebook.com/illenium
http://instagram.com/illeniummusic

►xKito Music:
https://www.facebook.com/xKitoMusic
https://twitter.com/xkito_music
https://instagram.com/xkito_m/
https://soundcloud.com/xkitomusic
https://www.youtube.com/c/xKitoMusic

►Submit your music to xKito:
https://xkito.toneden.io/

►PICTURE → http://www.pixiv.net/member_illust.php?mode=medium&illust_id=55190493
©Artwork by: hiko

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

►DONATE VIA PAYPAL OR PAYSAFE CARD → http://tinyurl.com/oh6c2vc
[If you decide to donate, please leave a note with your youtube name if you want that displayed instead of your real name. With paysafecards just send the code to my email: xkitomusic@gmail.com]

►List of donors:
https://docs.google.com/document/d/1YKBo40AOU4qe4bsuuGhvo2f0GlmlQQFT1LvbrXBxWJs/edit?usp=sharing&pageId=118298691797275305549

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

•IMPORTANT:
If any artist or label has copyright issues with my videos (including artists of the images used), please send an e-mail to: xkitomusic@gmail.com and I will remove it immediately!' -metadata 'description=♫ Get it on iTunes: http://apple.co/1OmQT39
♫ Get it on Bandcamp: http://bit.ly/1OmR3aG

Illenium is back with his brand new album called '"'"'Ashes'"'"' including '"'"'It'"'"'s All On U ft. Liam O'"'"'Donnell'"'"'! OUT NOW!
[Genre: Melodic Dubstep/Electronic]

►Illenium:
https://soundcloud.com/illeniumofficial
https://twitter.com/ILLENIUMMUSIC
http://www.facebook.com/illenium
http://instagram.com/illeniummusic

►xKito Music:
https://www.facebook.com/xKitoMusic
https://twitter.com/xkito_music
https://instagram.com/xkito_m/
https://soundcloud.com/xkitomusic
https://www.youtube.com/c/xKitoMusic

►Submit your music to xKito:
https://xkito.toneden.io/

►PICTURE → http://www.pixiv.net/member_illust.php?mode=medium&illust_id=55190493
©Artwork by: hiko

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

►DONATE VIA PAYPAL OR PAYSAFE CARD → http://tinyurl.com/oh6c2vc
[If you decide to donate, please leave a note with your youtube name if you want that displayed instead of your real name. With paysafecards just send the code to my email: xkitomusic@gmail.com]

►List of donors:
https://docs.google.com/document/d/1YKBo40AOU4qe4bsuuGhvo2f0GlmlQQFT1LvbrXBxWJs/edit?usp=sharing&pageId=118298691797275305549

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

•IMPORTANT:
If any artist or label has copyright issues with my videos (including artists of the images used), please send an e-mail to: xkitomusic@gmail.com and I will remove it immediately!' -metadata 'artist=Illenium ft. Liam O'"'"'Donnell' -metadata 'title=It'"'"'s All On U' -metadata date=20160215 -metadata 'purl=https://www.youtube.com/watch?v=81uHlxzM6KE' 'file:/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.temp.webm'
[debug] ffmpeg command line: /usr/local/bin/ffprobe -show_streams 'file:/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.webm'
[ffmpeg] Destination: /media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'Donnell - It's All On U.m4a
[debug] ffmpeg command line: /usr/local/bin/ffmpeg -y -i 'file:/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.webm' -vn -acodec aac -q:a 0 -bsf:a aac_adtstoasc 'file:/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.m4a'
Deleting original file /media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'Donnell - It's All On U.webm (pass -k to keep)
[atomicparsley] Adding thumbnail to "/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'Donnell - It's All On U.m4a"
[debug] AtomicParsley command line: AtomicParsley '/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.m4a' --artwork '/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.jpg' -o '/media1/Media/Music/youtube/xKito Music/Illenium ft. Liam O'"'"'Donnell - It'"'"'s All On U.temp.m4a'

youtube-dl.conf

-x
--metadata-from-title '%(artist)s - %(title)s'
--output '/media1/Media/Music/youtube/%(uploader)s/%(title)s.%(ext)s'
--no-overwrites
--download-archive /media1/Media/Music/youtube/dlarchive
--yes-playlist
--ignore-errors
--netrc
--ffmpeg-location /usr/local/bin/ffmpeg
--audio-format m4a
--audio-quality 0
--embed-thumbnail
--add-metadata
dstftw commented 8 years ago

--metadata-from-title is not supposed to embed metadata, it's --add-metadata's task. As seen from your log artist metafield is passed when embedding metadata:

-metadata 'artist=Illenium ft. Liam O'"'"'Donnell'

Here is why metadata is not embedded.