FA-83866 / Sports scoring and tiebreakers / Open access
Tiebreak target compared with a strict inequality · case 01
A 7-5 tiebreak is not closed and play continues to eight points.
ROOT CAUSE
The target check requires more than target points instead of at least target.
THE FAILURE
The target check requires more than target points instead of at least target.
Unsuccessful approach: Comparing the combined point total with the target closes tiebreaks such as 5-2 early.
Case contract
Tiebreak game. points is a string of A/B point winners; target is 7 (standard) or 10 (match tiebreak). The tiebreak ends at the first point where a player has at least target points and a two-point lead; later points are ignored. first_server serves point 0, then serve alternates every two points (point k is served by first_server when ((k + 1) // 2) is even). Return [a, b, winner or None, server of the next point or None when finished, ends_change] where ends_change is true when the tiebreak is unfinished and a positive multiple of 6 points has been played.
Why this case matters
Chair-umpire scoring software must drive the server indicator and change-of-ends prompt during tiebreaks.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(points, first_server, target):
def finished(x, y):
return max(x, y) > target and abs(x - y) >= 2
a = b = 0
for p in points:
if p == 'A':
a += 1
else:
b += 1
if finished(a, b):
break
played = a + b
winner = None
if finished(a, b):
winner = 'A' if a > b else 'B'
other = 'B' if first_server == 'A' else 'A'
server = first_server if ((played + 1) // 2) % 2 == 0 else other
ends_change = played > 0 and played % 6 == 0 and winner is None
return [a, b, winner, None if winner else server, ends_change]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
def run(args):
try:
return solve(*args)
except Exception as exc:
return 'raised ' + type(exc).__name__
cases = [[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBBBABBB', 'A', 7), [1, 7, 'B', None, False]),
('variant scenario 1', ('B', 'A', 7), [0, 1, None, 'B', False]),
('variant scenario 2', ('BAAA', 'A', 10), [3, 1, None, 'A', False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBAAAABBBABBB', 'B', 7), [5, 7, 'B', None, False]),
('regression: target threshold', ('BAAAABBAABAABBAB', 'B', 7), [7, 4, 'A', None, False]),
('variant scenario 1', ('AAAAA', 'B', 7), [5, 0, None, 'A', False]),
('variant scenario 2', ('ABBA', 'A', 7), [2, 2, None, 'A', False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('AAABABA', 'A', 7), [5, 2, None, 'A', False]),
('regression: target threshold', ('ABABAABAAABA', 'B', 7), [7, 3, 'A', None, False]),
('variant scenario 1', ('AA', 'A', 10), [2, 0, None, 'B', False]),
('variant scenario 2', ('BABBBABBABBABA', 'B', 10), [5, 9, None, 'A', False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBBBABABABBBBABABB', 'B', 10), [3, 10, 'B', None, False]),
('variant scenario 1', ('ABB', 'B', 7), [1, 2, None, 'B', False]),
('variant scenario 2', ('AABAAABBBABABBBBABBBB', 'A', 10), [8, 10, 'B', None, False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBABBBBBBBABBBBABABBAA', 'A', 10), [2, 10, 'B', None, False]),
('variant scenario 1', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('variant scenario 2', ('BBBBABBAABBBAABB', 'A', 7), [3, 7, 'B', None, False])]]
for label, args, expected in cases[N - 1]:
check(label, run(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| control opening point | [0, 0, None, 'A', False] | [0, 0, None, 'A', False] | Passed |
| boundary second server pair | [1, 0, None, 'B', False] | [1, 0, None, 'B', False] | Passed |
| boundary third point back to first | [1, 1, None, 'A', False] | [1, 1, None, 'A', False] | Passed |
| control seven-five tiebreak | [7, 5, None, 'A', True] | [7, 5, 'A', None, False] | Failed |
| boundary change of ends at six | [3, 3, None, 'B', True] | [3, 3, None, 'B', True] | Passed |
| control match tiebreak not over at seven | [7, 0, None, 'B', False] | [7, 0, None, 'B', False] | Passed |
| regression: target threshold | [1, 7, None, 'A', False] | [1, 7, 'B', None, False] | Failed |
| variant scenario 1 | [0, 1, None, 'B', False] | [0, 1, None, 'B', False] | Passed |
| variant scenario 2 | [3, 1, None, 'A', False] | [3, 1, None, 'A', False] | Passed |
SHA-256 / de11715cf580a0b2429e0576b0eaa1322722c7cfe91a488676bc2c5b72c9678f
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(points, first_server, target):
def finished(x, y):
return x + y >= target and abs(x - y) >= 2
a = b = 0
for p in points:
if p == 'A':
a += 1
else:
b += 1
if finished(a, b):
break
played = a + b
winner = None
if finished(a, b):
winner = 'A' if a > b else 'B'
other = 'B' if first_server == 'A' else 'A'
server = first_server if ((played + 1) // 2) % 2 == 0 else other
ends_change = played > 0 and played % 6 == 0 and winner is None
return [a, b, winner, None if winner else server, ends_change]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
def run(args):
try:
return solve(*args)
except Exception as exc:
return 'raised ' + type(exc).__name__
cases = [[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBBBABBB', 'A', 7), [1, 7, 'B', None, False]),
('variant scenario 1', ('B', 'A', 7), [0, 1, None, 'B', False]),
('variant scenario 2', ('BAAA', 'A', 10), [3, 1, None, 'A', False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBAAAABBBABBB', 'B', 7), [5, 7, 'B', None, False]),
('regression: target threshold', ('BAAAABBAABAABBAB', 'B', 7), [7, 4, 'A', None, False]),
('variant scenario 1', ('AAAAA', 'B', 7), [5, 0, None, 'A', False]),
('variant scenario 2', ('ABBA', 'A', 7), [2, 2, None, 'A', False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('AAABABA', 'A', 7), [5, 2, None, 'A', False]),
('regression: target threshold', ('ABABAABAAABA', 'B', 7), [7, 3, 'A', None, False]),
('variant scenario 1', ('AA', 'A', 10), [2, 0, None, 'B', False]),
('variant scenario 2', ('BABBBABBABBABA', 'B', 10), [5, 9, None, 'A', False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBBBABABABBBBABABB', 'B', 10), [3, 10, 'B', None, False]),
('variant scenario 1', ('ABB', 'B', 7), [1, 2, None, 'B', False]),
('variant scenario 2', ('AABAAABBBABABBBBABBBB', 'A', 10), [8, 10, 'B', None, False])],
[('control opening point', ('', 'A', 7), [0, 0, None, 'A', False]),
('boundary second server pair', ('A', 'A', 7), [1, 0, None, 'B', False]),
('boundary third point back to first', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('control seven-five tiebreak', ('AAAAABBBBBAA', 'A', 7), [7, 5, 'A', None, False]),
('boundary change of ends at six', ('ABABAB', 'A', 7), [3, 3, None, 'B', True]),
('control match tiebreak not over at seven', ('AAAAAAA', 'B', 10), [7, 0, None, 'B', False]),
('regression: target threshold', ('BBABBBBBBBABBBBABABBAA', 'A', 10), [2, 10, 'B', None, False]),
('variant scenario 1', ('AB', 'B', 7), [1, 1, None, 'A', False]),
('variant scenario 2', ('BBBBABBAABBBAABB', 'A', 7), [3, 7, 'B', None, False])]]
for label, args, expected in cases[N - 1]:
check(label, run(args), expected)
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| control opening point | [0, 0, None, 'A', False] | [0, 0, None, 'A', False] | Passed |
| boundary second server pair | [1, 0, None, 'B', False] | [1, 0, None, 'B', False] | Passed |
| boundary third point back to first | [1, 1, None, 'A', False] | [1, 1, None, 'A', False] | Passed |
| control seven-five tiebreak | [5, 2, 'A', None, False] | [7, 5, 'A', None, False] | Failed |
| boundary change of ends at six | [3, 3, None, 'B', True] | [3, 3, None, 'B', True] | Passed |
| control match tiebreak not over at seven | [7, 0, None, 'B', False] | [7, 0, None, 'B', False] | Passed |
| regression: target threshold | [1, 6, 'B', None, False] | [1, 7, 'B', None, False] | Failed |
| variant scenario 1 | [0, 1, None, 'B', False] | [0, 1, None, 'B', False] | Passed |
| variant scenario 2 | [3, 1, None, 'A', False] | [3, 1, None, 'A', False] | Passed |
SHA-256 / 810d5fde758c45ed5b2fa87a0ed2cfe9d525eac07cb8aa9079454dfc7fa1504b
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 9 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.
Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.
Member access is invitation-based. Sign in with your invited account to inspect the repair.
Sign in to the archive ↗Verification & scope
Stipulated, bounded toy contract stated in the contract field; not a claim of conformance with any governing body rulebook or operator house rules. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.
Observations recorded using Python 3.12.14 at 2026-09-29T14:50:25.556413+00:00.
Case digest / bf100f2096ee8193370cbb62845037ea94cca34f9a88e45df29c5053f3f8482c