fsspec / fsspec/filesystem_spec
`FTPFileSystem` incompatibility with `pandas`/`pyarrow`
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.4k
- Forks
- 490
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 38
Description
I've run across an issue, and to be honest I'm not quite sure which library it belongs in.
It starts with the line
df.to_parquet(
path=path,
partition_cols=partition_cols,
storage_options=fs.storage_options
)
which takes me through the pandas library until reaching this function in pyarrow
which internally calls the helper function _mkdir_if_not_exists()
The problem is that for FTPFileSystem, this helper function does not actually create the directory because of this line
The simplest solution would be to override this _is_filestore() method in FTPFileSystem to return True.
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 _is_filestore() in fsspec/spec.py and trace how FTPFileSystem reaches it during pandas to_parquet(), including pyarrow's _mkdir_if_not_exists() helper. Verify the directory is created for partitioned parquet output on FTPFileSystem and add or update coverage if the repository has a relevant test entry point.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100