This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2015年01月02日 09:40 by serhiy.storchaka, last changed 2022年04月11日 14:58 by admin. This issue is now closed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| pathlib_parse_parts_altsep.patch | serhiy.storchaka, 2015年02月12日 21:36 | review | ||
| Messages (6) | |||
|---|---|---|---|
| msg233308 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) | Date: 2015年01月02日 09:40 | |
>>> pathlib.PureWindowsPath('c:/a/b', '/x/y')
PureWindowsPath('c:/x/y')
>>> pathlib.PureWindowsPath('//?/c:/a/b', '/x/y')
PureWindowsPath('/x/y')
>>> pathlib.PureWindowsPath(r'\\?\c:\a\b', '/x/y')
PureWindowsPath('//?/c:/x/y')
I suppose this is because in parse_parts() altsep is replaced with sep before calling self.splitroot() in main loop but not in other loop (if drv or root). Line 76.
|
|||
| msg235826 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) | Date: 2015年02月12日 14:23 | |
Ping. |
|||
| msg235851 - (view) | Author: Antoine Pitrou (pitrou) * (Python committer) | Date: 2015年02月12日 19:21 | |
Yes, this is a bug indeed. A patch would be welcome ;-) |
|||
| msg235855 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) | Date: 2015年02月12日 21:36 | |
Here is a patch. It also fixes tests which didn't test altsep. |
|||
| msg236048 - (view) | Author: Roundup Robot (python-dev) (Python triager) | Date: 2015年02月15日 17:07 | |
New changeset 0f8f24dab34b by Antoine Pitrou in branch '3.4': Issue #23146: Fix mishandling of absolute Windows paths with forward slashes in pathlib. https://hg.python.org/cpython/rev/0f8f24dab34b New changeset 0de45993c21c by Antoine Pitrou in branch 'default': Issue #23146: Fix mishandling of absolute Windows paths with forward slashes in pathlib. https://hg.python.org/cpython/rev/0de45993c21c |
|||
| msg236049 - (view) | Author: Antoine Pitrou (pitrou) * (Python committer) | Date: 2015年02月15日 17:07 | |
Thanks for the patch! |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:58:11 | admin | set | github: 67335 |
| 2015年02月15日 17:07:32 | pitrou | set | status: open -> closed resolution: fixed messages: + msg236049 stage: patch review -> resolved |
| 2015年02月15日 17:07:14 | python-dev | set | nosy:
+ python-dev messages: + msg236048 |
| 2015年02月15日 13:00:00 | serhiy.storchaka | set | assignee: pitrou |
| 2015年02月12日 21:36:44 | serhiy.storchaka | set | files:
+ pathlib_parse_parts_altsep.patch keywords: + patch messages: + msg235855 stage: needs patch -> patch review |
| 2015年02月12日 19:21:54 | pitrou | set | messages: + msg235851 |
| 2015年02月12日 14:23:42 | serhiy.storchaka | set | messages: + msg235826 |
| 2015年01月02日 09:40:25 | serhiy.storchaka | create | |