FA-83096 / Go territory scoring / Open access
The board edge counts as liberties · case 01
Edge and corner chains report extra liberties.
ROOT CAUSE
Off-board neighbours pass the liberty test.
THE FAILURE
Off-board neighbours pass the liberty test.
Unsuccessful approach: An off-by-one upper bound still counts the bottom and right edges as liberties.
Case contract
Input [board, row, col]. Return [colour, chain_size, distinct_orthogonal_empty_liberties]; an empty point gives [".", 0, 0].
Why this case matters
Go servers and scoring tools compute this value automatically; a wrong answer changes a game result.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(x):
board, r, c = x
n = len(board)
m = len(board[0])
col = board[r][c]
if col == '.':
return ['.', 0, 0]
chain = [(r, c)]
k = 0
while k < len(chain):
i, j = chain[k]
k += 1
for p, q in ((i + 1, j), (i - 1, j), (i, j + 1), (i, j - 1)):
if 0 <= p < n and 0 <= q < m and board[p][q] == col and (p, q) not in chain:
chain.append((p, q))
libs = set()
for i, j in chain:
for p, q in ((i, j - 1), (i, j + 1), (i - 1, j), (i + 1, j)):
if not (0 <= p < n and 0 <= q < m) or board[p][q] == '.':
libs.add((p, q))
return [col, len(chain), len(libs)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[[[['.B.', 'B.B', '.B.'], 1, 0], ['B', 1, 3]], [[['B..W', 'B..W', 'B..W', 'B..W'], 3, 3], ['W', 4, 4]], [[['B..W', 'B..W', 'B..W', 'B..W'], 3, 2], ['.', 0, 0]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 3, 2], ['W', 4, 4]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 3, 1], ['B', 4, 4]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 1, 1], ['B', 4, 4]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 2, 0], ['.', 0, 0]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 3, 3], ['W', 6, 4]]], [[[['B..W', 'B..W', 'B..W', 'B..W'], 1, 0], ['B', 4, 4]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 3, 1], ['W', 6, 4]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 1, 2], ['B', 7, 6]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 1, 1], ['.', 0, 0]], [[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 1, 1], ['B', 1, 4]], [[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 2, 2], ['B', 1, 2]], [[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 3, 0], ['B', 3, 4]], [[['W....', '.....', '.....', '.....', '....B'], 4, 4], ['B', 1, 2]]], [[[['.BW.', '.BW.', '.BW.', '.BW.'], 3, 2], ['W', 4, 4]], [[['W....', '.....', '.....', '.....', '....B'], 4, 4], ['B', 1, 2]], [[['W....', '.....', '.....', '.....', '....B'], 0, 0], ['W', 1, 2]], [[['W....', '.....', '.....', '.....', '....B'], 1, 0], ['.', 0, 0]], [[['.W.B.', 'W.WB.', '.WB..', 'WB...', 'B....'], 2, 1], ['W', 1, 2]], [[['.W.B.', 'W.WB.', '.WB..', 'WB...', 'B....'], 4, 0], ['B', 1, 1]], [[['.W.B.', 'W.WB.', '.WB..', 'WB...', 'B....'], 3, 0], ['W', 1, 1]], [[['WWW', 'W.W', 'WWW'], 2, 1], ['W', 8, 1]]], [[[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 3, 3], ['W', 6, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 3, 0], ['B', 12, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 3, 2], ['B', 12, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 0, 1], ['B', 12, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 2, 2], ['.', 0, 0]], [[['WWW', 'W.W', 'WWW'], 2, 1], ['W', 8, 1]], [[['WWW', 'W.W', 'WWW'], 1, 2], ['W', 8, 1]], [[['.B...', 'B....', '.....', '....W', '...W.'], 4, 3], ['W', 1, 3]]], [[[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 3, 0], ['B', 3, 4]], [[['WWW', 'W.W', 'WWW'], 1, 1], ['.', 0, 0]], [[['B.W', '...', 'W.B'], 0, 0], ['B', 1, 2]], [[['B.W', '...', 'W.B'], 0, 2], ['W', 1, 2]], [[['B.W', '...', 'W.B'], 2, 2], ['B', 1, 2]], [[['B.W', '...', 'W.B'], 1, 2], ['.', 0, 0]], [[['.B...', 'B....', '.....', '....W', '...W.'], 4, 3], ['W', 1, 3]], [[['WB.B', 'B.B.', '.B..', 'B...'], 3, 0], ['B', 1, 2]]]]
for i, (args, expected) in enumerate(fixtures[N-1]):
check("chain case %d" % i, solve(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 |
|---|---|---|---|
| chain case 0 | ['B', 1, 4] | ['B', 1, 3] | Failed |
| chain case 1 | ['W', 4, 10] | ['W', 4, 4] | Failed |
| chain case 2 | ['.', 0, 0] | ['.', 0, 0] | Passed |
| chain case 3 | ['W', 4, 6] | ['W', 4, 4] | Failed |
| chain case 4 | ['B', 4, 6] | ['B', 4, 4] | Failed |
| chain case 5 | ['B', 4, 6] | ['B', 4, 4] | Failed |
| chain case 6 | ['.', 0, 0] | ['.', 0, 0] | Passed |
| chain case 7 | ['W', 6, 7] | ['W', 6, 4] | Failed |
SHA-256 / 1cfb264bc3efce941cc250b8f469ee006f4d60ea4bf8599e8bfd905de0d88611
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(x):
board, r, c = x
n = len(board)
m = len(board[0])
col = board[r][c]
if col == '.':
return ['.', 0, 0]
chain = [(r, c)]
k = 0
while k < len(chain):
i, j = chain[k]
k += 1
for p, q in ((i + 1, j), (i - 1, j), (i, j + 1), (i, j - 1)):
if 0 <= p < n and 0 <= q < m and board[p][q] == col and (p, q) not in chain:
chain.append((p, q))
libs = set()
for i, j in chain:
for p, q in ((i, j - 1), (i, j + 1), (i - 1, j), (i + 1, j)):
if 0 <= p <= n and 0 <= q <= m and (p == n or q == m or board[p][q] == '.'):
libs.add((p, q))
return [col, len(chain), len(libs)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[[[['.B.', 'B.B', '.B.'], 1, 0], ['B', 1, 3]], [[['B..W', 'B..W', 'B..W', 'B..W'], 3, 3], ['W', 4, 4]], [[['B..W', 'B..W', 'B..W', 'B..W'], 3, 2], ['.', 0, 0]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 3, 2], ['W', 4, 4]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 3, 1], ['B', 4, 4]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 1, 1], ['B', 4, 4]], [[['.BW.', '.BW.', '.BW.', '.BW.'], 2, 0], ['.', 0, 0]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 3, 3], ['W', 6, 4]]], [[[['B..W', 'B..W', 'B..W', 'B..W'], 1, 0], ['B', 4, 4]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 3, 1], ['W', 6, 4]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 1, 2], ['B', 7, 6]], [[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 1, 1], ['.', 0, 0]], [[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 1, 1], ['B', 1, 4]], [[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 2, 2], ['B', 1, 2]], [[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 3, 0], ['B', 3, 4]], [[['W....', '.....', '.....', '.....', '....B'], 4, 4], ['B', 1, 2]]], [[[['.BW.', '.BW.', '.BW.', '.BW.'], 3, 2], ['W', 4, 4]], [[['W....', '.....', '.....', '.....', '....B'], 4, 4], ['B', 1, 2]], [[['W....', '.....', '.....', '.....', '....B'], 0, 0], ['W', 1, 2]], [[['W....', '.....', '.....', '.....', '....B'], 1, 0], ['.', 0, 0]], [[['.W.B.', 'W.WB.', '.WB..', 'WB...', 'B....'], 2, 1], ['W', 1, 2]], [[['.W.B.', 'W.WB.', '.WB..', 'WB...', 'B....'], 4, 0], ['B', 1, 1]], [[['.W.B.', 'W.WB.', '.WB..', 'WB...', 'B....'], 3, 0], ['W', 1, 1]], [[['WWW', 'W.W', 'WWW'], 2, 1], ['W', 8, 1]]], [[[['..B..', '..B..', 'BBBBB', 'WWWWW', '..W..'], 3, 3], ['W', 6, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 3, 0], ['B', 12, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 3, 2], ['B', 12, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 0, 1], ['B', 12, 4]], [[['BBBB', 'B..B', 'B..B', 'BBBB'], 2, 2], ['.', 0, 0]], [[['WWW', 'W.W', 'WWW'], 2, 1], ['W', 8, 1]], [[['WWW', 'W.W', 'WWW'], 1, 2], ['W', 8, 1]], [[['.B...', 'B....', '.....', '....W', '...W.'], 4, 3], ['W', 1, 3]]], [[[['B.B.W', '.B.W.', 'B.BW.', 'BBW.W', '..W..'], 3, 0], ['B', 3, 4]], [[['WWW', 'W.W', 'WWW'], 1, 1], ['.', 0, 0]], [[['B.W', '...', 'W.B'], 0, 0], ['B', 1, 2]], [[['B.W', '...', 'W.B'], 0, 2], ['W', 1, 2]], [[['B.W', '...', 'W.B'], 2, 2], ['B', 1, 2]], [[['B.W', '...', 'W.B'], 1, 2], ['.', 0, 0]], [[['.B...', 'B....', '.....', '....W', '...W.'], 4, 3], ['W', 1, 3]], [[['WB.B', 'B.B.', '.B..', 'B...'], 3, 0], ['B', 1, 2]]]]
for i, (args, expected) in enumerate(fixtures[N-1]):
check("chain case %d" % i, solve(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 |
|---|---|---|---|
| chain case 0 | ['B', 1, 3] | ['B', 1, 3] | Passed |
| chain case 1 | ['W', 4, 9] | ['W', 4, 4] | Failed |
| chain case 2 | ['.', 0, 0] | ['.', 0, 0] | Passed |
| chain case 3 | ['W', 4, 5] | ['W', 4, 4] | Failed |
| chain case 4 | ['B', 4, 5] | ['B', 4, 4] | Failed |
| chain case 5 | ['B', 4, 5] | ['B', 4, 4] | Failed |
| chain case 6 | ['.', 0, 0] | ['.', 0, 0] | Passed |
| chain case 7 | ['W', 6, 6] | ['W', 6, 4] | Failed |
SHA-256 / eb1cfdcd9326ef08de1016eacfd2dfebe197e4b9d5eaa31cc8bb6456aa8e2be4
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 8 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
Small rectangular toy boards given as strings of B, W and dot; a bounded teaching model of one scoring or bookkeeping rule, not a complete rules engine or server implementation. 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:18.452995+00:00.
Case digest / 340b6005998e413fa9f77dc069e73013f3e38d15110bf4ca0bbd6c51c719dd2b