-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
Open
Labels
stdlibPython modules in the Lib dirPython modules in the Lib dirtopic-pathlibtype-featureA feature request or enhancementA feature request or enhancement
Description
Feature or enhancement
This issue covers the final tasks needed to make the pathlib ABCs worthy of using in zipfile.Path
(i.e. zipp.Path
).
Tasks
- Rename
PurePathBase
toJoinablePath
, and splitPathBase
intoReadablePath
andWritablePath
- Make
WritablePath
a sibling (not subclass) ofReadablePath
- Add
ReadablePath.info
- Subclass
abc.ABC
fromJoinablePath
, and makeparser
abstract - Make type-checking more consistent
- Move metadata reading into
ReadablePath.info
; removeReadablePath._copy_reader
- Move metadata writing into
WritablePath._write_info()
; removeWritablePath._copy_writer
- Merge
pathlib._abc
intopathlib.types
- Tests: replace the
Dummy*
classes with simplezipfile.Path
-like implementation - Tests: add tests for
WritablePath
- Tests: parametrize
copy()
tests - Finalise
copy()
implementation - Add type annotations?
- Sync code to pathlib-abc PyPI package
- Update pathlib-abc documentation
- Publish new version of pathlib-abc
- Merge PR to jaraco/zipp
Discussion: https://discuss.python.org/t/make-pathlib-extensible/3428
Linked PRs
- GH-128520: Divide pathlib ABCs into three classes #128523
- GH-128520: Subclass
abc.ABC
inpathlib._abc
#128745 - GH-128520: Make
pathlib._abc.WritablePath
a sibling ofReadablePath
#129014 - GH-128520: Read path metadata from
pathlib.types.PathInfo
when copying #129841 - GH-128520: More consistent type-checking behaviour in pathlib #130199
- GH-128520: Merge
pathlib._abc
intopathlib.types
#130747 - GH-128520: Merge
pathlib._local
intopathlib
#130748 - GH-128520: pathlib ABCs: fix
with_name()
handling of empty names #130964 - GH-128520: pathlib ABCs: allow tests to be run externally #131315
- GH-128520: pathlib ABCs: reject empty pattern in
ReadablePath.glob()
#127343 - GH-128520: pathlib ABCs: validate
magic_open()
arguments #131617 - GH-128520: pathlib ABCs: tighten up argument types #131621
- GH-128520: pathlib ABCs: raise text encoding warnings at correct stack level #133051
- GH-128520: pathlib ABCs tests: use explicit text encoding #133105
- GH-128520: pathlib ABCs: add
JoinablePath.__vfspath__()
#133437 - GH-128520: pathlib ABCs: improve protocol for 'openable' objects #134101
- GH-128520: pathlib ABCs: tweak protocol for virtual path strings #134104
tomasr8, m-aciek and edgarrmondragon
Metadata
Metadata
Assignees
Labels
stdlibPython modules in the Lib dirPython modules in the Lib dirtopic-pathlibtype-featureA feature request or enhancementA feature request or enhancement