nebius/SWE-rebench-V2-PRs huggingface dataset:
Repository: fsspec/universal_pathlib
Pull request #358 (2025-04-21 16:36:24)

List late registered protocols
List late registered fsspec filesystems via available_protocols


Patch:
diff --git a/upath/registry.py b/upath/registry.py
index 27e5d01..150bdea 100644
--- a/upath/registry.py
+++ b/upath/registry.py
@@ -44,6 +44,7 @@ from typing import MutableMapping
 
 from fsspec.core import get_filesystem_class
 from fsspec.registry import known_implementations as _fsspec_known_implementations
+from fsspec.registry import registry as _fsspec_registry
 
 import upath
 
@@ -148,11 +149,10 @@ def available_implementations(*, fallback: bool = False) -> list[str]:
         If True, also return protocols for fsspec filesystems without
         an implementation in universal_pathlib.
     """
-    impl = list(_registry)
     if not fallback:
-        return impl
+        return list(_registry)
     else:
-        return list({*impl, *list(_fsspec_known_implementations)})
+        return list({*_registry, *_fsspec_registry, *_fsspec_known_implementations})
 
 
 def register_implementation(


Test patch:
diff --git a/upath/tests/test_registry.py b/upath/tests/test_registry.py
index f0562de..294b132 100644
--- a/upath/tests/test_registry.py
+++ b/upath/tests/test_registry.py
@@ -1,5 +1,12 @@
+import random
+import string
+
 import pytest
-from fsspec.registry import known_implementations
+from fsspec.implementations.local import LocalFileSystem
+from fsspec.registry import _registry as fsspec_registry_private
+from fsspec.registry import known_implementations as fsspec_known_implementations
+from fsspec.registry import register_implementation as fsspec_register_implementation
+from fsspec.registry import registry as fsspec_registry
 
 from upath import UPath
 from upath.registry import available_implementations
@@ -69,9 +76,29 @@ def test_available_implementations():
     assert set(impl) == IMPLEMENTATIONS
 
 
-def test_available_implementations_with_fallback():
+@pytest.fixture
+def fake_registered_proto():
+    fake_proto = "".join(random.choices(string.ascii_lowercase, k=8))
+
+    class FakeRandomFS(LocalFileSystem):
+        protocol = fake_proto
+
+    fsspec_register_implementation(fake_proto, FakeRandomFS)
+    try:
+        yield fake_proto
+    finally:
+        fsspec_registry_private.pop(fake_proto, None)
+
+
+def test_available_implementations_with_fallback(fake_registered_proto):
     impl = available_implementations(fallback=True)
-    assert set(impl) == IMPLEMENTATIONS.union(list(known_implementations))
+    assert fake_registered_proto in impl
+    assert set(impl) == IMPLEMENTATIONS.union(
+        {
+            *fsspec_known_implementations,
+            *fsspec_registry,
+        }
+    )
 
 
 def test_available_implementations_with_entrypoint(fake_entrypoint):
Repository: fsspec/universal_pathlib
Pull request #361 (2025-04-21 18:25:20)

upath: update flavours and fix GH test skipping


Patch:
diff --git a/dev/requirements.txt b/dev/requirements.txt
index d9ce737..d9f3683 100644
--- a/dev/requirements.txt
+++ b/dev/requirements.txt
@@ -6,13 +6,13 @@ boxfs==0.3.0
 dropboxdrivefs==1.4.1
 gcsfs==2025.3.2
 s3fs==2025.3.2
-ocifs==1.3.1
+ocifs==1.3.2
 webdav4[fsspec]==0.10.0
 # gfrivefs @ git+https://github.com/fsspec/gdrivefs@master broken ...
 morefs[asynclocalfs]==0.2.2
-dvc==3.58.0
-huggingface_hub==0.29.2
-lakefs-spec==0.11.0
+dvc==3.59.1
+huggingface_hub==0.30.2
+lakefs-spec==0.11.3
 ossfs==2023.12.0
-fsspec-xrootd==0.4.0
+fsspec-xrootd==0.5.1
 wandbfs==0.0.2
diff --git a/upath/_flavour_sources.py b/upath/_flavour_sources.py
index 47be9bc..b77c921 100644
--- a/upath/_flavour_sources.py
+++ b/upath/_flavour_sources.py
@@ -574,7 +574,7 @@ class HadoopFileSystemFlavour(AbstractFileSystemFlavour):
 
 class HfFileSystemFlavour(AbstractFileSystemFlavour):
     __orig_class__ = 'huggingface_hub.hf_file_system.HfFileSystem'
-    __orig_version__ = '0.29.2'
+    __orig_version__ = '0.30.2'
     protocol = ('hf',)
     root_marker = ''
     sep = '/'
@@ -590,7 +590,7 @@ class JupyterFileSystemFlavour(AbstractFileSystemFlavour):
 
 class LakeFSFileSystemFlavour(AbstractFileSystemFlavour):
     __orig_class__ = 'lakefs_spec.spec.LakeFSFileSystem'
-    __orig_version__ = '0.11.0'
+    __orig_version__ = '0.11.3'
     protocol = ('lakefs',)
     root_marker = ''
     sep = '/'
@@ -722,7 +722,7 @@ class MemoryFileSystemFlavour(AbstractFileSystemFlavour):
 
 class OCIFileSystemFlavour(AbstractFileSystemFlavour):
     __orig_class__ = 'ocifs.core.OCIFileSystem'
-    __orig_version__ = '1.3.1'
+    __orig_version__ = '1.3.2'
     protocol = ('oci', 'ocilake')
     root_marker = ''
     sep = '/'
@@ -924,7 +924,7 @@ class WebdavFileSystemFlavour(AbstractFileSystemFlavour):
 
 class XRootDFileSystemFlavour(AbstractFileSystemFlavour):
     __orig_class__ = 'fsspec_xrootd.xrootd.XRootDFileSystem'
-    __orig_version__ = '0.4.0'
+    __orig_version__ = '0.5.1'
     protocol = ('root',)
     root_marker = '/'
     sep = '/'
@@ -963,7 +963,7 @@ class ZipFileSystemFlavour(AbstractFileSystemFlavour):
 
 class _DVCFileSystemFlavour(AbstractFileSystemFlavour):
     __orig_class__ = 'dvc.fs.dvc._DVCFileSystem'
-    __orig_version__ = '3.58.0'
+    __orig_version__ = '3.59.1'
     protocol = ('dvc',)
     root_marker = '/'
     sep = '/'


Test patch:
diff --git a/upath/tests/implementations/test_github.py b/upath/tests/implementations/test_github.py
index 81db812..d6330f2 100644
--- a/upath/tests/implementations/test_github.py
+++ b/upath/tests/implementations/test_github.py
@@ -10,7 +10,9 @@ from upath.tests.cases import BaseTests
 
 pytestmark = pytest.mark.skipif(
     os.environ.get("CI")
-    and (sys.version_info not in {(3, 8), (3, 12)} and platform.system() != "Linux"),
+    and not (
+        platform.system() == "Linux" and sys.version_info[:2] in {(3, 9), (3, 13)}
+    ),
     reason="Skipping GitHubPath tests to prevent rate limiting on GitHub API.",
 )