You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
match decomposed/precomposed unicode strings with sub-auto=fuzzy #4016
rename a video with the filename[ぐ.mkv and rename the corresponding subtitle file with [ぐ.ass. Both files are in the same directory.
open the [ぐ.mkv with terminal command mpv \[ぐ.mkv
Expected behavior
Since the sub-auto=fuzzy is set, subtitle file with filename same to the video file should be loaded automatically when the video is opened.
Actual behavior
mpv doesn't load the subtitle file automatically. ~~What is stranger, filename with single ぐ or single [ doesn't trigger the problem. The bug occurs with [ and ぐ both be present in the filename. ~~ Update
The ぐ character is to blame as far as I tested.
Update:
If mpv is defined as the default player and thus launched by double click the file in Finder, the subtitle file can be loaded normally. The bug only occurs under terminal launch.
Must be some macOS-only bug, works fine in Windows.
Do you try to open the video via terminal (maybe cmd in windows? I didn't try mpv in windows..)
I just found the problem was only triggered via terminal launch. Opening the file in Finder is fine.
Yes I can reproduce the problem with the options you mentioned. The log file is on http://sprunge.us/cNGI <http://sprunge.us/cNGI>
And by renaming the files to `[.mkv` and `[.ass` the problem is solved.
I just found `ぐ.mkv`+ `ぐ.ass` pair was broken as well, and so is any filename contains 'ぐ’. Filename containing some other Hiraganas seems to work well.
(I remember it worked last night..maybe I opened the file via Finder by mistake?)
And my locale settings is as following, thought they may be related.
```
LANG="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_CTYPE="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_ALL="en_US.UTF-8”
```
So it is a normalization issue, where OSX not only uses non-standard normalization, but also is inconsistent about which form it uses.
Likely a WONTFIX.
Sorry to hear that.
Is there any work around for this issue? As launching mpv via bundle just works while iTerm2.app and terminal.app fail, can the terminal applications behave as Finder do?
i tested with the same mpv version and set the same locale as you. i am also on the same macOS version, and it still works here. i wonder what else could be different on your system.
Here I asked one of my colleagues to test and he could exactly reproduce my problem, on the same macOS version.
I don't know if other system preference settings like area or lauguage matters. The prior language in `System Preferences > Language & Region` we choose here is Simplified Chinese.
From: Akemi
Date: 2017-01-11 20:20
To: mpv-player/mpv
CC: 小叶子; Author
Subject: Re: [mpv-player/mpv] mpv failed to load subtitle file with specific character pair in filename (#4016)
i tested with the same mpv version and set the same locale as you. i am also on the same macOS version, and it still works here. i wonder what else could be different on your system.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
changed the title [-]mpv failed to load subtitle file with specific character pair in filename[/-][+]mpv failed to load subtitle file with specific character in filename[/+]on Jan 11, 2017
tested with that too and still works. here a log. the only things i really noticed, when comparing the logs, is:
your libass is build with harfbuzz, which shouldn't make a difference
my mpv is build with uchardet, which might make the difference here
maybe give it a try and build mpv with uchardet. if you can't, try this build. if you want to start it from the terminal, right click the bundle and click "Show package Contents", navigate to Contents > MacOS and drag an drop the "mpv" binary into your terminal. in the terminal there should be the path to the binary now and just test it with --no-config and your options again.
changed the title [-]mpv failed to load subtitle file with specific character in filename[/-][+]match decomposed/precomposed unicode strings with sub-auto=fuzzy[/+]on Jan 20, 2017
Activity
wiiaboo commentedon Jan 10, 2017
Must be some macOS-only bug, works fine in Windows.
ParadiseDS commentedon Jan 11, 2017
Do you try to open the video via terminal (maybe cmd in windows? I didn't try mpv in windows..)
I just found the problem was only triggered via terminal launch. Opening the file in Finder is fine.
Akemi commentedon Jan 11, 2017
i can't reproduce this. it works via terminal and the bundle here. can you reproduce it with
--no-config --sub-auto=fuzzy?ParadiseDS commentedon Jan 11, 2017
ParadiseDS commentedon Jan 11, 2017
Sorry to hear that.
Is there any work around for this issue? As launching mpv via bundle just works while iTerm2.app and terminal.app fail, can the terminal applications behave as Finder do?
Akemi commentedon Jan 11, 2017
i tested with the same mpv version and set the same locale as you. i am also on the same macOS version, and it still works here. i wonder what else could be different on your system.
ParadiseDS commentedon Jan 11, 2017
[-]mpv failed to load subtitle file with specific character pair in filename[/-][+]mpv failed to load subtitle file with specific character in filename[/+]Akemi commentedon Jan 11, 2017
tested with that too and still works. here a log. the only things i really noticed, when comparing the logs, is:
maybe give it a try and build mpv with uchardet. if you can't, try this build. if you want to start it from the terminal, right click the bundle and click "Show package Contents", navigate to Contents > MacOS and drag an drop the "mpv" binary into your terminal. in the terminal there should be the path to the binary now and just test it with --no-config and your options again.
wiiaboo commentedon Jan 11, 2017
I don't think uchardet works on filenames, just on subtitle data. @wm4?
22 remaining items
[-]mpv failed to load subtitle file with specific character in filename[/-][+]match decomposed/precomposed unicode strings with sub-auto=fuzzy[/+]Akemi commentedon Jan 20, 2017
i changed the title a bit since this is more like a feature request now.
cocoa: consistent normalisation when searching for external files
cocoa: consistent normalisation when searching for external files
cocoa: consistent normalisation when searching for external files
Akemi commentedon Jan 25, 2017
#4067 another attempt to fix this. hopefully this time without any drawbacks.
cocoa: consistent normalisation when searching for external files
ParadiseDS commentedon Jan 26, 2017
Akemi commentedon Jan 29, 2017
just wondering, this worked for you as expected?
ParadiseDS commentedon Jan 30, 2017
osx: consistent normalisation when searching for external files
osx: consistent normalisation when searching for external files