-
Notifications
You must be signed in to change notification settings - Fork 3k
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
mpv attempts to parse language tags from video filename for the external track file with the same name #16038
Labels
Milestone
Comments
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 11, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. ISO 639-2 is choosen since we already canonicalize to that and ISO 639-3 is just overkill. Fixes mpv-player#16038.
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 11, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. ISO 639-2 is chosen since we already canonicalize to that and ISO 639-3 is just overkill. Fixes mpv-player#16038.
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 11, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. Living languages with ISO 639-2 tags are chosen as the basis of the whitelist since we accept those and having a list of everything in ISO 639-3 is just overkill. Fixes mpv-player#16038.
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 11, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. Living languages with ISO 639-2 tags are chosen as the basis of the whitelist since we accept those and having a list of everything in ISO 639-3 is just overkill. Fixes mpv-player#16038.
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 11, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. Living languages with ISO 639-2 tags are chosen as the basis of the whitelist since we accept those and having a list of everything in ISO 639-3 is just overkill. Fixes mpv-player#16038.
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 12, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. Living languages with ISO 639-2 tags are chosen as the basis of the whitelist since we accept those and having a list of everything in ISO 639-3 is just overkill. Fixes mpv-player#16038.
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 12, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. Living languages with ISO 639-2 tags are chosen as the basis of the whitelist since we accept those and having a list of everything in ISO 639-3 is just overkill. As a side note, Chinese should canonicalize to zho not chi so change that as well. Fixes mpv-player#16038.
Dudemanguy
added a commit
to Dudemanguy/mpv
that referenced
this issue
Mar 12, 2025
The old logic blindly accepted any string combination that had the same format as an IETF. Do at least a little bit of validation to make sure the first part matches an actual language. The downside is that this requires having a giant whitelist of language tags. But it's not like the amount of languages on planet earth is growing at a rapid pace or something. Living languages with ISO 639-2 tags are chosen as the basis of the whitelist since we accept those and having a list of everything in ISO 639-3 is just overkill. Fixes mpv-player#16038.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
mpv Information
Other Information
Reproduction Steps
Try using
mpv --no-config --log-file=mpv.log
to play a video with the same name external track file and view external track information.Expected Behavior
External track files with the same name as the video file name should not show any available language tags
Actual Behavior
mpv attempts to parse language tags from video filename for the external track file with the same name
Log File
mpv.log
Sample Files
No response
I carefully read all instruction and confirm that I did the following:
--log-file=output.txt
.The text was updated successfully, but these errors were encountered: