Move the next chunk's pick into chunk_pick, so git_repo only runs git and todo_table only parses the plan

This commit is contained in:
2026-10-18 10:33:36 +02:00
parent ca5edc2ae3
commit 6cdace6ae3
20 changed files with 332 additions and 277 deletions
+1 -1
View File
@@ -22,7 +22,7 @@ def history_changes(default: str) -> list[HistoryChange] | Failure:
return changes
def landed_since_release(default: str) -> bool | Failure:
def committed_since_release(default: str) -> bool | Failure:
"""Whether the default branch holds a commit after its newest `v*` tag, or any commit when it has none."""
newest = newest_release_tag(default)
if isinstance(newest, Failure):
+2 -2
View File
@@ -1,9 +1,9 @@
import pathlib
from larv_review.git import committed_since_release
from failure import Failure
from git_repo import file_at, top
from todo_table import Item, items, renames
from larv_review.git import landed_since_release
def scoring_run_due(before: list[Item], after: list[Item], ships: list[int], landed: bool, renamed: set[tuple[int, int, int]]) -> list[str] | Failure:
@@ -55,7 +55,7 @@ def plan_reasons(default: str, ids: list[int]) -> list[str] | Failure:
renamed = renames(after)
if isinstance(renamed, Failure):
return Failure(f"the checkout's todo.md: {renamed.reason}")
landed = landed_since_release(default)
landed = committed_since_release(default)
if isinstance(landed, Failure):
return landed
return scoring_run_due(planned, chunk, ids, landed, renamed)