Test the fact for two items and the warning's release
CI / tests (pull_request) Successful in 4m21s

This commit is contained in:
2026-11-27 21:05:06 +01:00
parent e4fa2275a6
commit f89bdd9938
2 changed files with 8 additions and 3 deletions
+3 -3
View File
@@ -98,10 +98,10 @@ class FilePlan:
def warnings(self) -> list[str]:
"""What `rank_todo.py --check` says of the file without failing on it: which items of its earliest release hold no `Touches:` list."""
plan = self.read()
if isinstance(plan, Failure) or not plan.items:
if isinstance(plan, Failure):
return []
missing = unpredicted(plan.items, min(item.release for item in plan.items))
return [f"{self.path}: warning: {missing}; write each as `~/.claude/rules/todo-items.md` says"] if missing else []
earliest = sorted({item.release for item in plan.items})[:1]
return [f"{self.path}: warning: {missing}; write each as `~/.claude/rules/todo-items.md` says" for release in earliest if (missing := unpredicted(plan.items, release))]
def reported(self, ranked: ranking.Ranked) -> list[str]:
"""Ranking's notes and under-bar lines, each prefixed with the file's path, as a tool prints them on stderr."""