Scaffolded setup skill deletes live v6 config (cleanup-legacy + merge cleanup); still present in v2.0.0

オープン
#96 コメント 3 件 リアクション 1 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
72/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
python
領域
tooling

調査の方向性

bmad-module-builder/assets/setup-skill-template/cleanup-legacy.py から始め、その削除処理を merge-config.py の cleanup_legacy_configs および merge-help-csv.py の cleanup_legacy_csvs と比較します。報告されている v6 のインストールおよびクリーンアップコマンドを実行します。設定、ヘルプ、マニフェストのライブファイルがそのまま残り、実際に冗長な legacy ペイロードを引き続き削除できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Summary

The bmad-module-builder scaffolder emits a setup skill whose cleanup steps delete config that is live on BMAD v6. Confirmed still present in v2.0.0 — the v2 rebuild did not touch bmad-module-builder/assets/setup-skill-template (last change 2026-06-02).

Details

cleanup-legacy.py builds dirs_to_remove = [module_code, "core"] + also_remove and shutil.rmtrees each. On v6 these are live:

  • _bmad/core/config.yaml — live core config (user_name, project_name, language settings) read by core/bmm skills
  • _bmad/<module>/config.yaml, _bmad/<module>/module-help.csv — live module config/help
  • _bmad/_config/ — installer manifests + bmad-help.csv

The --skills-dir safety check only guards directories that contain a SKILL.md. On v6 these config directories have none, so find_skill_dirs returns empty, verification is skipped, and removal proceeds — while the JSON reports skills_verified: true.

merge-config.py (cleanup_legacy_configs) and merge-help-csv.py (cleanup_legacy_csvs) have the same file-level deletions for core/config.yaml, <module>/config.yaml, and the per-module module-help.csv.

Reproduction

npx bmad-method@latest install --modules bmm --tools claude-code --yes
# then run the scaffolded setup skill's cleanup invocation:
python3 cleanup-legacy.py --bmad-dir _bmad --module-code <m> --also-remove _config --skills-dir .claude/skills

Result: core/config.yaml, <module>/ config + help, and _config/ manifests are deleted; project_name is lost (it isn't migrated up by merge-config.py); /bmad-help's catalog (_config/bmad-help.csv) is gone.

Why it's wrong on v6

The consolidate-and-delete model assumes the installer staged redundant skill payloads + per-module config into _bmad/<module>/ and core/. Fresh-install probes of 6.0.1, 6.6.0, and 6.8.0 all show the opposite: per-module config.yaml is live, skills live at .claude/skills/, and nothing is staged redundantly under _bmad/. The model matches a pre-v6 (v4/v5) layout, not any v6 release.

Impact

Affects every module scaffolded by bmad-module-builder that coexists with bmm-core v6, including bmad-bmb-setup itself.

Suggested fix

Gate removal on "verified-redundant skill payload": remove a directory only if it contains ≥1 SKILL.md whose skills are verified installed at the skills dir, and never remove a directory containing config files. This no-ops safely on v6 while still cleaning genuine pre-v6 payload dirs — no version check needed. Apply the same guard to the cleanup_legacy_* file deletions in merge-config.py / merge-help-csv.py.

主要言語
Python
スター
220
フォーク
54
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

bmad-code-org/bmad-builder のほかの issue

bmad-code-org/bmad-builder の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。