From 1df4c265027453a4ec81f06e941ac13c1d2be5c4 Mon Sep 17 00:00:00 2001 From: Ivan Longin Date: Fri, 16 Aug 2024 01:54:19 +0200 Subject: [PATCH] fixing test --- src/datachain/lib/dc.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/src/datachain/lib/dc.py b/src/datachain/lib/dc.py index 7e0124615..31cb720ee 100644 --- a/src/datachain/lib/dc.py +++ b/src/datachain/lib/dc.py @@ -386,7 +386,10 @@ def from_storage( client_config["anon"] = True session = Session.get( - session, catalog=kwargs.get("catalog"), client_config=client_config + session, + catalog=kwargs.get("catalog"), + client_config=client_config, + in_memory=in_memory, ) client, path = Client.parse_url( @@ -404,7 +407,7 @@ def from_storage( client.uri, posixpath.join(lst_path, "") ) - for ds in cls.datasets(session=session).collect("dataset"): + for ds in cls.datasets(session=session, in_memory=in_memory).collect("dataset"): # TODO filter out expired ones if ( DatasetRecord.contains_listing( @@ -421,7 +424,12 @@ def from_storage( ) ( - cls.from_records(DataChain.DEFAULT_FILE_RECORD, session=session, **kwargs) + cls.from_records( + DataChain.DEFAULT_FILE_RECORD, + session=session, + in_memory=in_memory, + **kwargs, + ) .gen( list_bucket(lst_uri, **session.catalog.client_config), output={f"{object_name}": file_type},