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

title in file name doesn't match JSON title #654

Closed
porjo opened this issue Jan 27, 2013 · 2 comments
Closed

title in file name doesn't match JSON title #654

porjo opened this issue Jan 27, 2013 · 2 comments

Comments

@porjo
Copy link

@porjo porjo commented Jan 27, 2013

I run this command:

$ youtube-dl --write-info-json -t https://www.youtube.com/watch?v=dgI52y27O_I

results in 2 files:

John Resig - The DOM is a Mess-dgI52y27O_I.mp4.info.json
John Resig - The DOM is a Mess-dgI52y27O_I.mp4

Inside the JSON file, both 'title' and 'stitle' are set to:

"John Resig: The DOM is a Mess"

The filenames have ' -' in place of ':' - is that a bug?

(using version 2013.01.02)

@phihag
Copy link
Contributor

@phihag phihag commented Jan 27, 2013

This is intended behavior. Since : is not generally a safe character in a filename - it would break at least on all Windows systems - we have to replace it when picking a filename. In the JSON, however, we are free to include the title (in fact, that's what the metadata is for).

I'm not sure what we could change: Which behavior would you expect? Personally, I think that the filename we pick at the moment is perfectly understandable. Leaving colons in on non-Windows systems would be possible, but is bound to lead to problems, say, when someone dual-boots or downloads to a USB thumb drive, and then can't open them on a Windows system.

@phihag
Copy link
Contributor

@phihag phihag commented Jan 27, 2013

Closing for now, but feel free to leave a comment if you have a proposal on what youtube-dl should do.

@phihag phihag closed this Jan 27, 2013
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.