feat: vault core/CLI/workbench, vaultd token path, filetree view-state cleanup

Land password-vault dedicated workbench and mnote-vault-core/CLI, agent token
read path design, vault transport split, and retire obsolete filetree smokes.
Ignore local vault reimport scripts that trip secret scanners.
This commit is contained in:
Agent Board
2026-07-24 11:36:06 +08:00
parent b798f628ee
commit bc6f8488ee
41 changed files with 13072 additions and 2316 deletions
+30
View File
@@ -58,6 +58,35 @@ paseo_browser_screenshot
| Paseo 终端无输出 | 前台进程阻塞 | 用 `nohup ... &` 后台启动 |
| `desktop:hot` vs `dev:hot` | 启动命令不同 | 浏览器测试用 `dev:hot` |
### 6. AI 密码本读密 / 登录态(12-2 · **不依赖 3000**
读密与 login/session 走本地 core + capability token**不要**为 resolve/login/session 启 mnote-web。
```bash
cd rust
cargo build -q -p mnote-vault
# 一次签发(写入 ~/.config/mnote/vault-tokens/default.token;默认 scope 含 login,session
./target/debug/mnote-vault issue-token --agent smoke --ttl 1d
./target/debug/mnote-vault doctor
# 可选常驻 UDS$XDG_RUNTIME_DIR/mnote-vaultd.sock 或 MNOTE_VAULT_SOCK
./target/debug/mnote-vault serve &
./target/debug/mnote-vault list # sock 优先,不可达则内嵌 core
./target/debug/mnote-vault resolve --id <cred_id> --field password
./target/debug/mnote-vault resolve --id <id> --field password --local # 强制内嵌
./target/debug/mnote-vault resolve --id <id> --field password --remote # 强制 UDS
# session 回写 + login 复用(无外站 HTTP
./target/debug/mnote-vault session --id <id> --cookie-header 'mnote_session=smoke; other=1' --local
./target/debug/mnote-vault login --id <id> --local # 期望 reused=true / mode=session
cargo test -p mnote-vault-core --lib
cargo test -p mnote-web --lib routes::vault::resolve_strategy_tests
cargo test -p mnote-web --lib routes::vault -- --nocapture 2>&1 | rg -n "login_reuses|ok"
```
- Crate`mnote-vault-core``mnote-vault`bin,含 `serve` + login/session)、`mnote-web` AI list/get/resolve/login/session thin-wrap core
- 设计:`design/12-vault/process/12-2-vaultd-local-token-agent-read-path-v1.md`
- Skill / 策略:`$mnote-vault``/home/lix/.agent-infra/vault-policy.md`
- Web UI / CRUD workbench 仍可走 3000**list/get/resolve/login/session 稳态禁止以 auth-e2e 为前置**
这份文档面向 `/mnt/Data1T/mnote/scripts` 目录下的现有测试脚本,目标不是重新设计测试体系,而是把当前已经在用的 smoke、回归脚本、截图取证和人工复核方式整理成一套可执行参考。
当前结论先说在前面:
@@ -113,6 +142,7 @@ node scripts/task490-runtime-surfaces-smoke.js
- WeKnora 默认 provider 脚本(`task544``task769``task772``task777``task781``task783``task784``task785``task787``task788``task789``task790``task79x`)已退役;它们与 LightRAG 默认 provider 主线相反。
- Hermes/ACP/Reasonix 页面 AI 主流程 smoke 已退役;只保留 `task-hermes-page-ai-retirement-guard.js` 防止旧 runtime 复活。`task762-page-ai-board-first-smoke.js` 也已退役。
-`task019``task021``task022` 这类早期 UI regression 脚本已软删除到 `recycle/scripts/retired-ui-regressions/`,只作为历史对照;后续默认不要用于当前 Rust SSR / local-first 主路径验收。
- `task494-filetree-lazy-loading-dedup-smoke.js``task498-starred-page-tree-scope-and-local-edit-smoke.js``task499-sidebar-tree-view-state-smoke.js`2026-07-21 诊断为 fixture/契约过时(非 Playwright 安装问题),已迁到 `recycle/scripts/obsolete-tree-smokes-20260721/`。全局 Playwright 栈:`~/.agent-infra/playwright-stack`(见该目录 `use-in-project.md`)。树移动排序优先 `task447-tree-move-order-dual-browser-live-smoke.js` 或 Hermes tree QA。
### 0.3 其他 current 候选脚本