From e87d0c3970ddc5374938c7631022afa90e49afe1 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 25 Feb 2026 12:20:52 +0000 Subject: [PATCH 1/2] Initial plan From bd75183193486988afd2ac13900f8147f9250be7 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Wed, 25 Feb 2026 12:21:46 +0000 Subject: [PATCH 2/2] fix: close NamedTemporaryFile handle before downloading GCS blob Co-authored-by: yhyatt <10474956+yhyatt@users.noreply.github.com> --- src/dmaf/gcs_watcher.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dmaf/gcs_watcher.py b/src/dmaf/gcs_watcher.py index 905159c..1cbccec 100644 --- a/src/dmaf/gcs_watcher.py +++ b/src/dmaf/gcs_watcher.py @@ -90,8 +90,8 @@ def download_gcs_blob(gcs_path: str) -> Path: suffix = Path(blob_name).suffix tmp = tempfile.NamedTemporaryFile(delete=False, suffix=suffix, prefix="dmaf_gcs_") - blob.download_to_filename(tmp.name) tmp.close() + blob.download_to_filename(tmp.name) logger.debug(f"Downloaded {gcs_path} -> {tmp.name}") return Path(tmp.name)