Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

style(session_host): reformat resume condition and test call

Steven Enamakelb119b3235197
diff --git a/crates/openhuman-core/src/agent/session_host/runtime_session_turn.rs b/crates/openhuman-core/src/agent/session_host/runtime_session_turn.rs
index 0a91e5b7c8..f164089b7d 100644
--- a/crates/openhuman-core/src/agent/session_host/runtime_session_turn.rs
+++ b/crates/openhuman-core/src/agent/session_host/runtime_session_turn.rs
@@ -45,11 +45,10 @@ impl OpenHumanSessionHost {
if matches!(
options.resume,
ResumeMode::Session | ResumeMode::LatestForAgent
- )
- && self
- .runtime_session
- .as_ref()
- .is_some_and(|session| session.history().is_empty())
+ ) && self
+ .runtime_session
+ .as_ref()
+ .is_some_and(|session| session.history().is_empty())
{
let runtime = self
.runtime_session
diff --git a/crates/openhuman-core/src/agent/session_host/transcript_compat_tests.rs b/crates/openhuman-core/src/agent/session_host/transcript_compat_tests.rs
index cb98a3b6cf..f48a2fdd0d 100644
--- a/crates/openhuman-core/src/agent/session_host/transcript_compat_tests.rs
+++ b/crates/openhuman-core/src/agent/session_host/transcript_compat_tests.rs
@@ -691,7 +691,9 @@ fn assert_retired_tool_replay(identity_bound: bool) {
.await
.expect("resume archive"));
} else {
- resumed.ensure_runtime_session().expect("cold runtime session");
+ resumed
+ .ensure_runtime_session()
+ .expect("cold runtime session");
assert!(matches!(
resumed.turn_resume_mode(),
tinyagents_runtime::ResumeMode::LatestForAgent