fix(push@d52f8b5): @sfmc-bds/tools 发包失败 + npm-publish 空 jobs / SOLID - #26
Merged
Tanya7z merged 4 commits intoJul 22, 2026
Merged
Conversation
workflow_dispatch.inputs.tag 改为非 required,publish job 增加 ref_type==tag 门控,避免改 workflow 的 branch push 被 GHA 误评估后 出现空 jobs + "workflow file issue"(如 run 29922880511)。 Co-authored-by: Shiroha <Tanya7z@users.noreply.github.com>
- installHostBootstrap 默认注入 createHttpDataAdapter,可经
dataAdapter / dbServerUrl 替换;HttpDB.configure 覆盖基址
- db-routes 错误路径统一 jsonV2Fail({ok:false}),支持 step extra
Co-authored-by: Shiroha <Tanya7z@users.noreply.github.com>
push@d52f8b5 打了 @sfmc-bds/tools@v0.1.0,但 NPM_PUBLISH_PACKAGES 未收录、 tools 未进 workspaces,导致 run 29926464473 在 parse tag 失败。 - 清单 + root workspaces + pack:verify 对齐(DRY) - main 改为 check-ootb.mjs;补 bin / files;noop build - npm-publish build 加 --if-present(OCP) - paths.ROOT 尊重 SFMC_ROOT(DIP) Co-authored-by: Shiroha <Tanya7z@users.noreply.github.com>
cursor Bot
pushed a commit
that referenced
this pull request
Jul 22, 2026
ROOT 优先读 SFMC_ROOT;FETCH_MODULE 固定为本包路径,避免 npm 安装后 仍拼 ROOT/tools(#26 同类改法的漏洞)。补充 bin 与 README。 Co-authored-by: Shiroha <Tanya7z@users.noreply.github.com>
cursor Bot
pushed a commit
that referenced
this pull request
Jul 22, 2026
ROOT 优先读 SFMC_ROOT;FETCH_MODULE 固定为本包路径,避免 npm 安装后 仍拼 ROOT/tools(#26 同类改法的漏洞)。补充 bin 与 README。 Co-authored-by: Shiroha <Tanya7z@users.noreply.github.com>
Tanya7z
marked this pull request as ready for review
July 22, 2026 14:08
Contributor
Author
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
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.
背景
审查 main@d52f8b5(
publish dev tools)+ tag@sfmc-bds/tools@v0.1.0。Unknown npm package tag: @sfmc-bds/tools本 PR 取代 #24 / #25(同批 CI 空 jobs + DataAdapter / db-routes,已 cherry-pick 到最新 main),并修本次 tools 发包缺口。
审查结论(DRY / OCP / DIP / LSP / Demeter)
@sfmc-bds/tools不在NPM_PUBLISH_PACKAGES,tag 发布直接挂main: check-ootb.js指向已废弃扩展名check-ootb.mjs+ bin/filesinputs.tag required:true→ 空 jobs(#25 未合)required:false+ref_type==tagnpm run build,纯脚本包无 build--if-present+ noop buildinstallHostBootstrapstub DataAdaptercreateHttpDataAdapter可注入db-routes错误路径混用{success:false}jsonV2Fail({ok:false})paths.ROOT写死相对路径,npm 安装后失效SFMC_ROOTdb.txrecorder 不回放 serverresultssuccess方言验证
db-servernode --test:7/7SFMC_ROOT=$PWD node tools/check-ootb.mjs:10/10PUBLISH_TAG=@sfmc-bds/tools@v0.1.0 node tools/resolve-npm-publish-tag.mjs:Version OKnpm pack -w @sfmc-bds/tools --dry-run:打包 21 文件合并后建议
workflow_dispatch发布@sfmc-bds/tools@v0.1.0(原 tag 推送已失败,workflow 已按该 tag 跑过)