Repository navigation
chore: format session.py (black baseline drift after #14483) - #14780
Conversation
GPT 5.6 Review — ✅ no blocking findingsGPT 5.6 completed its review of This comment is updated in place on each push. Review detailsNo findings. False positive or not applicable? A repository writer can comment: |
Design Review (Fable 5) — ✅ PASSDesign-level review of Design-Verdict: PASS Nothing to check. [DESIGN-REVIEWED] 1fd0929 |
Opus 5 Review — ✅ no blocking findingsReviewed Verdict parsed from the review's SHA-scoped output markers for commit False positive or not applicable? A repository writer can comment: |
First Principles Review (Fable 5) — ✅ PASSPremise-level review of First-Principles-Verdict: PASS Nothing to check. What this change shipsInventory (1 item) — 1 justifiedIntent: make
The diff is exactly the gate's own prescribed remedy ( [FIRST-PRINCIPLES-REVIEWED] 1fd0929 |
The black ratchet gate (scripts/check_black_formatting.py) fails on main since b5dcaaa (#14642): two constructs added to src/kiro_crew/apps/builtins/meetings/backend/domain/session.py were not black-formatted, and the file is not in .github/black-baseline.txt, so the whole-tree audit lane and every PR merging main inherit the red. Apply the gate's own remedy (black --target-version py310 <file>) to that single file. No behaviour change; no baseline edit. Closes #14768
2e6af7a to
1fd0929
Compare
bolichen97
left a comment
There was a problem hiding this comment.
Reviewed on behalf of the maintainers (sweep 2026-09-28): readiness passed, required checks green on 1fd0929, no blocking review threads, security posture unchanged. Approving and merging.
Problem / Motivation
Goal: Black-format
session.pyso the unbaselined file is black-clean on main again and theratchet-gatesblack step stops flagging it.The Main Ratchet Audit (run 36453125850) fails on main at
b5dcaaa6cin step "Check formatting (black, baselined)":Every other gate in the lane passed (subprocess-encoding, ACP fixtures, agent-sdk boundary, sync-io, cwd-reads, lockdown, census & config-baseline). The single drift is one file that is not in
.github/black-baseline.txtand therefore must be black-clean.Why it matters
A PR runs the ratchet gates against
merge(branch, main), so this red lands on every open PR that touches nothing inmeetings/(#14281 and #14574 already inherit it). Left alone, each of those PRs would be pushed toward the wrong cure: raising a ceiling or baselining the file in someone else's change.Not a goal
.github/black-baseline.txt(the file is not baselined and should stay that way).What changed (motivation → approach → change)
scripts/check_black_formatting.pyreports one new offender on main.6ec57f60f, merged 15:20Z) black-formattedsession.pyand graduated it out of.github/black-baseline.txt. fix(meetings): keep topic titles and owner attachments usable in agent context #14642 (b5dcaaa6c, merged 16:43Z) was based on the older main where the file was still baselined, so its PR lane passed (black gate scope: merge HEAD^1..HEAD (4 changed file(s)), 950 baselined) even though its two new constructs -- the two-line implicit concatenation inside_SYSTEM_PROMPT_TOPIC_REand the single-lineparts = [...]list in_context_lines-- were not black-clean. After the squash merge the file is unbaselined and carries those constructs, so the whole-tree audit correctly flags it.black --target-version py310 src/kiro_crew/apps/builtins/meetings/backend/domain/session.py, on that one file. Whitespace-only diff (two hunks); regex and f-string content are byte-identical.Backwards compatibility
Compatible: formatting-only change; the compiled regex and the rendered context lines are unchanged.
Tests
The gate script is the test:
black --check --target-version py310 <file>exits 0 on this head and exits 1 onorigin/main(red-on-base, green-after).isort --check-only,flake8andmypyon the file all pass. No test suite run locally; CI runs the suites.Manual verification
git diff origin/main..HEAD --statlists onlysrc/kiro_crew/apps/builtins/meetings/backend/domain/session.py.ast.dump(ast.parse(before)) == ast.dump(ast.parse(after))isTruefor the file atorigin/mainvs this head; the diff is whitespace/line-break only (4 insertions, 3 deletions).Screenshots / video
N/A -- CI-only formatting fix, no user-visible surface.
Related Issues
None closed. This is the black baseline drift introduced by the interplay of #14483 (graduated the file from the baseline) and #14642 (added unformatted lines while based on the pre-graduation main). The separate
pid_readerratchet count drift tracked in #14768 was healed by #14778 and is not part of this PR.Pattern harvest
Not generalizable: the gate itself is correct and caught the drift within one audit cycle; the gap is the ordinary base-race between two PRs where one graduates a file from the baseline and the other, based on the older main, still relied on the exemption. A re-run of the PR lane on the final merge base would close it, but that is a CI-policy choice, not a rule in this PR's scope.
Checklist
feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)