You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "qzyu999 (via GitHub)" <gi...@apache.org> on 2026/07/29 21:51:54 UTC
[I] IO: Windows paths crash with 'Unrecognized filesystem type in URI: c' [iceberg-python]
qzyu999 opened a new issue, #3720:
URL: https://github.com/apache/iceberg-python/issues/3720
### Apache Iceberg version
Latest main (also affects all released versions)
### Please describe the bug
On Windows, passing a local absolute path (e.g. `C:\Users\data\warehouse`) to any PyIceberg IO operation crashes with:
``nValueError: Unrecognized filesystem type in URI: c
``n
The root cause: Python's `urlparse` treats Windows drive letters as URI schemes (`C:\...` `scheme='c'`). Since `'c'` is not in PyIceberg's scheme-to-FileIO mapping, all local file operations fail.
This affects three independent parse sites:
1. `_infer_file_io_from_scheme()` in `pyiceberg/io/__init__.py`
2. `PyArrowFileIO.parse_location()` in `pyiceberg/io/pyarrow.py`
3. `FsspecFileIO._get_fs_from_uri()` in `pyiceberg/io/fsspec.py`
### Related issues
- #2477 (CI: run tests on Windows lists this as the primary failure)
- #1005 (user report closed as stale without fix)
- PR #3161 (partial fix only pyarrow, no tests, went stale)
- PR #996 (partial fix only pyarrow, went stale)
### Proposed fix
A platform-guarded predicate that detects when `urlparse` has misidentified a Windows drive letter as a URI scheme, and remaps it to `'file'`:
`python
import sys
def _is_windows_drive_letter(scheme: str) -> bool:
return sys.platform == 'win32' and len(scheme) == 1 and scheme.isalpha()
``n
Applied at all three parse sites. Zero behavior change on non-Windows (the platform check short-circuits). Includes platform-conditional tests.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] IO: Windows paths crash with 'Unrecognized filesystem type in URI: c' [iceberg-python]
Posted by "sidharth-05 (via GitHub)" <gi...@apache.org>.
sidharth-05 commented on issue #3720:
URL: https://github.com/apache/iceberg-python/issues/3720#issuecomment-5214020300
Hi! I’d like to work on this issue. I plan to add a shared, platform-aware Windows drive-letter path check, apply it consistently at the three parsing sites described here, and add focused tests covering PyArrowFileIO, FsspecFileIO, and FileIO inference without changing non-Windows URI behavior.
If this is still available, could you please assign it to me? Thanks!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] IO: Windows paths crash with 'Unrecognized filesystem type in URI: c' [iceberg-python]
Posted by "qzyu999 (via GitHub)" <gi...@apache.org>.
qzyu999 commented on issue #3720:
URL: https://github.com/apache/iceberg-python/issues/3720#issuecomment-5219277410
> Hi! I’d like to work on this issue. I plan to add a shared, platform-aware Windows drive-letter path check, apply it consistently at the three parsing sites described here, and add focused tests covering PyArrowFileIO, FsspecFileIO, and FileIO inference without changing non-Windows URI behavior.
>
> If this is still available, could you please assign it to me? Thanks!
This is complete as of #3723.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org
Re: [I] IO: Windows paths crash with 'Unrecognized filesystem type in URI: c' [iceberg-python]
Posted by "qzyu999 (via GitHub)" <gi...@apache.org>.
qzyu999 closed issue #3720: IO: Windows paths crash with 'Unrecognized filesystem type in URI: c'
URL: https://github.com/apache/iceberg-python/issues/3720
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org