Files
hakorune/docs/private/roadmap/phases/phase-20.10/README.md

44 lines
2.5 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Phase 20.10 — ScriptFirst Runner (CABI Unified)
Status
- In progress部分的に完了。Runner facade は既定ONoptoutで静穏運用可
Intent
- Move policy/coordination logic closer to Hakorune (script) while keeping dataplane at the CABI boundary.
- Unify extern calls via CABI (`hako_*`) and minimize Rustonly decision points.
- Preserve VM/LLVM parity and provide small, reversible steps (FailFast / BoxFirst).
Scope (this phase)
- Python/llvmlite 降ろしは据え置き(変更対象外)。
- 対象: 実行エンジンとランナー(調停/方針部分・Extern/効果解決・CLI/ENV/設定の「上物」を Hakorune スクリプト側に寄せる。
- ルール: Extern は CABI (`hako_*`) 経由に統一し、dotted C シンボルは AOT に流さない。
HighLevel Goals
- Script RunnerRefVM/Runner facadeを lang 側に置き、エントリ/コーディネーションを段階移譲。
- Extern/Effects の解決方針を SSOT で管理(将来 TOML → Rust/Python 生成)。
- CLI/ENV は CLI を正、ENV は補助HAKO_* を第一表記)に統一。
Outcomes so far20.10 前半の成果)
- Runner preinvoke既定ON
- 成功/失敗の短文を固定stdout`[script-runner] invoke` / `invoke: FAIL`
- 代表スモークquick/integration-coreを追加invoke / workspace-only
- UsingResolver の前段/比較/シャドウの観測フックを追加(挙動不変)。
- Externs SSOT
- `specs/externs.toml` を SSOT とし、生成スクリプトで Python/Rust を同期。
- チェックを STRICT へ昇格drift は FAIL
- Effects の取り込み導線env`HAKO_EXTERN_EFFECTS_SSOT=1`Io を反映)。
- AOT selfhost ランチャ(最小)
- `lang/build/build_runner.sh``lang/bin/hakorune` を生成LLVM18 dev が必要)。
- 代表スモークquickでビルド→実行を確認exit code=0
OutofScope
- Python/llvmlite の大きな構造変更(降ろしは現状維持)。
- GC/IO/例外/非同期の実装拡張(本フェーズでは扱わない)。
Risk & Rollback
- すべて gate 配下(既定 OFF。スモークは parity/diagnostics のみを増強。
- 戻し手順: gate を OFF、または Runner 経路を既存 Rust ラインへ戻すだけで可逆。
TTLbringup 限定トグル)
- `HAKO_SCRIPT_RUNNER_FORCE_FAIL`, `HAKO_SCRIPT_RUNNER_TRACE` は撤退済み。固定短文のみ維持invoke/FAIL