fsspec / fsspec/filesystem_spec
spec: add sync/async connect/disconnect
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.4k
- Forks
- 490
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 38
Description
From discussion in #864
Currently, fsspec doesn't define any connect/disconnect methods in sync or async specs, which results in some implementations implementing things like set_session/connect/etc or even simply creating a connection automatically and using weakref to close it.
This issue is meant to try to start the discussion about the proper common API that all implementations could comply with.
-
connect/disconnect (possible better names?) with async versions
-
sync and async context managers?
-
clearly automatic connection is a very handy thing and most of filesystems already do it. Please correct me if I'm wrong, but it looks like this is not documented (but I'm not sure if it even needs to be, since it is kinda given from the examples).
-
a bit unrelated, but we currently use
_prefix for async methods, which looks unofficial to users and linters 🙂 Maybe time to also supportasync_to make it official?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the discussion in issue #864 and inspect the existing synchronous and asynchronous filesystem specifications. Define the common connect/disconnect API, context-manager expectations, automatic connection behavior, and possible async_ naming, with agreement on the resulting specification as done.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend-api-design
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100