Skip to content

Add built-in download tool#20

Draft
ZhiXiao-Lin wants to merge 1 commit into
mainfrom
agent/builtin-download-tool
Draft

Add built-in download tool#20
ZhiXiao-Lin wants to merge 1 commit into
mainfrom
agent/builtin-download-tool

Conversation

@ZhiXiao-Lin

Copy link
Copy Markdown

Summary

  • add a local-workspace download tool inspired by Surge's range probe, adaptive chunking, bounded retry, sequential fallback, and atomic finalization
  • share the SSRF-safe HTTP transport with web_fetch, including DNS pinning, manual redirect validation, proxy support, credential isolation, and redacted source anchors
  • enforce binary-safe streaming, size/time limits, coherent validators, strict Content-Range checks, optional SHA-256, cancellation cleanup, and workspace/symlink boundaries
  • wire download into permissions, HITL risk assessment, selection, queues, subagents, task projection, skill validation, and local-backend registration
  • document the tool and add unit plus HTTP integration coverage

Validation

  • cargo fmt --all -- --check
  • cargo check -p a3s-code-core
  • cargo clippy -p a3s-code-core --lib -- -D warnings
  • download/governance/shared HTTP focused tests: passed
  • cargo test -p a3s-code-core --test test_workspace_backend custom_workspace_file_tools_do_not_touch_local_filesystem: passed
  • full lib suite: 2418 passed, 9 ignored, 1 existing Windows-only failure. agent_api::tests::test_verify_commands_builds_report_from_bash_results runs the Unix command printf ok through the Windows PowerShell-backed BashTool and fails independently when rerun in isolation.

Reference

Implementation principles were checked against Surge's probe, concurrent worker, scheduler fallback, and sync-then-rename finalization behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant