Add structured verify JSON reports and safe Blueprint materialize export to @wp-playground/cli
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 35/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- javascript, wasm, wordpress
调研方向
Start by reading the @wp-playground/cli implementation and the linked reference patterns wpai verify and wpai export, then review the staged proposal and related PR for the proposed report and state schemas. Agree on the command or Blueprint convention and safety invariants before implementation; done means the upstream interface and minimal PR scope are agreed, with verification and materialization behavior specified.
由索引模型根据 Issue 内容生成。
描述
Problem
@wp-playground/cli already gives agents a one-command, zero-MySQL path to boot Blueprints. Two adjacent contracts are still missing for reliable agent loops:
- Structured verify / JSON report —
run-blueprintexecutes steps, but agents lack a first-class, machine-parseable pass/fail report for site options, content presence, REST routes, Abilities, and PHP fatals. Today they scrape logs or invent ad-hocrunPHPprobes. - Materialize export — Blueprints often use
runPHP/importWxrduring ephemeral Playground boots. Replaying raw PHP on production MySQL/MariaDB hosts is unsafe and non-idempotent. Agents need a declarative handoff (WXR + allowlisted state + changedwp-content/) with zero rawrunPHPreplay.
Proposal
Two thin CLI surfaces (or equivalent Blueprint step + report conventions) in official Playground:
1. Structured verify / JSON report
npx @wp-playground/cli verify \
--blueprint=./blueprint.json \
--checks=./verify.json \
--out=./report.json
# exit 0 iff all checks pass; report.json always written
verify.json would declare expectations only (no agent-supplied executable PHP): site options, published pages/posts by slug/title, CPT counts, terms, theme/plugin presence, REST route presence, Abilities API presence/count, optional live HTTP checks.
report.json should include at least: ok, wordpress_version, php_version, per-check { name, passed, detail }, and php_last_error on failure.
2. Materialize export (WXR + declarative state)
npx @wp-playground/cli materialize \
--blueprint=./blueprint.json \
--out=./dist/
# Writes content.wxr + state.json + changed wp-content/; never emits runPHP source
Invariants:
- Zero raw
runPHPreplay in the export artifact - No secrets (admin accounts, password hashes, salts, SQLite drop-ins)
- No symlink following under
wp-content/ - Fail safe on host-level untranslatable steps unless an explicit
--allow-partial(or equivalent) is set
Non-goal
This is not a proposal to adopt a second official CLI. wpai is a research harness / reference implementation that wraps pinned @wp-playground/cli. After upstream adoption, wpai should call the official commands and shrink.
Reference implementation
- Research repo: https://github.com/patilswapnilv/wp-agent-experience
- Context / related work PR: https://github.com/patilswapnilv/wp-agent-experience/pull/21
- Staged proposal (full detail): https://github.com/patilswapnilv/wp-agent-experience/blob/feat/p0-1-skill-sync-docs-contested/upstream-drafts/playground-verify-and-materialize-proposal.md
- Reference patterns in-repo:
wpai verify/wpai export(Playground + MariaDB parity probes)
Empirical context (honest scope)
Verified in-repo: 63 controlled runs within a single model family; Condition C (verify in the loop) reached 15/15 suitable WordPress selections with live Playground verification and 100% negative-control restraint. Multi-vendor Harbor trials are prepared but not yet run — no cross-vendor claims here.
Ask
- Schema bikeshed on report + state JSON
- Willingness to accept a minimal PR after design agreement
- Preference: new CLI subcommands vs Blueprint step/report conventions
- 主要语言
- JavaScript
- 星标
- 2k
- 派生
- 504
- 平均合并
- 1 天 18 小时
- 30 天内合并 PR
- 146
环境准备
在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
WordPress/wordpress-playground 的其他 Issue
-
PHP_SELF keeps the requested path after an internal redirect, so WordPress serves the home page for unknown permalinks可能已有人在做 @skyphusion-mackaye 于 9 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 70/100
WordPress/wordpress-playground#4689 ·
维护者通常 1 天内回复
-
[Aspect] Internationalization (i18n) [Type] Documentation
难度 2/5 1-3 小时 新手友好度 74/100
WordPress/wordpress-playground#4664 · 20 条评论 · 2 个 reaction ·
维护者通常 1 天内回复
-
[Aspect] Internationalization (i18n) [Type] Documentation
难度 2/5 1-3 小时 新手友好度 65/100
WordPress/wordpress-playground#4662 ·
维护者通常 1 天内回复
-
Spurious "Loaded WordPress version differs from requested version" warning on every default boot可能已有人在做 @amitraj2203 于 117 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
WordPress/wordpress-playground#4246 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
WordPress/wordpress-playground#4165 ·
维护者通常 1 天内回复
查看 WordPress/wordpress-playground 的全部 Issue
相似的 Issue
-
enhancement good first issue help wanted
难度 2/5 1-3 小时 新手友好度 78/100
Ayaan-20-11/Zentro-#79 ·
维护者通常 1 天内回复
-
bug good first issue P3
难度 2/5 1-3 小时 新手友好度 88/100
NakileSolutions/Steno#433 ·
维护者通常 1 天内回复
-
wallet(ui): remove truncated "Name reported by wallet" label and normalize Wallet container heights未关闭bug
难度 2/5 1-3 小时 新手友好度 78/100
elastos/elastos-runtime#656 ·
维护者通常 1 天内回复
-
accessibility bug
难度 2/5 1-3 小时 新手友好度 78/100
quarto-dev/quarto-cli#15440 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 68/100
crxjs/chrome-extension-tools#1261 ·