aien-sovereign-core-mv
AienOS host runtime: inference scheduling, paged KV state, the aien CLI and Spark verification tooling. Its inference engine is in alpha testing (DGX Spark GB10); Omega is the implementation destination.
Brought by drakestapleton
GitHub aien-dev/aien-sovereign-core-mv#920 (code only)
Apply it
git checkout -b patch-3b873612d4babcb8 2ae8b5469c8691666188a214bad7d623a0cf10cd curl -fsSL https://interplane.io/drakestapleton/aien-sovereign-core-mv/patches/3b873612d4babcb8.patch | git am
Provenance
github-import 1
aien-dev/aien-sovereign-core-mv
920
a7a72f5d4d88b7ee972650818d4823d0968e04c7
{"kind":"github-import","owner":"aien-dev","repo":"aien-sovereign-core-mv","number":920,"url":"https://github.com/aien-dev/aien-sovereign-core-mv/pull/920","export_sha256":"967c79e26a893657b5cdaa45efd442be5dbd2ecfe68e25f9a8c1b5da4d60d452","imported_utc":"2026-11-18T16:38:16Z","metadata":"unavailable","state_derived":true}
Changes
diff --git a/Cargo.lock b/Cargo.lock index 8d29d090..0adb62b3 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -764,7 +764,7 @@ dependencies = [ "sha1", "sync_wrapper", "tokio", - "tokio-tungstenite", + "tokio-tungstenite 0.29.0", "tower", "tower-layer", "tower-service", @@ -1689,7 +1689,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] @@ -2749,7 +2749,7 @@ version = "0.50.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7957b9740744892f114936ab4a57b3f487491bbeafaf8083688b16841a4240e5" dependencies = [ - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] @@ -3172,7 +3172,7 @@ dependencies = [ "once_cell", "socket2", "tracing", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] @@ -3210,7 +3210,7 @@ dependencies = [ "crumb-spec", "ed25519-dalek", "hex", - "rand 0.10.2", + "rand 0.8.8", "serde", "serde_json", "sha2 0.10.9", @@ -3598,7 +3598,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] @@ -4124,7 +4124,7 @@ dependencies = [ "serde", "serde_json", "tokio", - "tokio-tungstenite", + "tokio-tungstenite 0.24.0", "tracing", "tracing-subscriber", ] @@ -4389,7 +4389,7 @@ dependencies = [ "getrandom 0.4.3", "once_cell", "rustix", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] @@ -4581,9 +4581,9 @@ dependencies = [ [[package]] name = "tokio-tungstenite" -version = "0.29.0" +version = "0.24.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f72a05e828585856dacd553fba484c242c46e391fb0e58917c942ee9202915c" +checksum = "edc5f74e248dc973e0dbb7b74c7e0d6fcc301c694ff50049504004ef4d0cdcd9" dependencies = [ "futures-util", "log", @@ -4591,10 +4591,22 @@ dependencies = [ "rustls-pki-types", "tokio", "tokio-rustls", - "tungstenite", + "tungstenite 0.24.0", "webpki-roots 0.26.11", ] +[[package]] +name = "tokio-tungstenite" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8f72a05e828585856dacd553fba484c242c46e391fb0e58917c942ee9202915c" +dependencies = [ + "futures-util", + "log", + "tokio", + "tungstenite 0.29.0", +] + [[package]] name = "tokio-util" version = "0.7.19" @@ -4807,6 +4819,26 @@ version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e421abadd41a4225275504ea4d6566923418b7f05506fbc9c0fe86ba7396114b" +[[package]] +name = "tungstenite" +version = "0.24.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18e5b8366ee7a95b16d32197d0b2604b43a0be89dc5fac9f8e96ccafbaedda8a" +dependencies = [ + "byteorder", + "bytes", + "data-encoding", + "http", + "httparse", + "log", + "rand 0.8.8", + "rustls", + "rustls-pki-types", + "sha1", + "thiserror 1.0.69", + "utf-8", +] + [[package]] name = "tungstenite" version = "0.29.0" @@ -4819,8 +4851,6 @@ dependencies = [ "httparse", "log", "rand 0.9.5", - "rustls", - "rustls-pki-types", "sha1", "thiserror 2.0.20", ] @@ -4918,6 +4948,12 @@ dependencies = [ "serde", ] +[[package]] +name = "utf-8" +version = "0.7.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" + [[package]] name = "utf8-zero" version = "0.8.1" @@ -5150,7 +5186,7 @@ version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" dependencies = [ - "windows-sys 0.48.0", + "windows-sys 0.61.2", ] [[package]] diff --git a/crates/aien-cli/src/browser_mirror.rs b/crates/aien-cli/src/browser_mirror.rs index d70c525d..43e398a7 100644 --- a/crates/aien-cli/src/browser_mirror.rs +++ b/crates/aien-cli/src/browser_mirror.rs @@ -430,6 +430,12 @@ impl ChromeProcess { .map_err(|e| format!("profile dir: {}", e))?; let mut command = Command::new(binary); command.env(TAG_VAR, &tag); + // Chrome's crashpad handler keeps its database under XDG_CONFIG_HOME (default ~/.config). + // With a read-only HOME (the aien-local-ci sandbox) the handler exits with "--database is + // required" and Chrome dies with SIGTRAP before it opens the debugging port. Keep the + // config and cache dirs inside this run's throwaway profile so a read-only HOME is enough. + command.env("XDG_CONFIG_HOME", &profile_dir); + command.env("XDG_CACHE_HOME", &profile_dir); // Linux teardown signals only pidfds, never numeric PID/PGID targets, so // Chrome stays in the caller's process group: a Ctrl-C or a harness // group kill that ends the caller before Drop runs also reaches Chrome. diff --git a/scripts/test-install-release.sh b/scripts/test-install-release.sh index 7fc86cbe..50328f23 100755 --- a/scripts/test-install-release.sh +++ b/scripts/test-install-release.sh @@ -319,7 +319,14 @@ inst_args "$WORK/bin-good" "$WORK/cfg-good" --rollback || fail "rollback after r # 13. release gate: the candidate must be named and omega.lock must be the candidate's omega commit GT="$WORK/gate"; mkdir -p "$GT/scripts" "$GT/release" -cp "$ROOT/scripts/check-release-candidate.sh" "$GT/scripts/"; cp "$ROOT/release/candidate.toml" "$GT/release/"; cp "$ROOT/Cargo.lock" "$GT/" +cp "$ROOT/scripts/check-release-candidate.sh" "$GT/scripts/"; cp "$ROOT/release/candidate.toml" "$GT/release/" +# A matching tree by construction: Cargo.lock sources at exactly the candidate's [pins], as omega.lock below is +# the candidate's omega commit. The live Cargo.lock moves with dependency updates (sc#906 left one aien-protocols-mv +# source) and is not CAND-4; pin mismatches are covered by scripts/test-release-checks.sh. +pin() { sed -n '/^\[pins\]/,/^\[/p' "$GT/release/candidate.toml" | sed -n "s/^$1 *= *\"\([0-9a-f]*\)\".*/\1/p"; } +for r in aien-protocols crumb-spec spark-crumbs; do + printf '[[package]]\nsource = "git+https://github.com/aien-dev/%s?rev=%s#%s"\n' "$r" "$(pin "$r")" "$(pin "$r")" +done > "$GT/Cargo.lock" gate() { (cd "$GT" && bash scripts/check-release-candidate.sh "$@" > "$WORK/log-gate" 2>&1); } OM="$(sed -n 's/^omega-commit *= *"\(.*\)"$/\1/p' "$GT/release/candidate.toml")" echo "$OM" > "$GT/omega.lock" diff --git a/tools/aien-local-ci/registry-refresh.sh b/tools/aien-local-ci/registry-refresh.sh index 1e6cfedf..f7988c18 100755 --- a/tools/aien-local-ci/registry-refresh.sh +++ b/tools/aien-local-ci/registry-refresh.sh @@ -40,10 +40,12 @@ say() { printf '[registry-refresh] %s\n' "$*"; } die() { echo "registry-refresh: $*" >&2; exit 1; } [[ -d $JUDGE/cache && -d $OPER/cache ]] || die "registry layout missing (judge $JUDGE, operator $OPER)" -# One index directory on each side (index.crates.io-<hash>); the names must agree or the judge's cargo -# would never look where we copy. -idx_judge=$(ls "$JUDGE/cache"); idx_oper=$(ls "$OPER/cache") -[[ $idx_judge == "$idx_oper" && $(wc -w <<<"$idx_judge") -eq 1 ]] || die "index directory mismatch: judge '$idx_judge' operator '$idx_oper'" +# The judge has one index directory (index.crates.io-<hash>). The operator's ~/.cargo may hold more than +# one (a cargo release that changed the hash leaves the old one behind); only the judge's name matters, +# because the judge's cargo never looks anywhere else, so the operator must have that same directory. +idx_judge=$(ls "$JUDGE/cache") +[[ $(wc -w <<<"$idx_judge") -eq 1 ]] || die "judge registry must hold exactly one index directory, found '$idx_judge'" +[[ -d $OPER/cache/$idx_judge ]] || die "index directory mismatch: operator has no '$idx_judge' (has '$(ls "$OPER/cache")')" idx=$idx_judge SRC_DIR=$JUDGE/src/$idx diff --git a/tools/aien-local-ci/tests/registry_refresh_test.sh b/tools/aien-local-ci/tests/registry_refresh_test.sh index 1e7e264b..e1cee391 100755 --- a/tools/aien-local-ci/tests/registry_refresh_test.sh +++ b/tools/aien-local-ci/tests/registry_refresh_test.sh @@ -131,5 +131,14 @@ out=$(AIEN_JUDGE_REGISTRY=$T/judge2 bash "$R" "$T/Cargo.lock" 2>&1) && rc=0 || r check "index dir mismatch refused" test $rc -eq 1 check "index dir mismatch message" grep -q 'index directory mismatch' <<<"$out" +# 9 an extra, stale operator index directory (left by an older cargo) does not block the judge's one +mkdir -p "$O/cache/index.crates.io-0000000000000000" +sha_extra=$(mk "$O/cache/$IDX" extra 1.0.0) +pkg extra 1.0.0 "$sha_extra" >> "$T/Cargo.lock" +out=$(bash "$R" "$T/Cargo.lock" 2>&1) && rc=0 || rc=$? +check "stale operator index dir ignored" test -f "$J/cache/$IDX/extra-1.0.0.crate" +check "stale operator index dir not copied" test ! -e "$J/cache/index.crates.io-0000000000000000" +rmdir "$O/cache/index.crates.io-0000000000000000" + echo "registry_refresh_test: $pass passed, $fail failed" (( fail == 0 ))