sf project generate manifest --from-org silently drops metadata types unless SF_LIST_METADATA_BATCH_SIZE is set
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 68/100
调研方向
Start with the sf project generate manifest --from-org command and trace the listMetadata calls and handling of SF_LIST_METADATA_BATCH_SIZE. Reproduce the inconsistent type counts with the command shown in the issue, then inspect the debug output to determine why failures are not surfaced. Done means repeated runs produce the same complete manifest, or incomplete results produce warnings and a non-zero exit status.
由索引模型根据 Issue 内容生成。
描述
Summary
sf project generate manifest --from-org still drops whole metadata types at random and reports success, unless SF_LIST_METADATA_BATCH_SIZE is set. That variable came out of #3152, but it is opt-in, so tools that build backups on this command (for example sfdx-hardis org monitor backup) silently miss types by default.
Steps to reproduce
Run the same command five times in a row against one sandbox, without and then with batching:
sf project generate manifest --from-org <alias> --include-packages managed,unlocked --name runN --json
SF_LIST_METADATA_BATCH_SIZE=20 sf project generate manifest --from-org <alias> --include-packages managed,unlocked --name batchN --json
Expected result
The same complete list on every run, or a non-zero status or a warning when a listMetadata call fails.
Actual result
Without batching, the five runs returned 66, 81, 101, 100 and 73 types. Core types were missing in some runs: CustomObject, Flow, LightningComponentBundle, Layout, PermissionSet, Profile. Every run had "status": 0 and "warnings": [], and the debug log shows no error for the dropped types.
With SF_LIST_METADATA_BATCH_SIZE=20, all five runs were identical: 110 types and 13,513 members, about 150 seconds each.
Another org showed the same pattern (47 to 63 types across three runs).
System information
@salesforce/cli/2.155.7, darwin-arm64, Node 24.17.0; also on ubuntu-latest in GitHub Actions- API version 67.0 / 68.0
Suggestions
- Batch the
listMetadatacalls by default (for example 20), or - at least report the failed types as warnings, or return a non-zero status, so callers can detect an incomplete manifest.
Related: #3152.
- 主要语言
- 没有语言数据
- 星标
- 571
- 派生
- 80
- 平均合并
- 14 小时 43 分钟
- 30 天内合并 PR
- 5
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
forcedotcom/cli 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 74/100
forcedotcom/cli#3672 ·
-
investigating validated
难度 2/5 1-3 小时 新手友好度 72/100
forcedotcom/cli#3671 · 1 条评论 ·
-
sf agent mcp asset replace --assets null throws raw TypeError instead of InvalidShape可能已有人在做 @konkonrong-lgtm 于 75 天前认领。 未关闭area:afdx bug investigating owned by another team validated
难度 2/5 1-3 小时 新手友好度 78/100
forcedotcom/cli#3625 · 4 条评论 ·
-
area:afdx bug owned by another team
难度 2/5 1-3 小时 新手友好度 78/100
forcedotcom/cli#3608 · 2 条评论 ·
-
announcement
难度 1/5 1 小时以内 新手友好度 1/100
forcedotcom/cli#3668 ·
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 83/100
维护者通常 1 天内回复
-
schema-map --csv falsely reports objectid/globalid as 'not in the file' (name-based, not type-based)未关闭
难度 2/5 1-3 小时 新手友好度 72/100
OCHA-DAP/topo-tools-py#222 ·
-
fm-spawn: bash 5.2 patsub_replacement turns '&' in a home or project path into the placeholder text未关闭
难度 2/5 1-3 小时 新手友好度 77/100
kunchenguid/firstmate#7786 ·
维护者通常 1 天内回复
-
untriaged
难度 2/5 1-3 小时 新手友好度 68/100
dotnet/install-scripts#746 · 1 个 reaction ·
-
area:plugins area:tui enhancement
难度 2/5 1-3 小时 新手友好度 69/100
anthropics/claude-code#105139 ·
维护者通常 1 天内回复