fsspec / fsspec/s3fs

pathlib.Path syntax not supported?

Open
#635 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
1k
Forks
305
Avg merge
22h 37m
Merged PRs (30d)
4

Description

Some functions crash when trying to use pathlib.Path-like syntax. Is this intentional (e.g. s3fs does not intend to support pathlib.Path, only str, or is this a bug?

pathlib is for many libraries now the default way to handle paths, since it has a lot of benefits over plain strings.

An example of a function that crashes when providing a pathlib.PurePosixPath is the ._rm functionality.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the crash in the ._rm functionality with a pathlib.PurePosixPath, then trace how that path value is handled. Determine whether pathlib paths are intended to be accepted, and make the supported behavior for this example clear and verifiable.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cloud
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.