Terry J. Reedy added the comment:
3.5 (and 3.6) only gets security fixes. From the report, the bug is fixed in
3.7.
FWIW, I agree about the 9-bit octal thing. There is another issue about this.
--
nosy: +terry.reedy
resolution: -> out of date
stage: -> resolved
status: open -> cl
Eryk Sun added the comment:
>\N{name} : named character
>\U : 32-bit hexadecimal ordinal (e.g. \U0010)
>\u : 16-bit hexadecimal ordinal (e.g. \u)
>\xXX : 8-bit hexadecimal ordinal (e.g. \xff)
>\OOO : 9-bit octal ordinal (e.g. \777)
>
Eryk Sun added the comment:
As Karthikeyan noted, in a regular string literal, backslash is an escape
character that's used in the following escape sequences:
\N{name} : named character
\U : 32-bit hexadecimal ordinal (e.g. \U0010)
\u : 16-bit hexadecimal ord
Karthikeyan Singaravelan added the comment:
I guess '\f' translates to \x0c and using raw string helps with this.
>>> ord('\f')
12
>>> '\f'
'\x0c'
>>> var = "d:\stuff\morestuff\furtherdown\THEFILE.txt"
>>> var
'd:\\stuff\\morestuff\x0curtherdown\\THEFILE.txt'
>>> print(os.path.normpath(var))
d
New submission from Yugi :
I was trying to handle path to work on both '/' and '\' but when I tried to run
the code like they said on:
https://stackoverflow.com/questions/3167154/how-to-split-a-dos-path-into-its-components-in-python
I have no idea why the terminal on my PC doesnt have the same