Skip to content

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

chore(session): reformat debug log and test call for readability

Steven Enamakelde2cefea0139
diff --git a/crates/openhuman-session/src/manager.rs b/crates/openhuman-session/src/manager.rs
index e53b4aa288..7cb95f0fcd 100644
--- a/crates/openhuman-session/src/manager.rs
+++ b/crates/openhuman-session/src/manager.rs
@@ -545,7 +545,9 @@ impl<L: CoreLink> SessionManager<L> {
// is superseded. Do not combine that retried user with the core
// snapshot from before the credential change.
if self.core_state().await? != core {
- log::debug!("{LOG_PREFIX} session state changed while reading current user; retrying");
+ log::debug!(
+ "{LOG_PREFIX} session state changed while reading current user; retrying"
+ );
continue;
}
return Ok(SessionState {
diff --git a/crates/openhuman-session/src/manager_tests.rs b/crates/openhuman-session/src/manager_tests.rs
index c3b565f362..de725f979f 100644
--- a/crates/openhuman-session/src/manager_tests.rs
+++ b/crates/openhuman-session/src/manager_tests.rs
@@ -312,9 +312,12 @@ async fn state_retries_its_core_snapshot_after_a_superseded_refresh() {
tokio::spawn(async move { m.state().await })
};
tokio::time::sleep(std::time::Duration::from_millis(100)).await;
- m.store_session_token(&LIVE_JWT_NO_SUB, Some(serde_json::json!({ "id": "user-456" })))
- .await
- .unwrap();
+ m.store_session_token(
+ &LIVE_JWT_NO_SUB,
+ Some(serde_json::json!({ "id": "user-456" })),
+ )
+ .await
+ .unwrap();
let state = reading.await.unwrap().unwrap();
assert_eq!(state.core.user_id.as_deref(), Some("user-456"));