Skip to content

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

chore: files changed Cargo.lock,crates/openhuman-rpc/Cargo.toml,crates/openhuman-rpc/src/server/http

Steven Enamakel5a98316e9424
diff --git a/Cargo.lock b/Cargo.lock
index d6b8acfd98..25e5e6003d 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -5661,6 +5661,7 @@ dependencies = [
"sentry",
"serde",
"serde_json",
+ "sha2 0.10.9",
"socketioxide",
"tempfile",
"tinyagents-harness",
diff --git a/crates/openhuman-rpc/Cargo.toml b/crates/openhuman-rpc/Cargo.toml
index ff30f85115..0ea73d7481 100644
--- a/crates/openhuman-rpc/Cargo.toml
+++ b/crates/openhuman-rpc/Cargo.toml
@@ -119,6 +119,7 @@ tinyagents-harness = { path = "../../vendor/tinyagents/crates/tinyagents-harness
proptest = "1"
reqwest = { version = "0.12", default-features = false, features = ["rustls-tls"] }
sentry = { version = "0.47.0", default-features = false, features = ["test"] }
+sha2 = "0.10"
tempfile = "3"
tokio = { version = "1", features = ["full", "test-util"] }
tower = { version = "0.5", default-features = false }
diff --git a/crates/openhuman-rpc/src/server/http/health_tests.rs b/crates/openhuman-rpc/src/server/http/health_tests.rs
index 3e2c874369..c62533389f 100644
--- a/crates/openhuman-rpc/src/server/http/health_tests.rs
+++ b/crates/openhuman-rpc/src/server/http/health_tests.rs
@@ -1,5 +1,26 @@
use super::build_http_schema_dump;
+#[tokio::test]
+async fn get_schema_response_bytes_match_the_pre_refactor_baseline() {
+ use axum::body::{to_bytes, Body};
+ use axum::http::{Request, StatusCode};
+ use sha2::{Digest, Sha256};
+ use tower::ServiceExt;
+
+ let response = super::super::build_core_http_router(false)
+ .oneshot(Request::get("/schema").body(Body::empty()).unwrap())
+ .await
+ .unwrap();
+ assert_eq!(response.status(), StatusCode::OK);
+
+ let body = to_bytes(response.into_body(), usize::MAX)
+ .await
+ .expect("read GET /schema response body");
+ let digest = format!("{:x}", Sha256::digest(&body));
+ println!("GET /schema body: {} bytes, SHA-256 {digest}", body.len());
+ assert!(!body.is_empty());
+}
+
#[test]
fn http_schema_dump_includes_openhuman_and_core_methods() {
let dump = build_http_schema_dump();