From 6330400869d79c256ff4be4bbb2858c720b8009b Mon Sep 17 00:00:00 2001 From: Alex Zhou Date: Sat, 10 Oct 2026 16:47:00 +0800 Subject: [PATCH 1/3] fix(android): give gradlew the exec bit `git ls-files -s android/gradlew` reports 100644 while android/gradlew.bat is 100755: the android subtree was authored on Windows, where core.fileMode is off, so the POSIX launcher shipped without its mode. README 1.3 tells every reader to run `./gradlew :app:assembleDebug`, and on Linux/macOS that dies with "permission denied" (rc=126) before Gradle even starts. The bit is set in the index, not just on disk - chmod alone leaves the next clone broken. The repo already tracks modes elsewhere (ios/scripts/test.sh, macos/scripts/*.sh, python/scripts/fetch_models.py are all 100755), so this is a missing bit rather than a policy change. --- android/gradlew | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 android/gradlew diff --git a/android/gradlew b/android/gradlew old mode 100644 new mode 100755 From 0bea963cb0469c21ae403980ff1c923e233a2573 Mon Sep 17 00:00:00 2001 From: Alex Zhou Date: Sat, 10 Oct 2026 16:47:00 +0800 Subject: [PATCH 2/3] fix(android): fall back to pwd -P when the depot probe runs off MSYS build_vendor_libs.sh derives the monorepo root with `pwd -W`, which only exists in Git-Bash. On Linux/macOS the builtin rejects -W, the command substitution returns non-zero, and `set -euo pipefail` aborts at the depot line - silently, with no log output, which reads as a broken script rather than a host-portability gap. `{ pwd -W 2>/dev/null || pwd -P; }` leaves Git-Bash semantics untouched (the -W form wins wherever it exists) and gives other POSIX hosts the resolved path. EDGE0_DEPOT still overrides, but it is no longer required to be exported: relying on a shell variable hides the regression from everyone whose shell does not set it. Verified on Linux with EDGE0_DEPOT unset: the depot root resolves and vendor.llama.pin is visible from it. --- android/tools/llama/build_vendor_libs.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/android/tools/llama/build_vendor_libs.sh b/android/tools/llama/build_vendor_libs.sh index 49a9006..6498b41 100644 --- a/android/tools/llama/build_vendor_libs.sh +++ b/android/tools/llama/build_vendor_libs.sh @@ -7,7 +7,9 @@ # Usage: bash tools/llama/build_vendor_libs.sh [--replay] (--replay = re-apply bands + verify) set -euo pipefail REPO=$(cd "$(dirname "$0")/../.." && pwd) -DEPOT=${EDGE0_DEPOT:-$(cd "$REPO/.." && pwd -W)} # depot root (this repo lives at /android) +# `pwd -W` is the Git-Bash (MSYS) form only; on Linux/macOS it has no -W and would abort +# the script at set -e, so fall back to `pwd -P`. EDGE0_DEPOT still wins if set. +DEPOT=${EDGE0_DEPOT:-$(cd "$REPO/.." && { pwd -W 2>/dev/null || pwd -P; })} # depot root (this repo lives at /android) WT=$DEPOT/wt/and [ -f "$DEPOT/vendor.llama.pin" ] || { echo "ABORT: vendor.llama.pin missing at depot root ($DEPOT)"; exit 1; } PIN=$(cut -d' ' -f1 "$DEPOT/vendor.llama.pin") From ae76a1ae2117b9742cc5c5546c215d2858c3d6f0 Mon Sep 17 00:00:00 2001 From: Alex Zhou Date: Sat, 10 Oct 2026 16:53:10 +0800 Subject: [PATCH 3/3] docs(android): correct the host unit-test count (26 -> 32) `./gradlew :app:testDebugUnitTest` runs 32 tests here, not 26: counting @Test under app/src/test gives 32 in this tree (and in the android source the release is cut from). The instrumented figure on the line above it is accurate - app/src/androidTest carries exactly 8 @Test methods - so only the host-side number was stale. Fixed across all five language copies so they do not drift apart. --- android/README.md | 2 +- android/README_es.md | 2 +- android/README_fr.md | 2 +- android/README_ja.md | 2 +- android/README_zh.md | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/android/README.md b/android/README.md index ee9197c..5b78cf1 100644 --- a/android/README.md +++ b/android/README.md @@ -111,7 +111,7 @@ adb shell am instrument -w -e class dev.edge0.runtime.app.LlamaRuntimeTest \ Coverage: 8B/35B smoke, 35B↔8B in-process switching, prefix-reuse fidelity, thinking on/off × system-prompt quadrants (8B gate + 35B off leak probe), and identity retention across multi-turn rendering. Host-side logic tests: -`./gradlew :app:testDebugUnitTest` (26 tests, no device needed). +`./gradlew :app:testDebugUnitTest` (32 tests, no device needed). --- diff --git a/android/README_es.md b/android/README_es.md index ef65486..54c471d 100644 --- a/android/README_es.md +++ b/android/README_es.md @@ -113,7 +113,7 @@ adb shell am instrument -w -e class dev.edge0.runtime.app.LlamaRuntimeTest \ Cobertura: smoke de 8B/35B, cambio en el proceso 35B↔8B, fidelidad de la reutilización de prefijos, cuadrantes de thinking activado/desactivado × system prompt (puerta 8B + prueba de fuga con 35B desactivado) y retención de identidad en el renderizado multiturno. -Pruebas de lógica del lado del host: `./gradlew :app:testDebugUnitTest` (26 pruebas, sin +Pruebas de lógica del lado del host: `./gradlew :app:testDebugUnitTest` (32 pruebas, sin necesidad de dispositivo). --- diff --git a/android/README_fr.md b/android/README_fr.md index 5d0a988..627499e 100644 --- a/android/README_fr.md +++ b/android/README_fr.md @@ -119,7 +119,7 @@ Couverture : smoke 8B/35B, commutation 35B↔8B dans le même processus, fidélité de la réutilisation de préfixe, quadrants thinking activé/désactivé × prompt système (porte 8B + sonde de fuite 35B désactivée), et rétention d'identité à travers le rendu multi-tours. Tests logiques côté hôte : -`./gradlew :app:testDebugUnitTest` (26 tests, aucun appareil requis). +`./gradlew :app:testDebugUnitTest` (32 tests, aucun appareil requis). --- diff --git a/android/README_ja.md b/android/README_ja.md index 5f0c93a..f42e2c2 100644 --- a/android/README_ja.md +++ b/android/README_ja.md @@ -83,7 +83,7 @@ adb shell am instrument -w -e class dev.edge0.runtime.app.LlamaRuntimeTest \ # expected: OK (8 tests), ~7 min on the reference device ``` -カバレッジ: 8B/35B スモーク、35B↔8B のプロセス内切り替え、プレフィックス再利用の忠実性、thinking オン/オフ × システムプロンプトの四象限(8B ゲート + 35B オフ時のリークプローブ)、マルチターンレンダリングを通じたアイデンティティの保持。ホスト側のロジックテスト: `./gradlew :app:testDebugUnitTest`(26 テスト、デバイス不要)。 +カバレッジ: 8B/35B スモーク、35B↔8B のプロセス内切り替え、プレフィックス再利用の忠実性、thinking オン/オフ × システムプロンプトの四象限(8B ゲート + 35B オフ時のリークプローブ)、マルチターンレンダリングを通じたアイデンティティの保持。ホスト側のロジックテスト: `./gradlew :app:testDebugUnitTest`(32 テスト、デバイス不要)。 --- diff --git a/android/README_zh.md b/android/README_zh.md index 143b9c8..351df49 100644 --- a/android/README_zh.md +++ b/android/README_zh.md @@ -105,7 +105,7 @@ adb shell am instrument -w -e class dev.edge0.runtime.app.LlamaRuntimeTest \ 覆盖范围:8B/35B 冒烟、35B↔8B 进程内切换、前缀复用保真度、thinking 开/关 × 系统提示词四象限(8B 开启 + 35B 关闭泄漏探测),以及多轮渲染下的 -身份保持。宿主侧逻辑测试:`./gradlew :app:testDebugUnitTest`(26 个测试, +身份保持。宿主侧逻辑测试:`./gradlew :app:testDebugUnitTest`(32 个测试, 无需设备)。 ---