test: verify installed View execution and document migration work
ci/woodpecker/push/eco Pipeline was canceled
ci/woodpecker/pr/eco Pipeline was canceled

This commit is contained in:
cflmy committed 2026-11-26 13:25:35 +08:00
1 parent 4c5c102593
commit 024d803494
5 files changed
+36 -8

No files matched your search

+1 -1
View File
@@ -23,7 +23,7 @@ git diff --cached --submodule=log
| C2 公共契约 | 真实 CLI 和 Worker、独立 Conformance 与消费者,覆盖当前协议、失败和正确身份 | | C2 公共契约 | 真实 CLI 和 Worker、独立 Conformance 与消费者,覆盖当前协议、失败和正确身份 |
| C3 生态集成 | 结构、公开冷克隆、精确 gitlink、官方基础发行、CLI Tool 和契约消费回归 | | C3 生态集成 | 结构、公开冷克隆、精确 gitlink、官方基础发行、CLI Tool 和契约消费回归 |
本候选先对全部 active 组件运行集成。Woodpecker 的 `layout` 校验 Git tree,随后初始化公开直连子模块。`candidate` 用官方冻结归档验证冷安装、Conformance、View、Knowledge、Prove 和 Lint。C1 的完整构建、View 的全浏览器矩阵、Prove 的 Lean 后端以及 CLI 的 strict VM 和性能门禁沿用各组件独立流程。 本候选先对全部 active 组件运行集成。Woodpecker 的 `layout` 校验 Git tree,随后初始化公开直连子模块。`candidate` 用官方冻结归档验证冷安装、Conformance、View、Knowledge、Prove 和 Lint。View 的集成测试包含安装、静态核验、显式执行、Observation 和移除。C1 的完整构建、View 的全浏览器矩阵、Prove 的 Lean 后端以及 CLI 的 strict VM 和性能门禁沿用各组件独立流程。
本地运行需要 Linux x86_64/glibc ≥ 2.39、Python 3.11+、jsonschema、Git、Rust、C 编译器和 curl。 本地运行需要 Linux x86_64/glibc ≥ 2.39、Python 3.11+、jsonschema、Git、Rust、C 编译器和 curl。
+2 -2
View File
@@ -31,8 +31,8 @@ Conformance 使用 CLI 已固定的真实 fixture 提交。
| --- | --- | --- | | --- | --- | --- |
| M0 盘点 | 自建 Git、历史标签、已有六组件和新仓位 | 通过真实远端候选持续维护台账 | | M0 盘点 | 自建 Git、历史标签、已有六组件和新仓位 | 通过真实远端候选持续维护台账 |
| M1 集成骨架 | 六个 gitlink、布局门禁和 RC.4 组合 | 查看候选 Woodpecker 运行及各组件独立 CI | | M1 集成骨架 | 六个 gitlink、布局门禁和 RC.4 组合 | 查看候选 Woodpecker 运行及各组件独立 CI |
| M2 标准库切换 | planned,CLI RC.4 提供官方完整 Bundle | CLI 接受显式外部 Bundle;九个标准库真实模块;HTTP、Regex、Archive 迁出与同步删除旧路径 | | M2 标准库切换 | planned,CLI RC.4 提供官方完整 Bundle | [CLI 外部 Bundle](https://git.cflmy.cn/cflmy/marqdo-cli/issues/11) 和 [九组件切换](https://git.cflmy.cn/cflmy/marqdo/issues/2),包括 HTTP、Regex、Archive 迁出与同步删除旧路径 |
| M3 跨仓闭环 | 工单、人工候选、同 SHA 门禁 | 以一个真实跨仓缺陷完成独立修复与消费者验收,建立通知鉴权和去重后再启用自动发起候选 | | M3 跨仓闭环 | 工单、人工候选、同 SHA 门禁 | [跨仓库 CI](https://git.cflmy.cn/cflmy/marqdo/issues/3) 跟踪真实缺陷闭环、候选通知鉴权、去重和影响分析 |
| 后续领域 | 空仓和预期职责 | 逐组件开展最小真实功能、独立 CI、制品与接入 | | 后续领域 | 空仓和预期职责 | 逐组件开展最小真实功能、独立 CI、制品与接入 |
### 标准库切换顺序 ### 标准库切换顺序
+6 -5
View File
@@ -104,12 +104,13 @@ def validate(revision, checkouts):
for path, item in active.items(): for path, item in active.items():
prefix = f"submodule.{path}." prefix = f"submodule.{path}."
require(config.pop(prefix + "path", None) == path, f"missing or invalid submodule path: {path}") require(config.pop(prefix + "path", None) == path, f"missing or invalid submodule path: {path}")
url = config.pop(prefix + "url", "") name = item["id"]
require(re.fullmatch(rf"https://git\.cflmy\.cn/cflmy/marqdo-{NAME}\.git", url), f"invalid submodule URL: {path}")
if item["kind"] == "stdlib":
require(url.endswith(f"/marqdo-{item['id']}.git"), f"invalid standard library repo name: {path}")
if item["kind"] == "extension": if item["kind"] == "extension":
require(url.endswith(f"/marqdo-ext-{item['id']}.git"), f"invalid extension repo name: {path}") name = f"ext-{name}"
elif item["kind"] == "test":
name = "extension-conformance"
url = config.pop(prefix + "url", "")
require(url == f"https://git.cflmy.cn/cflmy/marqdo-{name}.git", f"invalid submodule URL: {path}")
if checkouts: if checkouts:
checkout = ROOT / path checkout = ROOT / path
sha = gitlinks[path] sha = gitlinks[path]
+22
View File
@@ -59,6 +59,28 @@ python3 cli/tools/ci/verify_extension_contracts.py \
"$MARQDO_BIN" tool install dist/marqdo-view/tool.json "$MARQDO_BIN" tool install dist/marqdo-view/tool.json
"$MARQDO_BIN" view verify examples/mixed-modes/index.mq.md "$MARQDO_BIN" view verify examples/mixed-modes/index.mq.md
"$MARQDO_BIN" view export examples/tables-math --out "$work/view-export" "$MARQDO_BIN" view export examples/tables-math --out "$work/view-export"
setsid "$MARQDO_BIN" view examples/control-flow --port 0 --no-open >"$work/view-server.log" 2>&1 &
view_pid=$!
stop_view() {
kill -- "-$view_pid" 2>/dev/null || true
wait "$view_pid" 2>/dev/null || true
}
trap stop_view EXIT
view_url=""
for attempt in {1..100}; do
view_url="$(grep -m1 -o 'http://127\.0\.0\.1:[0-9]\+/' "$work/view-server.log" || true)"
if [[ -n "$view_url" ]] || ! kill -0 "$view_pid" 2>/dev/null; then
break
fi
sleep 0.1
done
if [[ -z "$view_url" ]]; then
cat "$work/view-server.log" >&2
exit 1
fi
python3 scripts/acceptance-run.py "$view_url"
stop_view
trap - EXIT
python3 scripts/check-observation.py stream-snapshot python3 scripts/check-observation.py stream-snapshot
"$MARQDO_BIN" tool remove view "$MARQDO_BIN" tool remove view
if "$MARQDO_BIN" view --version; then if "$MARQDO_BIN" view --version; then
+5
View File
@@ -80,6 +80,11 @@ class LayoutTests(unittest.TestCase):
with self.assertRaisesRegex(ValueError, "invalid submodule URL"): with self.assertRaisesRegex(ValueError, "invalid submodule URL"):
layout.validate("HEAD", False) layout.validate("HEAD", False)
def test_rejects_wrong_repository_at_authority(self):
self.candidate(url="https://git.cflmy.cn/cflmy/marqdo-view.git")
with self.assertRaisesRegex(ValueError, "invalid submodule URL"):
layout.validate("HEAD", False)
def test_rejects_unstaged_checkout(self): def test_rejects_unstaged_checkout(self):
self.candidate() self.candidate()
with self.assertRaisesRegex(ValueError, "missing submodule checkout"): with self.assertRaisesRegex(ValueError, "missing submodule checkout"):