summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
Diffstat (limited to 'Doc')
-rw-r--r--Doc/library/os.path.rst8
-rw-r--r--Doc/whatsnew/3.13.rst7
2 files changed, 13 insertions, 2 deletions
diff --git a/Doc/library/os.path.rst b/Doc/library/os.path.rst
index 95933f5..3cab7a2 100644
--- a/Doc/library/os.path.rst
+++ b/Doc/library/os.path.rst
@@ -239,12 +239,16 @@ the :mod:`glob` module.)
.. function:: isabs(path)
Return ``True`` if *path* is an absolute pathname. On Unix, that means it
- begins with a slash, on Windows that it begins with a (back)slash after chopping
- off a potential drive letter.
+ begins with a slash, on Windows that it begins with two (back)slashes, or a
+ drive letter, colon, and (back)slash together.
.. versionchanged:: 3.6
Accepts a :term:`path-like object`.
+ .. versionchanged:: 3.13
+ On Windows, returns ``False`` if the given path starts with exactly one
+ (back)slash.
+
.. function:: isfile(path)
diff --git a/Doc/whatsnew/3.13.rst b/Doc/whatsnew/3.13.rst
index 59b9281..05b9b87 100644
--- a/Doc/whatsnew/3.13.rst
+++ b/Doc/whatsnew/3.13.rst
@@ -307,6 +307,13 @@ os
:c:func:`!posix_spawn_file_actions_addclosefrom_np`.
(Contributed by Jakub Kulik in :gh:`113117`.)
+os.path
+-------
+
+* On Windows, :func:`os.path.isabs` no longer considers paths starting with
+ exactly one (back)slash to be absolute.
+ (Contributed by Barney Gale and Jon Foster in :gh:`44626`.)
+
pathlib
-------