Skip to content

Commit cb52c10

Browse files
committed
Allow mtransfer to be called with iterable
Only go over the loop once.
1 parent 3d7fdce commit cb52c10

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

python/lsst/resources/_resourcePath.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
fsspec = None
3838
AbstractFileSystem = type
3939

40-
from collections.abc import Iterable, Iterator, Sequence
40+
from collections.abc import Iterable, Iterator
4141
from typing import TYPE_CHECKING, Any, Literal, overload
4242

4343
from ._resourceHandles._baseResourceHandle import ResourceHandleProtocol
@@ -934,7 +934,7 @@ def _mexists(cls, uris: Iterable[ResourcePath]) -> dict[ResourcePath, bool]:
934934
def mtransfer(
935935
cls,
936936
transfer: str,
937-
from_to: Sequence[tuple[ResourcePath, ResourcePath]],
937+
from_to: Iterable[tuple[ResourcePath, ResourcePath]],
938938
overwrite: bool = False,
939939
transaction: TransactionProtocol | None = None,
940940
) -> dict[ResourcePath, bool]:

0 commit comments

Comments
 (0)