fix import err

This commit is contained in:
jstit
2025-01-17 16:36:14 +07:00
parent 138f80bb81
commit edceb8e22b
2 changed files with 12 additions and 0 deletions
+1
View File
@@ -0,0 +1 @@
# This file can be empty - it just marks the directory as a Python package
+11
View File
@@ -305,6 +305,17 @@ def download_file_temp(
chunk_size_in_mb=16,
file_integrity_check_callback=None,
):
"""
Downloads a file from a URL to a temporary location and yields the path.
Automatically cleans up the temporary file after use.
Args:
url (str): The URL to download from
Yields:
str: Path to the temporary downloaded file
"""
file_name = _parse_filename(url, None)
with tempfile.TemporaryDirectory() as temp_dir: