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

TypeError: %d format: a number is required, not float #8299

Closed
staticanime opened this issue Jan 22, 2016 · 5 comments
Closed

TypeError: %d format: a number is required, not float #8299

staticanime opened this issue Jan 22, 2016 · 5 comments

Comments

@staticanime
Copy link

@staticanime staticanime commented Jan 22, 2016

Youtube-DL Version: 2016.01.15

Platform: Ubuntu 14.04.3 LTS (Server)

Youtube-DL Command: youtube-dl --playlist-reverse --extract-audio --audio-format m4a --embed-thumbnail -o "%(uploader)s/%(autonumber)s.%(title)s.%(ext)s" --autonumber-size 3 --retries infinite --restrict-filenames https://www.youtube.com/user/DiavelNN/videos

Youtube-DL Traceback: [download] Downloading video 17 of 580
[youtube] nCr1lW67uEQ: Downloading webpage
[youtube] nCr1lW67uEQ: Downloading video info webpage
[youtube] nCr1lW67uEQ: Extracting video information
[youtube] nCr1lW67uEQ: Downloading DASH manifest
[youtube] nCr1lW67uEQ: Downloading thumbnail ...
[youtube] nCr1lW67uEQ: Writing thumbnail to: Diversity_Promotions/017.Auburn_-_Perfect_Two_Vau_Boy_Remix.jpg
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
"main", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/usr/local/bin/youtube-dl/main.py", line 19, in
File "/usr/local/bin/youtube-dl/youtube_dl/init.py", line 410, in main
File "/usr/local/bin/youtube-dl/youtube_dl/init.py", line 400, in _real_main
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1677, in download
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 676, in extract_info
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 729, in process_ie_result
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 676, in extract_info
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 837, in process_ie_result
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 729, in process_ie_result
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 676, in extract_info
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 722, in process_ie_result
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1347, in process_video_result
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1609, in process_info
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1551, in dl
File "/usr/local/bin/youtube-dl/youtube_dl/downloader/common.py", line 342, in download
File "/usr/local/bin/youtube-dl/youtube_dl/downloader/http.py", line 125, in real_download
File "/usr/local/bin/youtube-dl/youtube_dl/downloader/common.py", line 298, in report_retry
TypeError: %d format: a number is required, not float

Can anyone advise on this error please, or if there's a way to have youtube-dl skip & continue? Trying to download music from the above Youtube channel as m4a, with thumbnails embedded

@yan12125
Copy link
Collaborator

@yan12125 yan12125 commented Jan 22, 2016

--retries accepts positive integers only.

@staticanime
Copy link
Author

@staticanime staticanime commented Jan 22, 2016

Thank you, closing issue

jaimeMF added a commit that referenced this issue Jan 22, 2016
@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Jan 22, 2016

It's documented as supported:

-R, --retries RETRIES
              Number of retries (default is 10), or "infinite".

so I have fixed the error.

Note that it will print [download] Got server HTTP error. Retrying (attempt 1 of inf), maybe it could use , what do you think?

@yan12125
Copy link
Collaborator

@yan12125 yan12125 commented Jan 22, 2016

Sorry for the mistake. For the output format, just skipping the 'of xxx' part looks good to me:

Retrying (attempt 1)
Retrying (attempt 2)
Retrying (attempt 3)
@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Jan 23, 2016

I don't have any preference, feel free to change it.

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
3 participants
You can’t perform that action at this time.