fix(release): 修復 js-yaml 4 override 破壞 changesets release#503
Merged
Conversation
- js-yaml@4.2.0 override 移除 safeLoad,導致 changesets 的 read-yaml-file@1.1.0 在 changeset version 崩潰 - 新增 override read-yaml-file@<2 → ^2.1.0(js-yaml 4 相容),保留 js-yaml 安全版本 - 修復 Release workflow 無法建立 release PR、版本無法 bump 的阻塞 測試:pnpm changeset status 正常輸出 @app/ratewise patch(原 safeLoad 錯誤已消除) Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Contributor
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.OpenSSF Scorecard
Scanned Files
|
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.
問題
合併 #502 後 Release workflow 失敗,版本無法 bump、release PR 無法建立:
根因
安全修復 PR #501 的 override
js-yaml@<=4.1.1 → 4.2.0將 js-yaml 強制升到 4.x(移除safeLoad)。但 changesets 的傳遞相依
@changesets/cli → @manypkg/get-packages@1.1.3 → read-yaml-file@1.1.0仍呼叫已移除的yaml.safeLoad→changeset version崩潰,阻塞所有發版。修法(KISS,保留 js-yaml 安全版本)
新增 pnpm override,將過舊的
read-yaml-file升到 js-yaml 4 相容的 v2:read-yaml-file@2.1.0改用yaml.load,API 對@manypkg/get-packages相容;js-yaml 維持 4.2.0 不動。驗證
pnpm changeset status正常輸出@app/ratewisepatch(原 safeLoad 錯誤消除)pnpm changeset:version端到端成功(bump 2.25.9→2.25.10、CHANGELOG、release metadata、markdown mirrors、live rates restore 全數完成,exit 0;本地已還原不入此 PR)read-yaml-file解析版本由 1.1.0 → 2.1.0🤖 Generated with Claude Code