Answer prose round 1: 0 🔴, 8 🟡; say every way the anchors are left out, name what a missing file shows, and untangle the scoring rule's lists
This commit is contained in:
+1
-1
@@ -231,7 +231,7 @@ def parse_scores(id_: str, named: dict[str, str], names: tuple[str, ...]) -> dic
|
||||
|
||||
|
||||
def parse_ids(cell: str) -> tuple[int, ...] | None:
|
||||
"""The item IDs a cell lists, such as `12, 14`, none where it is empty; None where it holds anything else."""
|
||||
"""The item IDs a cell lists, such as `12, 14`: an empty tuple where the cell is empty, None where it holds anything else."""
|
||||
if not re.fullmatch(r"([0-9]+(, [0-9]+)*)?", cell):
|
||||
return None
|
||||
return tuple(int(id_) for id_ in cell.split(", ") if id_)
|
||||
|
||||
Reference in New Issue
Block a user