agent-zero/plugins/_code_execution/helpers
Alessandro ad5bebbea5 Send complete SSH commands without blocking the event loop
Paramiko Channel.send can accept only part of a command. Ignoring its byte
count truncated large inputs, including heredocs whose closing delimiters
never reached the shell.

Use sendall through asyncio.to_thread and route shell initialization through
the same send path. Close the SSH connection when an in-flight send is
cancelled so partial input cannot contaminate later commands. Cancellation
intentionally discards that SSH session and its shell state.

Add regressions for multi-packet Unicode delivery and blocked-window
responsiveness/cancellation, and document the SSH send contract.

Validation: 24 focused tests passed. Real Paramiko transport and container
OpenSSH probes delivered complete large single/nested heredocs and preserved
shell state across terminal, Python and Node.js calls. No local TTY, prompt
readiness, tool-dispatch, or platform-specific heredoc workaround changes.
2026-10-06 18:49:30 +02:00
..
__init__.py refactor - plugin names and builtin plugins 2026-03-10 22:20:53 +01:00
shell_local.py fix: release deferred task resources 2026-07-20 21:15:35 +02:00
shell_ssh.py Send complete SSH commands without blocking the event loop 2026-10-06 18:49:30 +02:00
tty_session.py Fix native Windows TTY cleanup 2026-10-06 18:49:30 +02:00