Answer principles round 2: 0 🔴, 0 🟡; decide ships-alone in one predicate both modules call
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
"""The lines the preflight prints, stated from what it gathered."""
|
||||
from todo_table import BUNDLE_MAX_R, bundle_candidates, Item, version
|
||||
from todo_table import BUNDLE_MAX_R, bundle_candidates, Item, ships_alone, version
|
||||
from failure import Failure
|
||||
from chunk_preflight.gathered import Forge, Gathered, ItemFacts, NamedPath, NoItem, Plan, Ran
|
||||
from chunk_pick import LastCut, unreleased_entries
|
||||
@@ -66,7 +66,7 @@ def open_pulls(stdout: str, forge: Forge, branch: str) -> list[str]:
|
||||
|
||||
def bundled(plan: Plan) -> list[str]:
|
||||
first, candidates = plan.first, bundle_candidates(plan.items, plan.first)
|
||||
if first.scores.get("R", 0) > BUNDLE_MAX_R:
|
||||
if ships_alone(first):
|
||||
return [f"- Item {first.id} has R above {BUNDLE_MAX_R}, so it ships alone."]
|
||||
if not candidates:
|
||||
return [f"- No other item of release {version(first.release)} may join item {first.id}'s chunk."]
|
||||
|
||||
Reference in New Issue
Block a user