| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Use `fnmatch` to match path and pattern anchors, just as we do for other path parts. This allows patterns such as `'*:/Users/*'` to be matched.
We need a test in "test_ntpath.py" to ensure that splitroot(' :/foo') == (' :', '/', 'foo') and splitroot('/:/foo') == ('', '/', ':/foo'). WinAPI GetFullPathNameW() will accept any character in the 16-bit BMP as a drive 'letter', except for null, slash, and backslash. For example: >>> os.getcwd()
'C:\\Temp'
>>> nt._getfullpathname(' :/foo')
' :\\foo'
>>> nt._getfullpathname('/:/foo')
'C:\\:\\foo' |
Sorry, something went wrong.
|
Change looks fine, just rerunning the failed tests. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Use fnmatch to match path and pattern anchors, just as we do for other path parts. This allows patterns such as '*:/Users/*' to be matched.
This can't be readily backported as it relies on a feature of pathlib in 3.12: support for non-alphabetic drive letters when parsing paths.