classification
Title: Incorrect conversion path case with german character
Type: behavior Stage: resolved
Components: Windows Versions: Python 3.8
process
Status: closed Resolution: duplicate
Dependencies: Superseder: os.path.normcase() is inconsistent with Windows file system
View: 42658
Assigned To: Nosy List: eryksun, paul.moore, steve.dower, tim.golden, voramva, zach.ware
Priority: normal Keywords:

Created on 2021-03-04 09:42 by voramva, last changed 2021-03-09 15:06 by eryksun. This issue is now closed.

Messages (3)
msg388079 - (view) Author: Сергей М (voramva) Date: 2021-03-04 09:42
I try to normalize case for path with german characters:

```
>os.path.normcase(r'c:\asd\ASDẞ')
'c:\\asd\\asdß'
```

But in OS Windows r'c:\asd\ASDẞ' and r'c:\asd\asdß' are different paths.
msg388350 - (view) Author: Сергей М (voramva) Date: 2021-03-09 11:04
I've found the useful function

https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-charlowerw
msg388364 - (view) Author: Eryk Sun (eryksun) * (Python triager) Date: 2021-03-09 15:06
ntpath.normcase() needs a platform-dependent implementation that calls LCMapStringEx() in Windows, in order to properly agree with case-insensitive Windows filesystems. See bpo-42658.
History
Date User Action Args
2021-03-09 15:06:51eryksunsetstatus: open -> closed

superseder: os.path.normcase() is inconsistent with Windows file system

nosy: + eryksun
messages: + msg388364
resolution: duplicate
stage: resolved
2021-03-09 11:04:21voramvasetmessages: + msg388350
2021-03-04 09:42:06voramvacreate