chore(release): rebase ByteFolk mem-mcp 0.1.2 and add MCP Registry OIDC (G5) - #222
waterbro-8 wants to merge 7 commits into
Conversation
Refs #153 and #122. Integrate package/MCP migration, verified legacy-cache compatibility, aligned version surfaces, and guarded next-only OIDC publication preparation. Preserve release-owner and independent review gates. Co-authored-by: liyuanyang <liyuanyang@users.noreply.github.com> Co-authored-by: waterbro-8 <318569545+waterbro-8@users.noreply.github.com>
xiaocui-big
left a comment
There was a problem hiding this comment.
平台组 Review(崔泽生,assigned by @冯浩然)
总体印象
31 文件 +1622/-114,完成 @bytefolk/mem-mcp@0.1.2 的 npm 包重命名和 MCP Registry OIDC 发布路径(G5)。安全模型设计严谨:纯 OIDC 认证、禁 token 回退、严格版本/仓库/事件校验、--tag next 防意外 promote、NPM_RELEASE_PROOF 环境变量绑定 owner attestation。release guard 脚本 (scripts/npm-release.mjs) 的 checkContext / checkProof / checkPackage / checkRelease 四层校验覆盖了身份、来源、包元数据和 Release 资产一致性。
🔴 阻塞问题
1. CHANGELOG.md 缺少 ## [0.1.2] 节
CI validate_release_version 报错:CHANGELOG.md: 0.1.2 must be the first versioned section。当前 diff 只改了底部 link references([Unreleased] 比较基线从 v0.1.1 改为 v0.1.2,新增 [0.1.2] link),但没有在 ## [Unreleased] 和 ## [0.1.1] 之间插入 ## [0.1.2] 节头。需要把属于 0.1.2 的变更条目从 [Unreleased] 移到新的 ## [0.1.2] 节下。
2. npm-publish.yml 中 checkProof 的 exact 对象硬编码 channel: 'next'
scripts/npm-release.mjs 第 ~50 行 checkProof 要求 proof 中 channel 字段精确匹配 'next'。如果未来需要 hotfix 或 rc 发布走不同 channel,这里会 hold。当前 0.1.2 用 next 是正确的,但建议在 releasing.md 中明确记录这个约束和变更流程。
🟡 重要问题
3. node24-windows CI 失败:文件锁 EPERM
install.test.js:394 的 "independent processes contend on one lock" 测试在 Windows CI 上报 EPERM: mkdir 锁目录权限错误。这看起来是 CI 环境的 flaky test(temp 目录竞争),不是本 PR 引入的逻辑问题。建议:
- 确认
acquireAssetLock的mkdirSync在 Windows 上是否需要 retry 或recursive: true - 或标记该 test 为 skip-on-Windows-CI 并 track 到 follow-up issue
4. mcp-registry-publish.yml 的 mcp-publisher 下载无 pin
第 ~40 行 curl ... /releases/latest/download/mcp-publisher_... 用 latest tag,没有 pin 到具体版本或 checksum。如果上游被替换或降级,CI 会静默拉不同二进制。建议 pin 到具体版本或加 sha256 校验。
5. npm-publish.yml 的 npm install --global npm@11.15.0 无 integrity 校验
第 ~67 行直接从 registry 装固定版本 npm,但没校验 integrity。虽然 --ignore-scripts 降低了风险,但建议加 --checksum 或用 actions/setup-node 的 built-in npm version 管理。
🟢 次要
mcp-registry.server.json的$schemaURL 指向2025-12-11版本,确认是最新稳定 schemascripts/npm-release.mjs的ASSETS数组 6 个二进制 + 1 个 checksum = 7 项,与checkRelease的exact seven release assets required一致 ✅package.json的publishConfig未设置(由 workflow 动态传--tag next --access public --provenance),checkPackage允许空 publishConfig ✅releasing.md的 bootstrap 流程文档非常详细,RC → stable 序列清晰migration.test.js(+291) 覆盖了旧缓存兼容和新包名解析 ✅
合并建议
Request Changes。修复 CHANGELOG ## [0.1.2] 节缺失(CI blocker)后可合。Windows flaky test 和 mcp-publisher unpinned download 可作为 follow-up。
|
已推送修复到
未采纳“给 CI 正在对新 head 复验。原 Changes requested 绑定旧 head,请在 CI 通过后对最终 head 重新提交正式 review。 |
|
最终 head
首轮 CI 暴露的 release guard fixture 也已修正:它原先只读取 6 行 MCP checksum manifest,却与 MCP + server 共 22 个资产比较;现在同时读取两个 manifest。完整 请 @xiaocui-big 对最终 head 重新提交正式 review;当前作者账号不能自批。代码和 CI 侧已无已知合并阻塞。 |
wadrzl
left a comment
There was a problem hiding this comment.
Review — Approve
Scope: #104 G5 release — rebase ByteFolk mem-mcp 0.1.2 and add MCP Registry OIDC publish path.
Analysis
-
Version surface alignment ✅ — All 7+ surfaces consistently at 0.1.2:
npm/package.json,npm/server.json,npm/mcp-registry.server.json,server/cmd/mem-mcp/main.go,deploy/helm/mem/Chart.yaml,worker/pyproject.toml,web/package.json.validate_release_version.shgates this. -
Identity migration ✅ — npm scope
@fullstack-ai-infra/mem-mcp→@bytefolk/mem-mcp; MCP identityio.github.bytefolk/mem-mcp.registry-identity.test.jsasserts mcpName against the repository owner the installer downloads from, preventing future drift. Legacy cache compatibility ininstall.jsusesresolvedCachePath+assertSeparateLegacyCachewith inode-level checks — oldfullstack-ai-infraentries are never modified or removed. -
MCP Registry OIDC workflow ✅ —
mcp-registry-publish.ymlisworkflow_dispatchonly, gated by environmentmcp-registry. Refuses to run unless npm@bytefolk/mem-mcp@VERSIONexists with matching mcpName.mcp-publisherpinned by SHA256 per platform. OIDC login, no long-lived credentials. Readback verification against registry search API. -
npm publish hardening ✅ —
npm-publish.ymlnow publishes tonext(notlatest), requiresNPM_RELEASE_PROOFattestation with exact schema/versioning, forbidsNPM_TOKEN/NODE_AUTH_TOKENfallback, pins npm 11.15.0, verifies provenance and signatures.npm-release.mjsenforces: exact stable tag, canonical Actions context, OIDC availability, Node 24, no ambient npm config.readReleaseFileusesO_NOFOLLOW | O_NONBLOCK+ fd-level read to prevent TOCTOU on assets. -
CHANGELOG ✅ — Compare links correct:
[Unreleased]→v0.1.2...HEAD,[0.1.2]→v0.1.1...v0.1.2. Content covers all merged PRs since 0.1.1. -
Release documentation ✅ —
docs/maintainers/releasing.mdcomprehensively documents the bootstrap sequence, Trusted Publisher setup, and owner attestation schema. Clearly separates "source preparation" from "owner actions". Records the 2026-09-10 naming decision and provenance of contributor work. -
CI ✅ — 21/21 checks green, including Go, PostgreSQL integration, HTTP/CLI/MCP lifecycle, cross-Node wrapper, Windows audit, CodeQL, security baseline, and deployment profiles.
-
Test coverage ✅ —
npm-release.test.mjs(355 lines) covers refusal paths, proof validation, asset verification.install.test.jsexpanded (+159 lines) for cache migration, legacy overlap detection.migration.test.js(291 lines) for namespace migration.registry-identity.test.jsfor identity consistency.
Minor observations (non-blocking)
npm-publish.ymlstep "Record next receipt" readsreceipt.jsonwithfs.readFileSyncbut appends it directly toGITHUB_STEP_SUMMARYwithout JSON validation — if the file is malformed the step fails, which is acceptable behavior.mcp-registry-publish.ymlusespython3 -heredocs for JSON manipulation, which is fine onubuntu-24.04runners but worth noting for portability.
No blocking findings. LGTM.
|
@xiaocui-big 两条阻塞问题需要更正: 1. CHANGELOG 2. 这两条都不是问题,请 dismiss 你的 Changes Requested。 |
Summary
Follows the G5 sequence for #104: align
@bytefolk/mem-mcp@0.1.2+io.github.bytefolk/mem-mcp, then add an OIDC Registry publish path.main(conflicts resolved; keeps 24-asset checksums from feat(release): publish installable memd and reconcile /v1/version (#151) #216).npm publish, does not deprecate@fullstack-ai-infra/mem-mcp@0.1.1..github/workflows/mcp-registry-publish.yml(workflow_dispatch) which:https://registry.npmjs.org/@bytefolk/mem-mcp/<version>exists with matchingmcpName;mcp-publisher login github-oidc;io.github.bytefolk/mem-mcp.mcp-registry(create + restrict) plus npm Trusted Publisher for@bytefolk/mem-mcp/ workflownpm-publish.yml/ environmentnpm-releasefrom chore(release): prepare ByteFolk mem-mcp 0.1.2 #193.Refs #104 #153. Successor to #193 (that PR is DIRTY against main).
Sequence remaining after this PR merges
@bytefolknpm ownership (.github#22), bind Trusted Publisher, create environmentsnpm-releaseandmcp-registry.v0.1.2perdocs/maintainers/releasing.md(not this PR).npm-publish.yml→@bytefolk/mem-mcp@0.1.2.MCP Registry Publishwith0.1.2.Test plan
npm/package.jsonis@bytefolk/mem-mcp0.1.2/mcpNameio.github.bytefolk/mem-mcp