validate-module.py: line-based YAML parser gives false fails and false passes; any '*-setup' folder hijacks detection
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 76/100
Hướng nghiên cứu
Start with skills/bmad-module-builder/scripts/validate-module.py and trace parse_yaml_minimal() and find_setup_skill(); inspect the validator's tests if present. Reproduce the listed YAML, BOM, and setup-folder cases against a copy of skills/. Done means those cases match the expected behavior, including deterministic handling when multiple setup-skill candidates match.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Describe the bug
skills/bmad-module-builder/scripts/validate-module.py:
parse_yaml_minimal()flattens everykey: valueat any indent, and drops values starting with>. Each change below was applied separately to a copy of bmb's ownskills/, which passes with an eval-runner row added:
| Change | Validator | Should be |
|---|---|---|
description: > + indented text (valid YAML) |
fail: missing or empty required field: description |
pass |
top-level code: removed, a variable block has nested code: nested-value |
pass, module_code: nested-value |
fail |
module-help.csv saved with a UTF-8 BOM (Excel default) |
fail: CSV header mismatch: missing: module; extra: \ufeffmodule |
pass |
find_setup_skill()returns the first*-setupdirectory in rawiterdir()order. It doesn't require aSKILL.md. Adding an emptyaaa-old-setup/next tobmad-bmb-setup/made the validator report 3 critical "Missing required file" findings against the wrong folder.
Steps to reproduce
cp -r skills /tmp/vm && cd /tmp/vm
mkdir aaa-old-setup
python3 <bmb>/skills/bmad-module-builder/scripts/validate-module.py .
# setup_skill: aaa-old-setup -> 3 critical findings
Expected behavior
- Load
module.yamlwith a real YAML parser (yaml.safe_load), checking top-level keys only. - Read the CSV as
utf-8-sig. - Treat only directories with
SKILL.mdandassets/module.yamlas setup-skill candidates. Error clearly when more than one matches, and sort candidates for deterministic output.
Environment
- Model(s) used: n/a (deterministic script)
- Agentic IDE used: n/a (scripts run directly)
- BMad version: bmad-builder
main@d4a921c(v2.2.2 + #118) - Project language: Python 3.13, Linux
- Ngôn ngữ chính
- Python
- Star
- 220
- Fork
- 54
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của bmad-code-org/bmad-builder
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
bmad-code-org/bmad-builder#157 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
bmad-code-org/bmad-builder#153 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
bmad-code-org/bmad-builder#151 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 77/100
bmad-code-org/bmad-builder#127 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
bmad-code-org/bmad-builder#123 ·
Tất cả issue của bmad-code-org/bmad-builder
Issue tương tự
-
Claiming namespace `kliklamala`Đang mởnamespace
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 68/100
EclipseFdn/open-vsx.org#15604 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
app: scripts severity: low status: backlog type: bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
netbox-community/netbox-scripts#164 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 85/100
Maintainer thường phản hồi trong vòng 5 ngày
-
Public function to read participants.tsvCó thể đã có người làm @bruAristimunha đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 85/100
huggingface/tau#799 ·
Maintainer thường phản hồi trong vòng 2 ngày