Skip to content

GH-127381: pathlib ABCs: remove PathBase.stat() - #128334

Merged
barneygale merged 2 commits into
python:mainfrom
barneygale:gh-127381-stat
Dec 29, 2024
Merged

GH-127381: pathlib ABCs: remove PathBase.stat()#128334
barneygale merged 2 commits into
python:mainfrom
barneygale:gh-127381-stat

Conversation

@barneygale

@barneygalebarneygale commented Dec 29, 2024

Copy link
Copy Markdown
Contributor

Remove the PathBase.stat() method. Its use of the os.stat_result API, with its 10 mandatory fields and low-level types, makes it an awkward fit for virtual filesystems.

We'll look to add a PathBase.info attribute later - see GH-125413.

No user-facing changes because the ABCs are still private.

Remove the `PathBase.stat()` method. Its use of the `os.stat_result` API,
with its 10 mandatory fields and low-level types, makes it a poor fit for
virtual filesystems.
We'll look to add a `PathBase.info` attribute later - see pythonGH-125413.
@barneygale
barneygale enabled auto-merge (squash) December 29, 2024 20:51
@barneygale
barneygale merged commit c78729f into python:mainDec 29, 2024
srinivasreddy pushed a commit to srinivasreddy/cpython that referenced this pull request Jan 8, 2025
Remove the `PathBase.stat()` method. Its use of the `os.stat_result` API,
with its 10 mandatory fields and low-level types, makes it an awkward fit
for virtual filesystems.
We'll look to add a `PathBase.info` attribute later - see pythonGH-125413.
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

@barneygale