Skip to content

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

test(json_rpc_e2e): clone config before moving into scoped task

Steven Enamakel1cebf7c2364c
diff --git a/evidence/issue75/native-host-e2e-scoped-calls-fixed.after b/evidence/issue75/native-host-e2e-scoped-calls-fixed.after
new file mode 100644
index 0000000000..8fe71dc48e
--- /dev/null
+++ b/evidence/issue75/native-host-e2e-scoped-calls-fixed.after
@@ -0,0 +1 @@
+61d7991f773d0bbf96dc978737d42a8e7c666ec8
diff --git a/evidence/issue75/native-host-e2e-scoped-calls-fixed.before b/evidence/issue75/native-host-e2e-scoped-calls-fixed.before
new file mode 100644
index 0000000000..8fe71dc48e
--- /dev/null
+++ b/evidence/issue75/native-host-e2e-scoped-calls-fixed.before
@@ -0,0 +1 @@
+61d7991f773d0bbf96dc978737d42a8e7c666ec8
diff --git a/evidence/issue75/native-host-e2e-scoped-calls-fixed.exit b/evidence/issue75/native-host-e2e-scoped-calls-fixed.exit
new file mode 100644
index 0000000000..573541ac97
--- /dev/null
+++ b/evidence/issue75/native-host-e2e-scoped-calls-fixed.exit
@@ -0,0 +1 @@
+0
diff --git a/tests/json_rpc_e2e.rs b/tests/json_rpc_e2e.rs
index e7589fc21d..8ef491a579 100644
--- a/tests/json_rpc_e2e.rs
+++ b/tests/json_rpc_e2e.rs
@@ -3178,10 +3178,11 @@ async fn json_rpc_cron_manual_worker_survives_caller_cancel_on_published_tinyflo
let duplicate_context = Arc::clone(&default_context);
let duplicate_job_id = first_job.id.clone();
+ let duplicate_config = config.clone();
let duplicate = CoreContext::scope(Arc::clone(&duplicate_context), async move {
openhuman_core::cron::ops::run_job_now(
&DispatchCtx::new(Arc::clone(&duplicate_context)),
- &config,
+ &duplicate_config,
&duplicate_job_id,
)
.await