From 25c51250b6ea0ed97c45f55ab8af4d352003d248 Mon Sep 17 00:00:00 2001 From: mxmlnkn Date: Sun, 6 Oct 2024 20:41:49 +0200 Subject: [PATCH] fixup! [feature] Add support for fsspec backends --- .github/workflows/appimage-develop.yml | 9 +++++++-- .github/workflows/appimage.yml | 16 ++++++++++++++-- .github/workflows/tests.yml | 14 +++++++------- AppImage/build-ratarmount-appimage.sh | 5 ++++- 4 files changed, 32 insertions(+), 12 deletions(-) diff --git a/.github/workflows/appimage-develop.yml b/.github/workflows/appimage-develop.yml index f4650c4f..2ba9eb70 100644 --- a/.github/workflows/appimage-develop.yml +++ b/.github/workflows/appimage-develop.yml @@ -73,8 +73,6 @@ jobs: ratarmount --help ratarmount --version - - uses: actions/checkout@v4 - - name: Test Simple Mount run: | ratarmount tests/single-file.tar mimi @@ -82,6 +80,13 @@ jobs: sleep 1s ratarmount -u mimi + - name: Install pip Test Dependencies + run: | + python3 -m pip install -r tests/requirements-tests.txt + # Explicitly install pygit2 even on Python 3.13+ because we have set up libgit2 manually. + python3 -m pip install pygit2 + python3 -c 'import pygit2' + - name: Regression Tests run: | # Starting up ratarmount for each very short test is quite slow, especially on the CI machine (3-5s). diff --git a/.github/workflows/appimage.yml b/.github/workflows/appimage.yml index b9d9fb44..1c6bba41 100644 --- a/.github/workflows/appimage.yml +++ b/.github/workflows/appimage.yml @@ -62,13 +62,18 @@ jobs: # These are required for creating test files on the fly not for ratarmount! sudo apt-get -y install bzip2 pixz zstd unar fuse + - name: Install pip Test Dependencies + run: | + python3 -m pip install -r tests/requirements-tests.txt + # Explicitly install pygit2 even on Python 3.13+ because we have set up libgit2 manually. + python3 -m pip install pygit2 + python3 -c 'import pygit2' + - name: Test Simple Startup run: | ratarmount --help ratarmount --version - - uses: actions/checkout@v4 - - name: Test Simple Mount run: | ratarmount tests/single-file.tar mimi @@ -76,6 +81,13 @@ jobs: sleep 1s ratarmount -u mimi + - name: Install pip Test Dependencies + run: | + python3 -m pip install -r tests/requirements-tests.txt + # Explicitly install pygit2 even on Python 3.13+ because we have set up libgit2 manually. + python3 -m pip install pygit2 + python3 -c 'import pygit2' + - name: Regression Tests run: | # Starting up ratarmount for each very short test is quite slow, especially on the CI machine (3-5s). diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 904b9d3a..b646773d 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -234,13 +234,6 @@ 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 - # Explicitly install pygit2 even on Python 3.13+ because we have set up libgit2 manually. - python3 -m pip install pygit2 - python3 -c 'import pygit2' - - name: Unit Tests run: | python3 -m pip install pytest pytest-xdist @@ -271,6 +264,13 @@ jobs: done python3 tests/tests.py + - name: Install pip Test Dependencies + run: | + python3 -m pip install -r tests/requirements-tests.txt + # Explicitly install pygit2 even on Python 3.13+ because we have set up libgit2 manually. + python3 -m pip install pygit2 + python3 -c 'import pygit2' + - name: Regression Tests (FUSE 3) if: ${{ !startsWith( matrix.os, 'macos' ) }} run: | diff --git a/AppImage/build-ratarmount-appimage.sh b/AppImage/build-ratarmount-appimage.sh index ec661582..08d2b2b9 100644 --- a/AppImage/build-ratarmount-appimage.sh +++ b/AppImage/build-ratarmount-appimage.sh @@ -86,6 +86,9 @@ function installAppImagePythonPackages() # And we need to apply a patch for that. "$APP_PYTHON_BIN" -I -m pip install --no-cache-dir pyfatfs patch -u "$( find "$APP_DIR" -type f -name FatIO.py )" pyfatfs-issue-41.patch + + # These are untested but small enough that we can just install them for now. Maybe they even work. + "$APP_PYTHON_BIN" -I -m pip install --no-cache-dir gcsfs adlfs dropboxdrivefs } function installAppImageSystemLibraries() @@ -185,7 +188,7 @@ function trimAppImage() "$APP_PYTHON_LIB/smtplib.py" \ "$APP_PYTHON_LIB/smtpd.py" \ "$APP_PYTHON_LIB/ensurepip" \ - "$APP_PYTHON_LIB/html" \ + #"$APP_PYTHON_LIB/html" \ # Needed by botocore "$APP_PYTHON_LIB/idlelib" \ "$APP_PYTHON_LIB/pickletools.py" \ "$APP_PYTHON_LIB/pydoc_data" \