tui: Deferred work pane is empty on a mixed v6/v7 install — deferred_entries and pending_missed_decisions don't resolve paths with want_tickets

Aperta Adatta ai principianti
#1,057 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
77/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
python
Ambito
cli, testing

Direzione di ricerca

Inizia in src/bmad_loop/tui/data.py, da deferred_entries e pending_missed_decisions, poi leggi _project_paths e bmadconfig.load_paths per seguire come want_tickets seleziona i percorsi. Aggiungi un caso di regressione in tests/test_tui_data.py usando una configurazione mista v6/v7 e un registro delle iniziative; il lavoro è completato quando entrambe le funzioni trovano il registro v7 e la risoluzione dei percorsi esclusivamente v6 continua a funzionare.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Summary

On a BMAD v7 project whose central config still carries the v6 keys [modules.bmm] planning_artifacts / implementation_artifacts (the installer writes them, so a migrated v6 → v7 project typically has them), the TUI's Deferred work pane shows "deferred ledger unavailable" even though the v7 ledger exists and parses. The ticket boards in the same TUI resolve the project as v7 correctly.

Seen on v0.13.2; the same code is on main at 8224d535e09a68c9ed5144e32e0842396acc646d.

Reproduce

  1. A v7 project with the ticket tree (_bmad/method/scripts/tickets.py present) and an active initiative whose folder holds deferred-work.md with DW entries.
  2. Central config still resolves the v6 keys planning_artifacts and implementation_artifacts (for example [modules.bmm] in _bmad/config.toml, or _bmad/bmm/config.yaml).
  3. bmad-loop tui → Deferred work.

Expected: the initiative's deferred-work.md entries, as bmad-loop sweep and tickets runs see them.
Actual: "deferred ledger unavailable". Calling data.deferred_entries(project) returns None; data._project_paths(project) resolves the v6 era with the ledger at <implementation_artifacts>/deferred-work.md, which no longer exists after the migration.

With want_tickets=True the same project resolves v7, the ledger path is <output_folder>/<active_initiative>/deferred-work.md, and parse_ledger returns every entry, so the ledger format is not the problem.

Cause

  • deferred_entries calls _project_paths(project) without want_tickets (tui/data.py#L1467).
  • pending_missed_decisions has the same call (tui/data.py#L1552).
  • bmadconfig.load_paths switches to v7 only when want_tickets is set or no v6 key resolves (bmadconfig.py#L676), so a mixed install answers v6 here.
  • The ticket boards already pass want_tickets=True (tui/data.py#L1324, #L1349), and _project_paths's docstring says that flag "resolves as a tickets run does, so a mixed install answers v7".

Possible fix

Resolve the ledger the way tickets runs and sweeps do on a v7 project: pass want_tickets=True at both call sites when the v7 marker is present (or always, if load_paths already falls back correctly on a pure v6 project). A test in tests/test_tui_data.py with a mixed config (v6 keys + v7 marker + initiative ledger) would pin it.

Workaround

Deleting the v6 keys isn't a good fix: the installer manages them, and v6 skills may still read them. Pointing implementation_artifacts at the active initiative's folder in a user override makes the pane read the right file, but it has to follow every initiative switch.

Lingua principale
Python
Stelle
196
Fork
78
Merge medio
9h 24m
PR unite (30g)
44

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di bmad-code-org/bmad-loop

Tutte le issue di bmad-code-org/bmad-loop

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.