lha 1.0.6

Long-Horizon Agent command-line package that installs the lha binary.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use crate::product::app_server_protocol::protocol::v1;
use crate::product::app_server_protocol::protocol::v2;

impl From<v1::ExecOneOffCommandParams> for v2::CommandExecParams {
    fn from(value: v1::ExecOneOffCommandParams) -> Self {
        Self {
            command: value.command,
            timeout_ms: value
                .timeout_ms
                .map(|timeout| i64::try_from(timeout).unwrap_or(60_000)),
            cwd: value.cwd,
            sandbox_policy: value.sandbox_policy.map(std::convert::Into::into),
        }
    }
}