chore(release): 0.8.1#69
Conversation
…k/kind Render each journal row as a Rich Table.grid with fixed clock/kind columns and a folding fields column, so long field strings wrap within their own column instead of spilling back under the timestamp and kind cells. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Warning Review limit reached
Next review available in: 44 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
WalkthroughThis PR bumps the package version to 0.8.1 across manifest files and adds a corresponding CHANGELOG entry, and separately refactors ChangesVersion Bump and Changelog
Journal Table Rendering
Estimated code review effort: 2 (Simple) | ~12 minutes Sequence Diagram(s)Not applicable — changes are version metadata updates and a self-contained rendering refactor without multi-component interaction flows. Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🤖 Augment PR SummarySummary: Cuts the Changes:
Technical Notes: Introduces shared 🤖 Was this summary useful? React with 👍 or 👎 |
| # indent) instead of wrapping back under the clock/kind columns. | ||
| grid = Table.grid(padding=(0, 1, 0, 0)) | ||
| grid.add_column(width=8) | ||
| grid.add_column(width=24, overflow="fold") |
There was a problem hiding this comment.
src/bmad_loop/tui/widgets.py:185 — Setting overflow="fold" on the fixed-width kind column changes behavior from the previous Text formatting: long kinds will now wrap and can make a single journal entry render as multiple lines. If only the fields column is intended to fold, it may be worth double-checking that wrapping kind won’t hurt journal row readability/selection behavior in Textual.
Severity: low
🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.
There was a problem hiding this comment.
Intentional — keeping fold on the kind column. The ~7 real journal kinds that exceed 24 chars (sweep-returned-after-decisions, decision-skipped-unattended, attempt-worktree-preserved, …) fold within their own column, so the full kind stays visible and the fields still hang-indent in their column rather than spilling. In a Textual OptionList each entry is one selectable unit regardless of visual height, so a two-line kind does not affect selection. Ellipsis/crop was considered but would hide the tail of those kinds; we prefer full visibility over row compactness here.
| # continuation lines stay in the fields column (clock 8 + pad 1 + kind 24 | ||
| # + pad 1 = 34), never spilling back under the clock/kind columns | ||
| for line in lines[1:]: | ||
| assert line.startswith(" " * 34) and line[34] != " " |
There was a problem hiding this comment.
tests/test_tui_app.py:329 — This assertion can be brittle: line[34] can raise IndexError if a wrapped continuation line is shorter than 35 characters, and line[34] != " " may fail if Rich wraps such that a continuation line begins with whitespace even though it’s still correctly indented into the fields column.
Severity: low
🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.
There was a problem hiding this comment.
Good catch — hardened in c6fb96e. The fields-column offset is now derived from shared width constants (_JOURNAL_CLOCK_WIDTH + _JOURNAL_COL_PAD + _JOURNAL_KIND_WIDTH + _JOURNAL_COL_PAD) instead of a hardcoded 34, and the per-line check is now line[:indent] == " " * indent (slice-safe, no IndexError, and tolerant of a fold boundary landing a space at the column edge) plus a single any(line[indent:].strip() …) to assert real fields content is carried.
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/bmad_loop/tui/widgets.py (1)
183-186: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueMagic numbers for column widths.
width=8andwidth=24are hardcoded with only a comment explaining the resulting34in the test file. Consider naming these as module-level constants (e.g._CLOCK_COL_WIDTH,_KIND_COL_WIDTH) so the relationship between this function and the hanging-indent test assertion (34 = 8 + 1 + 24 + 1) is self-documenting and doesn't silently drift if one side changes without the other.♻️ Proposed refactor
+_JOURNAL_CLOCK_WIDTH = 8 +_JOURNAL_KIND_WIDTH = 24 + def journal_line(entry: dict[str, Any]) -> Table: ... grid = Table.grid(padding=(0, 1, 0, 0)) - grid.add_column(width=8) - grid.add_column(width=24, overflow="fold") + grid.add_column(width=_JOURNAL_CLOCK_WIDTH) + grid.add_column(width=_JOURNAL_KIND_WIDTH, overflow="fold") grid.add_column(overflow="fold")🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src/bmad_loop/tui/widgets.py` around lines 183 - 186, The Table.grid setup in the widget builder uses hardcoded column widths that are coupled to the hanging-indent test assertion, so replace the inline widths in the grid.add_column calls with module-level named constants such as _CLOCK_COL_WIDTH and _KIND_COL_WIDTH. Update the relevant widget construction logic in the same area as the grid definition so the relationship between the layout and the 34-column test expectation stays explicit and easy to keep in sync.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@src/bmad_loop/tui/widgets.py`:
- Around line 183-186: The Table.grid setup in the widget builder uses hardcoded
column widths that are coupled to the hanging-indent test assertion, so replace
the inline widths in the grid.add_column calls with module-level named constants
such as _CLOCK_COL_WIDTH and _KIND_COL_WIDTH. Update the relevant widget
construction logic in the same area as the grid definition so the relationship
between the layout and the 34-column test expectation stays explicit and easy to
keep in sync.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 1b8f78be-2017-4c70-9376-1238df07c242
⛔ Files ignored due to path filters (15)
docs/images/dashboard.pngis excluded by!**/*.pngdocs/images/dashboard.svgis excluded by!**/*.svgdocs/images/decision-answer.pngis excluded by!**/*.pngdocs/images/decision-answer.svgis excluded by!**/*.svgdocs/images/deferred-modal.pngis excluded by!**/*.pngdocs/images/deferred-modal.svgis excluded by!**/*.svgdocs/images/demo.gifis excluded by!**/*.gifdocs/images/settings-scm.pngis excluded by!**/*.pngdocs/images/settings-scm.svgis excluded by!**/*.svgdocs/images/settings.svgis excluded by!**/*.svgdocs/images/start-run-modal.pngis excluded by!**/*.pngdocs/images/start-run-modal.svgis excluded by!**/*.svgdocs/images/sweep-decision.pngis excluded by!**/*.pngdocs/images/sweep-decision.svgis excluded by!**/*.svguv.lockis excluded by!**/*.lock
📒 Files selected for processing (8)
.claude-plugin/marketplace.jsonCHANGELOG.mdmodule.yamlpyproject.tomlsrc/bmad_loop/__init__.pysrc/bmad_loop/data/skills/bmad-loop-setup/assets/module.yamlsrc/bmad_loop/tui/widgets.pytests/test_tui_app.py
…dent test Extract _JOURNAL_CLOCK_WIDTH/_JOURNAL_KIND_WIDTH/_JOURNAL_COL_PAD so the grid layout in journal_line and the hanging-indent test derive the fields-column offset from one source instead of hardcoding a coupled 34 in the test comment. Make the continuation-line assertion slice-safe (no IndexError on a short wrap) and tolerant of a fold boundary landing a space at the column edge, while still catching any real left-spill. Rendering is unchanged. Addresses review comments on PR #69. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
@coderabbitai Addressed in c6fb96e. Extracted module-level constants |
|
Tip For best results, initiate chat on the files or code changes. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
cd /repo 2>/dev/null || true
git log --oneline -1 c6fb96e 2>/dev/null
git show c6fb96e -- src/bmad_loop/tui/widgets.py 2>/dev/null | head -100
git show c6fb96e -- tests/test_tui_app.py 2>/dev/null | head -100Length of output: 5165 Verified in commit c6fb96e — the constants |
|
augment review |
Release 0.8.1 — patch. Bugfix-dominant, plus bounded retention for the attempt-preserve recovery ref families.
Version stamped
0.8.0 → 0.8.1across all files; TUI screenshots + demo regenerated (src/bmad_loop/tuichanged since v0.8.0). Once merged tomain,release.ymlauto-creates thev0.8.1tag and GitHub release from the CHANGELOG.Fixed
state.json. (fix(engine): close resume-replay edges from #62 (final-cycle replay, stale result_json, record bloat) #63)Added
attempt-preserve/*andattempt-preserve-dirty/*families pruned to newestscm.preserve_keep(default 20,0= never) at run start. (feat(scm): bounded retention for attempt-preserve recovery refs #50 feat(scm): bounded retention for attempt-preserve-dirty worktree-snapshot refs #54, closes Cap the lifecycle of attempt-preserve/* recovery refs (follow-up to #29) #32 Cap the lifecycle of refs/attempt-preserve-dirty/* worktree-snapshot refs (follow-up to #32) #49)Changed
Full detail in
CHANGELOG.md.🤖 Generated with Claude Code
Summary by CodeRabbit