We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
import warnings
pathlib._local
1 parent d15b8e4 commit 83e3b51Copy full SHA for 83e3b51
1 file changed
Lib/pathlib/_local.py
@@ -4,7 +4,6 @@
4
import os
5
import posixpath
6
import sys
7
-import warnings
8
from glob import _StringGlobber
9
from itertools import chain
10
from _collections_abc import Sequence
@@ -405,6 +404,7 @@ def is_absolute(self):
405
404
def is_reserved(self):
406
"""Return True if the path contains one of the special names reserved
407
by the system, if any."""
+ import warnings
408
msg = ("pathlib.PurePath.is_reserved() is deprecated and scheduled "
409
"for removal in Python 3.15. Use os.path.isreserved() to "
410
"detect reserved paths on Windows.")
0 commit comments