Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
db118f5d
Commit
db118f5d
authored
Nov 19, 2014
by
Antoine Pitrou
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Close #22370: Windows detection in pathlib is now more robust.
parent
81f68a7d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
5 deletions
+6
-5
Lib/pathlib.py
Lib/pathlib.py
+4
-5
Misc/NEWS
Misc/NEWS
+2
-0
No files found.
Lib/pathlib.py
View file @
db118f5d
...
...
@@ -15,16 +15,15 @@ from urllib.parse import quote_from_bytes as urlquote_from_bytes
supports_symlinks
=
True
try
:
if
os
.
name
==
'nt'
:
import
nt
except
ImportError
:
nt
=
None
else
:
if
sys
.
getwindowsversion
()[:
2
]
>=
(
6
,
0
):
from
nt
import
_getfinalpathname
else
:
supports_symlinks
=
False
_getfinalpathname
=
None
else
:
nt
=
None
__all__
=
[
...
...
@@ -110,7 +109,7 @@ class _WindowsFlavour(_Flavour):
has_drv
=
True
pathmod
=
ntpath
is_supported
=
(
nt
is
not
None
)
is_supported
=
(
os
.
name
==
'nt'
)
drive_letters
=
(
set
(
chr
(
x
)
for
x
in
range
(
ord
(
'a'
),
ord
(
'z'
)
+
1
))
|
...
...
Misc/NEWS
View file @
db118f5d
...
...
@@ -36,6 +36,8 @@ Core and Builtins
Library
-------
- Issue #22370: Windows detection in pathlib is now more robust.
- Issue #22841: Reject coroutines in asyncio add_signal_handler().
Patch by Ludovic.Gasc.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment