Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
mxmlnkn committed Oct 5, 2024
1 parent e2e4d7c commit ad4baf9
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 5 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,9 @@ jobs:

steps:
- uses: actions/checkout@v4
with:
# We need one tag for testing the git mount.
fetch-tags: true

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
Expand Down Expand Up @@ -216,7 +219,12 @@ jobs:
# Segfaults (139) are not allowed but other exit codes are valid!
python3 ratarmount.py tests/simple.bz2 || [ $? != 139 ]
- name: Install pip Test Dependencies
run: |
python3 -m pip install -r tests/requirements-tests.txt
- name: Unit Tests
if: false
run: |
python3 -m pip install pytest pytest-xdist
for file in core/tests/test_*.py tests/test_*.py; do
Expand Down Expand Up @@ -246,6 +254,15 @@ jobs:
done
python3 tests/tests.py
- name: Git Debug
if: ${{ !startsWith( matrix.os, 'macos' ) }}
run: |
git status
pwd
ls -la
ls -la .git
git show --stat v0.15.2
- name: Regression Tests (FUSE 3)
if: ${{ !startsWith( matrix.os, 'macos' ) }}
run: |
Expand Down
3 changes: 1 addition & 2 deletions core/ratarmountcore/FSSpecMountSource.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
try:
import fsspec
import fsspec.core
import fsspec.implementations.http
except ImportError:
fsspec = None # type: ignore

Expand All @@ -36,7 +35,7 @@ def __init__(self, urlOrOpenFile, **options) -> None:
# The fsspec filesystems are not uniform! http:// expects the arguments to isdir with prefixed
# protocol while other filesystem implementations are fine with only the path.
# https://github.com/ray-project/ray/issues/26423#issuecomment-1179561181
self._isHTTP = isinstance(self.fileSystem, fsspec.implementations.http.HTTPFileSystem)
self._isHTTP = self.fileSystem.protocol.startswith('http')
prefix = self.openFile.path
self.prefix = prefix.rstrip("/") if prefix.strip("/") and self.fileSystem.isdir(prefix) else ""

Expand Down
4 changes: 1 addition & 3 deletions tests/runtests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2039,9 +2039,7 @@ checkRemoteSupport()
# https://filesystem-spec.readthedocs.io/en/latest/api.html#other-known-implementations
checkURLProtocolFile
checkURLProtocolSamba
#checkURLProtocolGit # TODO does not work in CI for some reason...
# Warning: Trying to open with fsspec raised an exception: 'v0.15.2'
# Error: Mount source does not exist: git://v0.15.2@tests/single-file.tar
checkURLProtocolGit # TODO does not work in CI for some reason...

#checkURLProtocolHTTP # TODO
checkURLProtocolFTP
Expand Down

0 comments on commit ad4baf9

Please sign in to comment.