This pull request introduces a new `Sandbox.download_file` interface for binary retrieval and implements it in both `AioSandbox` and `LocalSandbox`, creating a consistent way to fetch raw file contents from sandboxed runs; it also adds tests covering normal, empty, lock-aware, error, and single-chunk download paths to make the behavior explicit and regressions easier to catch.
What ChangedThis pull request introduces a new `Sandbox.download_file` interface for binary retrieval and implements it in both `AioSandbox` and `LocalSandbox`, creating a consistent way to fetch raw file contents from sandboxed runs; it also adds tests covering normal, empty, lock-aware, error, and single-chunk download paths to make the behavior explicit and regressions easier to catch.
Why It MattersDevelopers and operators using bytedance/deer-flow can now pull generated artifacts (such as images or outputs) directly from sandbox environments, reducing custom integration work and improving reliability of downstream pipelines that depend on file-based results. The technical impact is a standardized `download_file` path in both local and async sandboxes, so teams should watch for compatibility of custom sandbox backends, large-file transfer behavior, and lock/error path consistency as workloads increase.