|
20 | 20 | from models_library.projects_nodes_io import NodeIDStr |
21 | 21 | from models_library.services_types import ServicePortKey |
22 | 22 | from pydantic import ByteSize |
23 | | -from servicelib.archiving_utils import PrunableFolder, archive_dir |
| 23 | +from servicelib.archiving_utils import PrunableFolder, archive_dir, unarchive_dir |
24 | 24 | from servicelib.async_utils import run_sequentially_in_context |
25 | 25 | from servicelib.file_utils import remove_directory |
26 | 26 | from servicelib.logging_utils import log_context |
|
36 | 36 |
|
37 | 37 | from ..core.settings import ApplicationSettings, get_settings |
38 | 38 | from ..modules.notifications import PortNotifier |
39 | | -from .seven_zip_wrapper import unarchive_zip_to |
40 | 39 |
|
41 | 40 |
|
42 | 41 | class PortTypeName(str, Enum): |
@@ -298,8 +297,10 @@ async def _get_data_from_port( |
298 | 297 | logging.DEBUG, |
299 | 298 | f"unzipping '{downloaded_file}' to {final_path}", |
300 | 299 | ): |
301 | | - unarchived: set[Path] = await unarchive_zip_to( |
302 | | - downloaded_file, final_path, sub_progress |
| 300 | + unarchived: set[Path] = await unarchive_dir( |
| 301 | + archive_to_extract=downloaded_file, |
| 302 | + destination_folder=final_path, |
| 303 | + progress_bar=sub_progress, |
303 | 304 | ) |
304 | 305 | dest_folder.prune(exclude=unarchived) |
305 | 306 | else: |
|
0 commit comments