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

Generic Extractor tries to download videos with unspecified MIME/Content-Type #4149

Closed
ChrisK2 opened this issue Nov 10, 2014 · 3 comments
Closed

Comments

@ChrisK2
Copy link

ChrisK2 commented Nov 10, 2014

We can't expect webservers to know all video file types out there, so they may return no Content-Type on URLs that may actually lead directly to a file. The GenericExtractor however starts to download the entire file in this case, which isn't helpful.

Test URL: http://sva.wakku.to/~chris/symlinks/temp/00016.m2ts
The server doesn't know about m2ts files and doesn't return a "Content-Type" field in the header.

@jaimeMF
Copy link
Collaborator

jaimeMF commented Nov 12, 2014

How would you suggest detecting the file type?

@ChrisK2
Copy link
Author

ChrisK2 commented Nov 12, 2014

As soon as you have 1KB or so of data downloaded, check if it contains a <html> tag, if not, it's probably nothing that you can extract something from (since its most likely a direct media file).

@phihag
Copy link
Contributor

phihag commented Nov 26, 2014

Thank you for the report. I believe this issue to be fixed in youtube-dl 2014.11.26 and newer. Refer to our FAQ if you need help updating.

@phihag phihag closed this as completed in 4e262a8 Nov 26, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants