-
Notifications
You must be signed in to change notification settings - Fork 271
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
Only escape backslashes, single quotes, and newlines when writing ffmetadata #1161
Conversation
this documentation is correct: https://ffmpeg.org/ffmpeg-utils.html this is outdated: https://ffmpeg.org/ffmpeg-formats.html#metadata
Did you test this change? |
yes, you can test with some videos having those letters. These are without the PR, as is working right now:
The first title is in Twitch
But in metadata in video
The second title in Twitch
but in video is
third video is
third title in video (the ' is not escaped but if you escape it works too, no idea what is best)
fourth video in twitch
in video
fifth video original title is
In video is
sixth video original title is
In video is
|
The missing video is the one with |
https://www.twitch.tv/videos/2166590043 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a comment somewhere, preferably above the method name, explaining that the documentation is outdated and =
;
#
do not need to be escaped.
Also, have you reported this to the FFmpeg team yet? |
I've added the 6 videos each one to see is each character is escaped or not. The The downloaded metadata.txt is:
but if you want to put the title in two lines the
The issue is known: Chaotic escaping rules |
I did not say |
Already returned. |
Can you add the comment? |
yes that's a multi line description, but i meant that the description included the \n literal like this has in the title https://www.twitch.tv/videos/2172757417 |
Yes, that will stay as the literal |
comment done. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for catching this
this documentation is correct:
https://ffmpeg.org/ffmpeg-utils.html#Quoting-and-escaping
this is outdated:
https://ffmpeg.org/ffmpeg-formats.html#metadata
Escaping only backslash
\\
is enough but single quotes can be escaped no problem.