Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thumbnail is not added to the mp3 #13046

Closed
persian-telegram opened this issue May 10, 2017 · 3 comments
Closed

Thumbnail is not added to the mp3 #13046

persian-telegram opened this issue May 10, 2017 · 3 comments
Labels

Comments

@persian-telegram
Copy link

@persian-telegram persian-telegram commented May 10, 2017

Please follow the guide below

  • You will be asked some questions and requested to provide some information, please read them carefully and answer honestly
  • Put an x into all the boxes [ ] relevant to your issue (like that [x])
  • Use Preview tab to see how your issue will actually look like

Make sure you are using the latest version: run youtube-dl --version and ensure your version is 2017.05.09. If it's not read this FAQ entry and update. Issues with outdated version will be rejected.

  • [x ] I've verified and I assure that I'm running youtube-dl 2017.05.09

Before submitting an issue make sure you have:

  • [x ] At least skimmed through README and most notably FAQ and BUGS sections
  • [ x] Searched the bugtracker for similar issues including closed ones

What is the purpose of your issue?

  • [ x] Bug report (encountered problems with youtube-dl)
  • Site support request (request for adding support for a new site)
  • Feature request (request for a new functionality)
  • Question
  • Other

The following sections concretize particular purposed issues, you can erase any section (the contents between triple ---) not applicable to your issue


I am using the Youtube_DL module for python embedding so i wouldn't be able to get the CLI output.

Here is my code:
ydl_opts = {'writethumbnail': true,
'outtmpl': '/home/siyavash/'+fileNAME+'.%(ext)s',
'format': 'bestaudio/best',
'postprocessors': [
{'key': 'FFmpegExtractAudio',
'preferredcodec': 'mp3',
'preferredquality': '192'},
{'key': 'EmbedThumbnail',},

                                    ]

}

Here is Console Output:

WARNING: Parameter outtmpl is bytes, but should be a unicode string. Put from future import unicode_literals at the top of your code file or consider s
witching to Python 3.x.
[youtube] nMB2uCTTvJ0: Downloading webpage
[youtube] nMB2uCTTvJ0: Downloading video info webpage
[youtube] nMB2uCTTvJ0: Extracting video information
WARNING: "id" field is not a string - forcing string conversion
[youtube] nMB2uCTTvJ0: Downloading thumbnail ...
[youtube] nMB2uCTTvJ0: Writing thumbnail to: /home/siyavash/xx_341088146.jpg
[download] Destination: /home/siyavash/xx_341088146.webm
[download] 100% of 2.73MiB in 00:00
[ffmpeg] Destination: /home/siyavash/xx_341088146.mp3
WARNING: Your copy of avconv is outdated, update avconv to version 10-0 or newer if you encounter any errors.
Deleting original file /home/siyavash/xx_341088146.webm (pass -k to keep)
[ffmpeg] Adding thumbnail to "/home/siyavash/xx_341088146.mp3"
WARNING: Your copy of avconv is outdated, update avconv to version 10-0 or newer if you encounter any errors.
ERROR: file:/home/siyavash/xx_341088146.jpg: No such file or directory
ERROR:telegram.ext.dispatcher:An uncaught error was raised while processing the update
Traceback (most recent call last):
File "/home/siyavash/.local/lib/python2.7/site-packages/telegram/ext/dispatcher.py", line 270, in process_update
handler.handle_update(update, self)
File "/home/siyavash/.local/lib/python2.7/site-packages/telegram/ext/messagehandler.py", line 123, in handle_update
return self.callback(dispatcher.bot, update, **optional_args)
File "/home/siyavash/Final3.py", line 367, in echo
path = audioDownloader(chat_id, correctURL)
File "/home/siyavash/Final3.py", line 268, in audioDownloader
ydl.download([correctURL])
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 1896, in download
url, force_generic_extractor=self.params.get('force_generic_extractor', False))
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 771, in extract_info
return self.process_ie_result(ie_result, download, extra_info)
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 825, in process_ie_result
return self.process_video_result(ie_result, download=download)
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 1539, in process_video_result
self.process_info(new_info)
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 1877, in process_info
self.post_process(filename, info_dict)
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 1944, in post_process
self.report_error(e.msg)
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 589, in report_error
self.trouble(error_message, tb)
File "/home/siyavash/.local/lib/python2.7/site-packages/youtube_dl/YoutubeDL.py", line 559, in trouble
raise DownloadError(message, exc_info)
DownloadError: ERROR: file:/home/siyavash/xx_341088146.jpg: No such file or directory

Description of your issue, suggested solution and other information

This issue happens whenever I try to download the mp3 and embed the thumbnail. I can see the thumbnail in this directory /home/siyavash/xx_341088146.jpg however it still gives me an error.

Explanation of your issue in arbitrary form goes here. Please make sure the description is worded well enough to be understood. Provide as much context and examples as possible.
If work on your issue requires account credentials please provide them or explain how one can obtain them.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented May 10, 2017

Duplicate of #7238.

@dstftw dstftw closed this May 10, 2017
@dstftw dstftw added the duplicate label May 10, 2017
@persian-telegram
Copy link
Author

@persian-telegram persian-telegram commented May 10, 2017

Can you please give some help instead of just writing "Duplicate"?
How can i write "--prefer-ffmpeg" in python embedded ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.