score_mounts fails to resolve external data present in runfiles when execroot link is absent
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 68/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- python
- 领域
- build-system, tooling
调研方向
Start by reading _resolve_data_mounts in src/extensions/score_mounts/__init__.py and the fixture at src/tests/docs_bzl/scenarios/external_bundle. Build it with bazel run //src/tests/docs_bzl/scenarios/external_bundle:docs, then inspect the fixture's _mounts_manifest.json and runfiles paths. Add regression coverage for an external asset available in runfiles but missing from the reconstructed execroot path; done when the resolver succeeds in that case while generated data paths still resolve appropriately.
由索引模型根据 Issue 内容生成。
描述
A documentation build can fail while mounting an external bundle even though the reported missing source asset exists in the target's runfiles. Resolution currently depends on an additional symlink in the execution root, so the outcome can depend on local Bazel state.
Observed at commit 9bbb726f7757b61d5da02dfc74e2b1900376a5aa on Linux, Bazel 8.8.2, Python 3.12.
Observed failure
bazel run //src/tests/docs_bzl/scenarios/external_bundle:docs
Sphinx fails during config-inited:
ValueError: score_mounts: resolved data file does not exist:
<execroot>/_main/external/score_process_description+/process_extensions/_assets/ai_supported_sldc_review_example.drawio.svg
(mount_at=process/process_extensions)
At the time of failure:
- The SVG existed at
<target>.runfiles/score_process_description+/process_extensions/_assets/ai_supported_sldc_review_example.drawio.svg, and its symlink target existed in Bazel's external repository cache. - The corresponding path below
<execroot>/_main/external/did not exist.
Cause and expected behavior
_resolve_data_mounts derives the execution root by splitting the runfiles directory at /bazel-out/, then appends the manifest's execroot-relative data path. For an external source file, this assumes the external repository also has a usable link in that execution root.
External source assets should resolve through the declared runfiles rather than require this additional link. Generated data paths still need their appropriate resolution.
Reproduction and scope
The original failure occurred naturally, but the reason the execroot link was initially absent has not been established. Subsequent builds and fresh checkouts did not reproduce it automatically.
A controlled reproduction confirmed the dependency: in a disposable checkout after building the fixture, temporarily move the <execroot>/_main/external/score_process_description+ symlink aside, keeping the repository and the target's runfiles intact. Call _resolve_data_mounts with the fixture's built _mounts_manifest.json, workspace root and runfiles directory. It raises the exact SVG lookup error even though the SVG is still accessible through runfiles. Restore the symlink afterward.
This reproduced identically with the unmodified PR #1032 head and with a local PlantUML launcher fix applied. The affected resolver was also identical to the locally available upstream/main. The PlantUML launcher fix is separate: with the execroot link available, the complete fixture build fails on PlantUML before that fix and succeeds afterward.
Regression coverage should verify that an external mounted data file resolves when present in runfiles but absent at the reconstructed execroot path.
- 主要语言
- Python
- 星标
- 11
- 派生
- 39
- 平均合并
- 1 天 13 小时
- 30 天内合并 PR
- 65
环境准备
在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
eclipse-score/docs-as-code 的其他 Issue
-
bug
难度 1/5 1 小时以内 新手友好度 82/100
eclipse-score/docs-as-code#1031 · 4 条评论 ·
维护者通常 1 天内回复
-
waiting_for_author
难度 2/5 1-3 小时 新手友好度 78/100
eclipse-score/docs-as-code#1029 · 1 条评论 ·
维护者通常 1 天内回复
-
intentionally-limited
难度 1/5 1 小时以内 新手友好度 88/100
eclipse-score/docs-as-code#1019 · 2 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 74/100
eclipse-score/docs-as-code#920 · 2 条评论 ·
维护者通常 1 天内回复
-
Add project name to headline ...可能重新可做 关联的 PR 已关闭且未合并。 未关闭documentation
难度 2/5 1-3 小时 新手友好度 68/100
eclipse-score/docs-as-code#613 · 1 条评论 ·
维护者通常 1 天内回复
查看 eclipse-score/docs-as-code 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复
-
AIR-Bench Foundation reads the first letter of the word after "answer" as the model's choice可能已有人在做 @beartester34 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 84/100
modelscope/evalscope#2330 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 74/100
-
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
Distribution plot crashes when a numeric feature is constant in the train or test set可能已有人在做 @adembilge 今天认领。 未关闭bug good first issue
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 10 天内回复