[issue22302] Windows os.path.isabs UNC path bug
Antoine Pitrou
report at bugs.python.org
Fri Sep 5 18:52:14 CEST 2014
Antoine Pitrou added the comment:
Under Windows, pathlib's "absolute" means a fully qualified path as defined in http://msdn.microsoft.com/en-us/library/aa365247%28v=vs.85%29.aspx
>>> PureWindowsPath("c:").is_absolute()
False
>>> PureWindowsPath("/").is_absolute()
False
>>> PureWindowsPath("c:/").is_absolute()
True
The fact that "//server" isn't considered absolute is a bug in pathlib, since "//server/" is:
>>> PureWindowsPath("//foo").is_absolute()
False
>>> PureWindowsPath("//foo/").is_absolute()
True
I agree that it's not really important, since both aren't actual paths (in the sense that they may not point to anything, AFAIK).
----------
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue22302>
_______________________________________
More information about the Python-bugs-list
mailing list