Skip to content

upath._stat: add a os.stat_result compatible fsspec info wrapper#179

Merged
ap-- merged 5 commits intofsspec:mainfrom
ap--:fix-upath-stat
Feb 10, 2024
Merged

upath._stat: add a os.stat_result compatible fsspec info wrapper#179
ap-- merged 5 commits intofsspec:mainfrom
ap--:fix-upath-stat

Conversation

@ap--
Copy link
Copy Markdown
Collaborator

@ap-- ap-- commented Feb 10, 2024

Closes #145

This PR provide a duck-typed os.stat_result class UPathStatResult that wraps fsspec info dicts and tries to convert info entries to their corresponding st_* attributes if available.

For retrieving the original info dict, it provides a .as_info() method.

@ap-- ap-- merged commit a98c507 into fsspec:main Feb 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Different return types for S3Path.stat() and WindowsUPath.stat()

1 participant