Repository navigation
Zeta 后端:修复 CI 红——deploy 密钥校验测试未兼容可选密钥 WAKER_SIGNING_KEY - #259
Merged
todosdev[bot] merged 1 commit intoNov 29, 2026
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
摘要
.github/scripts/test-deploy-checks.mjs的「fail-closes on every secret it injects」用例未兼容可选密钥WAKER_SIGNING_KEY,导致「Test deploy checks」步断言失败。requiredKeys(4 个)与 env 声明的declaredSecrets(5 个,多出可选的WAKER_SIGNING_KEY)完全相等;而可选密钥按设计不得进入 fail-closed 的for name in循环,两者必然不等。deploy.yml的密钥语义:WAKER_SIGNING_KEY保持可选(未设 → 官方 Cron;真值 → waker 接管;false→ 无调度)。改动
.github/scripts/test-deploy-checks.mjsoptionalKeys提取:从「Write secrets file」步脚本正文解析if [ -n "${NAME:-}" ]条件块,与既有requiredKeys/declaredSecrets的解析方式一致,持续从deploy.yml推导而非重实现。deepEqual断言改为三向对账,并锁定设计意图:if [ -n ... ]条件块、且不得进入 fail-closed 循环(optional ∩ required = ∅);WAKER_SIGNING_KEY必须属于optionalKeys(保持可选,绝不 fail-closed)。测试
node --test .github/scripts/:7 tests / 7 pass,含新用例「fail-closes on required secrets and conditionally writes optional secrets」。903f550):conclusion = success,Test deploy checks/Lint/Format check/Build web/Typecheck worker/Test worker/Test web全部通过。