Skip to content

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

fix(storage): drop fallible unwrap from Scope::local calls

Steven Enamakel924a66d8bb51
diff --git a/crates/openhuman-core/src/storage/import/fixtures/legacy-v1-profile/generator/src/main.rs b/crates/openhuman-core/src/storage/import/fixtures/legacy-v1-profile/generator/src/main.rs
index 76032d1ecd..56313575df 100644
--- a/crates/openhuman-core/src/storage/import/fixtures/legacy-v1-profile/generator/src/main.rs
+++ b/crates/openhuman-core/src/storage/import/fixtures/legacy-v1-profile/generator/src/main.rs
@@ -212,7 +212,7 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
// local scope: the profile directory itself supplied user isolation.
// Their owners must continue to read them after the real v1-to-v2 boot
// migration.
- let user_scope = backend.for_scope(&Scope::local()?)?;
+ let user_scope = backend.for_scope(&Scope::local())?;
put(
user_scope.documents(),
"approvals",
diff --git a/crates/openhuman-core/src/storage/import/fixtures/legacy-v1-profile/storage.db b/crates/openhuman-core/src/storage/import/fixtures/legacy-v1-profile/storage.db
new file mode 100644
index 0000000000..fcfca555f7
Binary files /dev/null and b/crates/openhuman-core/src/storage/import/fixtures/legacy-v1-profile/storage.db differ
diff --git a/tests/storage_legacy_profile_boot_e2e.rs b/tests/storage_legacy_profile_boot_e2e.rs
index 65442058d1..d0ec942bd2 100644
--- a/tests/storage_legacy_profile_boot_e2e.rs
+++ b/tests/storage_legacy_profile_boot_e2e.rs
@@ -217,7 +217,7 @@ fn desktop_boot_reads_a_preserved_existing_v1_profile_database() {
openhuman_core::storage::open(&url).await
})
.unwrap();
- let scope = openhuman_core::storage::Scope::local().unwrap();
+ let scope = openhuman_core::storage::Scope::local();
let scoped = backend.for_scope(&scope).unwrap();
let secrets = openhuman_core::storage::secrets::over(
&scoped,