fix: Add buffer to the write file option

PiperOrigin-RevId: 785546915
This commit is contained in:
Jianfeng Zeng
2025-07-21 13:08:29 -07:00
committed by Copybara-Service
parent dfee06ac06
commit f2caf2eeca
+1 -1
View File
@@ -856,7 +856,7 @@ def get_fast_api_app(
os.makedirs(agent_dir, exist_ok=True)
file_path = os.path.join(agent_dir, filename)
with open(file_path, "w") as buffer:
with open(file_path, "wb") as buffer:
shutil.copyfileobj(file.file, buffer)
except Exception as e: