{"abstract":"Two neighbours one digit apart receive a new position equal to the lower neighbour.","category":"CRDT convergence","checks":10,"contract":"Starting from the given sorted positions, positions are digit lists in base 10 compared lexicographically and never ending in 0. Inserting at list index i allocates between the neighbours p (or [] at the start) and q (or [] at the end): walking depth d, lower digit a is p[d] or 0, upper digit b is q[d] while q still constrains (else 10); if b - a > 1 append (a+b)//2 and stop, else append a, and q stops constraining once a < b. Return positions as dotted strings in list order.","evaluation_group":"w2-crdt-convergence-fractional-position-allocation","failed_approach":"Taking the digit above the lower bound collides with the upper neighbour instead.","family":"w2-crdt-convergence-fractional-position-allocation-gap-test","id":"FA-75206","implementations":{"attempt":{"sha256":"75dd59669207ac940004851d9529069aaf386678a172fb6cfa6fa026d9d29b17","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(initial, inserts):\n    BASE = 10\n    lst = [list(p) for p in initial]\n    def between(p, q):\n        out = []\n        upper = True\n        d = 0\n        while True:\n            a = p[d] if d < len(p) else 0\n            b = q[d] if upper and d < len(q) else BASE\n            if b - a > 0:\n                out.append(a + 1)\n                return out\n            out.append(a)\n            if a < b:\n                upper = False\n            d += 1\n    for i in inserts:\n        p = lst[i - 1] if i > 0 else []\n        q = lst[i] if i < len(lst) else []\n        lst.insert(i, between(p, q))\n    return ['.'.join(str(x) for x in pos) for pos in lst]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncases = {\n    1: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4]], ['5', '7', '8', '9', '9.5']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0]], ['0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2]], ['2', '5', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1]], ['1.2.9', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    2: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5]], ['5', '7', '8', '9', '9.5', '9.7']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0]], ['0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1]], ['2', '3', '5', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1]], ['1.2.9', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    3: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6]], ['5', '7', '8', '9', '9.5', '9.7', '9.8']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0]], ['0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3]], ['2', '3', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1]], ['1.2.9', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    4: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6, 7]], ['5', '7', '8', '9', '9.5', '9.7', '9.8', '9.9']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0, 0]], ['0.0.2', '0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3, 2]], ['2', '3', '4', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1, 1]], ['1.2.9', '1.2.9.5', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    5: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6, 7, 8]], ['5', '7', '8', '9', '9.5', '9.7', '9.8', '9.9', '9.9.5']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0, 0, 0]], ['0.0.1', '0.0.2', '0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3, 2, 1]], ['2', '2.5', '3', '4', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1, 1, 1]], ['1.2.9', '1.2.9.2', '1.2.9.5', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n}[N]\nfor label, args, expected in cases:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"broken":{"sha256":"e61b62f847a4762fe9c50959af3fbdbf7c22fb0b9d04e05336ee917c009c8141","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(initial, inserts):\n    BASE = 10\n    lst = [list(p) for p in initial]\n    def between(p, q):\n        out = []\n        upper = True\n        d = 0\n        while True:\n            a = p[d] if d < len(p) else 0\n            b = q[d] if upper and d < len(q) else BASE\n            if b - a > 0:\n                out.append((a + b) // 2)\n                return out\n            out.append(a)\n            if a < b:\n                upper = False\n            d += 1\n    for i in inserts:\n        p = lst[i - 1] if i > 0 else []\n        q = lst[i] if i < len(lst) else []\n        lst.insert(i, between(p, q))\n    return ['.'.join(str(x) for x in pos) for pos in lst]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncases = {\n    1: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4]], ['5', '7', '8', '9', '9.5']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0]], ['0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2]], ['2', '5', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1]], ['1.2.9', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    2: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5]], ['5', '7', '8', '9', '9.5', '9.7']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0]], ['0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1]], ['2', '3', '5', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1]], ['1.2.9', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    3: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6]], ['5', '7', '8', '9', '9.5', '9.7', '9.8']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0]], ['0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3]], ['2', '3', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1]], ['1.2.9', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    4: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6, 7]], ['5', '7', '8', '9', '9.5', '9.7', '9.8', '9.9']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0, 0]], ['0.0.2', '0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3, 2]], ['2', '3', '4', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1, 1]], ['1.2.9', '1.2.9.5', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    5: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6, 7, 8]], ['5', '7', '8', '9', '9.5', '9.7', '9.8', '9.9', '9.9.5']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0, 0, 0]], ['0.0.1', '0.0.2', '0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3, 2, 1]], ['2', '2.5', '3', '4', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1, 1, 1]], ['1.2.9', '1.2.9.2', '1.2.9.5', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n}[N]\nfor label, args, expected in cases:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"},"fixed":{"sha256":"bd37b7eca55f08422e58136c50140f65844f3d387bad6d401573033c75ecb949","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(initial, inserts):\n    BASE = 10\n    lst = [list(p) for p in initial]\n    def between(p, q):\n        out = []\n        upper = True\n        d = 0\n        while True:\n            a = p[d] if d < len(p) else 0\n            b = q[d] if upper and d < len(q) else BASE\n            if b - a > 1:\n                out.append((a + b) // 2)\n                return out\n            out.append(a)\n            if a < b:\n                upper = False\n            d += 1\n    for i in inserts:\n        p = lst[i - 1] if i > 0 else []\n        q = lst[i] if i < len(lst) else []\n        lst.insert(i, between(p, q))\n    return ['.'.join(str(x) for x in pos) for pos in lst]\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncases = {\n    1: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4]], ['5', '7', '8', '9', '9.5']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0]], ['0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2]], ['2', '5', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1]], ['1.2.9', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    2: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5]], ['5', '7', '8', '9', '9.5', '9.7']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0]], ['0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1]], ['2', '3', '5', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1]], ['1.2.9', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    3: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6]], ['5', '7', '8', '9', '9.5', '9.7', '9.8']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0]], ['0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3]], ['2', '3', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1]], ['1.2.9', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    4: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6, 7]], ['5', '7', '8', '9', '9.5', '9.7', '9.8', '9.9']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0, 0]], ['0.0.2', '0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3, 2]], ['2', '3', '4', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1, 1]], ['1.2.9', '1.2.9.5', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n    5: [('first insert', [[], [0]], ['5']), ('append repeatedly', [[], [0, 1, 2, 3, 4, 5, 6, 7, 8]], ['5', '7', '8', '9', '9.5', '9.7', '9.8', '9.9', '9.9.5']), ('prepend repeatedly', [[], [0, 0, 0, 0, 0, 0, 0, 0, 0]], ['0.0.1', '0.0.2', '0.0.5', '0.1', '0.2', '0.5', '1', '2', '5']), ('insert between adjacent digits', [[], [0, 1, 1, 1, 1]], ['5', '5.2', '5.5', '6', '7']), ('insert after a deep position', [[], [0, 1, 1, 1, 2, 2]], ['5', '5.5', '5.6', '5.7', '6', '7']), ('mixed positions', [[], [0, 0, 2, 1, 3, 2, 1]], ['2', '2.5', '3', '4', '5', '6', '7']), ('upper neighbour stops constraining after divergence', [[[3, 7], [4, 8]], [1]], ['3.7', '3.8', '4.8']), ('deep upper neighbour after a one-digit step', [[[2], [3, 1, 4]], [1, 1]], ['2', '2.2', '2.5', '3.1.4']), ('long lower neighbour below a deep upper neighbour', [[[1, 2, 9], [2, 0, 5]], [1, 1, 1, 1, 1]], ['1.2.9', '1.2.9.2', '1.2.9.5', '1.3', '1.4', '1.6', '2.0.5']), ('open end after high digits', [[[8], [9, 9]], [2, 3]], ['8', '9.9', '9.9.5', '9.9.7'])],\n}[N]\nfor label, args, expected in cases:\n    check(label, solve(*args), expected)\nprint(json.dumps({\"observations\": observations, \"passed\": all(x[\"passed\"] for x in observations)}, ensure_ascii=False))\nraise SystemExit(0 if all(x[\"passed\"] for x in observations) else 1)\n"}},"limitations":"A deterministic, bounded teaching model of one replicated data type with stipulated operation and merge rules; it is not a production CRDT library and makes no claim of conformance to any specific published design. 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.","method":"Deterministic executable model with adversarial boundary fixtures.","provenance":{"created_by":"Failure Map","dependencies":"Python standard library","family":"w2-crdt-convergence-fractional-position-allocation-gap-test","generated_at":"2026-09-29T14:49:03.903435+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Sequence CRDTs such as Logoot and LSEQ assign dense identifiers so that concurrent inserts never need renumbering.","repair":"Descend a level unless the digits differ by at least two.","root_cause":"The allocator stops when the digits differ by one, where the midpoint equals the lower digit.","sha256":"34bec7dd26774206762278df0a6d17b79d704bf78a1db5c2f3ee5c28a1adda2f","title":"Fractional position allocation: a gap of one digit is treated as room · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":40.177,"exit_code":1,"observations":[{"actual":["1"],"check":"first insert","expected":["5"],"passed":false},{"actual":["1","2","3","4","5"],"check":"append repeatedly","expected":["5","7","8","9","9.5"],"passed":false},{"actual":["1","1","1","1","1"],"check":"prepend repeatedly","expected":["0.2","0.5","1","2","5"],"passed":false},{"actual":["1","2","2","2","2"],"check":"insert between adjacent digits","expected":["5","5.2","5.5","6","7"],"passed":false},{"actual":["1","2","2.1","2.1","2","2"],"check":"insert after a deep position","expected":["5","5.5","5.6","5.7","6","7"],"passed":false},{"actual":["1","1","2"],"check":"mixed positions","expected":["2","5","7"],"passed":false},{"actual":["3.7","4","4.8"],"check":"upper neighbour stops constraining after divergence","expected":["3.7","3.8","4.8"],"passed":false},{"actual":["2","3","3","3.1.4"],"check":"deep upper neighbour after a one-digit step","expected":["2","2.2","2.5","3.1.4"],"passed":false},{"actual":["1.2.9","2","2.0.5"],"check":"long lower neighbour below a deep upper neighbour","expected":["1.2.9","1.6","2.0.5"],"passed":false},{"actual":["8","9.9","10","10.1"],"check":"open end after high digits","expected":["8","9.9","9.9.5","9.9.7"],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"first insert\", \"actual\": [\"1\"], \"expected\": [\"5\"], \"passed\": false}, {\"check\": \"append repeatedly\", \"actual\": [\"1\", \"2\", \"3\", \"4\", \"5\"], \"expected\": [\"5\", \"7\", \"8\", \"9\", \"9.5\"], \"passed\": false}, {\"check\": \"prepend repeatedly\", \"actual\": [\"1\", \"1\", \"1\", \"1\", \"1\"], \"expected\": [\"0.2\", \"0.5\", \"1\", \"2\", \"5\"], \"passed\": false}, {\"check\": \"insert between adjacent digits\", \"actual\": [\"1\", \"2\", \"2\", \"2\", \"2\"], \"expected\": [\"5\", \"5.2\", \"5.5\", \"6\", \"7\"], \"passed\": false}, {\"check\": \"insert after a deep position\", \"actual\": [\"1\", \"2\", \"2.1\", \"2.1\", \"2\", \"2\"], \"expected\": [\"5\", \"5.5\", \"5.6\", \"5.7\", \"6\", \"7\"], \"passed\": false}, {\"check\": \"mixed positions\", \"actual\": [\"1\", \"1\", \"2\"], \"expected\": [\"2\", \"5\", \"7\"], \"passed\": false}, {\"check\": \"upper neighbour stops constraining after divergence\", \"actual\": [\"3.7\", \"4\", \"4.8\"], \"expected\": [\"3.7\", \"3.8\", \"4.8\"], \"passed\": false}, {\"check\": \"deep upper neighbour after a one-digit step\", \"actual\": [\"2\", \"3\", \"3\", \"3.1.4\"], \"expected\": [\"2\", \"2.2\", \"2.5\", \"3.1.4\"], \"passed\": false}, {\"check\": \"long lower neighbour below a deep upper neighbour\", \"actual\": [\"1.2.9\", \"2\", \"2.0.5\"], \"expected\": [\"1.2.9\", \"1.6\", \"2.0.5\"], \"passed\": false}, {\"check\": \"open end after high digits\", \"actual\": [\"8\", \"9.9\", \"10\", \"10.1\"], \"expected\": [\"8\", \"9.9\", \"9.9.5\", \"9.9.7\"], \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":39.468,"exit_code":1,"observations":[{"actual":["5"],"check":"first insert","expected":["5"],"passed":true},{"actual":["5","7","8","9","9"],"check":"append repeatedly","expected":["5","7","8","9","9.5"],"passed":false},{"actual":["0.5","0","1","2","5"],"check":"prepend repeatedly","expected":["0.2","0.5","1","2","5"],"passed":false},{"actual":["5","5.5","5","6","7"],"check":"insert between adjacent digits","expected":["5","5.2","5.5","6","7"],"passed":false},{"actual":["5","5","5.5","5","6","7"],"check":"insert after a deep position","expected":["5","5.5","5.6","5.7","6","7"],"passed":false},{"actual":["2","5","7"],"check":"mixed positions","expected":["2","5","7"],"passed":true},{"actual":["3.7","3","4.8"],"check":"upper neighbour stops constraining after divergence","expected":["3.7","3.8","4.8"],"passed":false},{"actual":["2","2.5","2","3.1.4"],"check":"deep upper neighbour after a one-digit step","expected":["2","2.2","2.5","3.1.4"],"passed":false},{"actual":["1.2.9","1","2.0.5"],"check":"long lower neighbour below a deep upper neighbour","expected":["1.2.9","1.6","2.0.5"],"passed":false},{"actual":["8","9.9","9","9"],"check":"open end after high digits","expected":["8","9.9","9.9.5","9.9.7"],"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"first insert\", \"actual\": [\"5\"], \"expected\": [\"5\"], \"passed\": true}, {\"check\": \"append repeatedly\", \"actual\": [\"5\", \"7\", \"8\", \"9\", \"9\"], \"expected\": [\"5\", \"7\", \"8\", \"9\", \"9.5\"], \"passed\": false}, {\"check\": \"prepend repeatedly\", \"actual\": [\"0.5\", \"0\", \"1\", \"2\", \"5\"], \"expected\": [\"0.2\", \"0.5\", \"1\", \"2\", \"5\"], \"passed\": false}, {\"check\": \"insert between adjacent digits\", \"actual\": [\"5\", \"5.5\", \"5\", \"6\", \"7\"], \"expected\": [\"5\", \"5.2\", \"5.5\", \"6\", \"7\"], \"passed\": false}, {\"check\": \"insert after a deep position\", \"actual\": [\"5\", \"5\", \"5.5\", \"5\", \"6\", \"7\"], \"expected\": [\"5\", \"5.5\", \"5.6\", \"5.7\", \"6\", \"7\"], \"passed\": false}, {\"check\": \"mixed positions\", \"actual\": [\"2\", \"5\", \"7\"], \"expected\": [\"2\", \"5\", \"7\"], \"passed\": true}, {\"check\": \"upper neighbour stops constraining after divergence\", \"actual\": [\"3.7\", \"3\", \"4.8\"], \"expected\": [\"3.7\", \"3.8\", \"4.8\"], \"passed\": false}, {\"check\": \"deep upper neighbour after a one-digit step\", \"actual\": [\"2\", \"2.5\", \"2\", \"3.1.4\"], \"expected\": [\"2\", \"2.2\", \"2.5\", \"3.1.4\"], \"passed\": false}, {\"check\": \"long lower neighbour below a deep upper neighbour\", \"actual\": [\"1.2.9\", \"1\", \"2.0.5\"], \"expected\": [\"1.2.9\", \"1.6\", \"2.0.5\"], \"passed\": false}, {\"check\": \"open end after high digits\", \"actual\": [\"8\", \"9.9\", \"9\", \"9\"], \"expected\": [\"8\", \"9.9\", \"9.9.5\", \"9.9.7\"], \"passed\": false}], \"passed\": false}\n"},"fixed":{"elapsed_ms":40.146,"exit_code":0,"observations":[{"actual":["5"],"check":"first insert","expected":["5"],"passed":true},{"actual":["5","7","8","9","9.5"],"check":"append repeatedly","expected":["5","7","8","9","9.5"],"passed":true},{"actual":["0.2","0.5","1","2","5"],"check":"prepend repeatedly","expected":["0.2","0.5","1","2","5"],"passed":true},{"actual":["5","5.2","5.5","6","7"],"check":"insert between adjacent digits","expected":["5","5.2","5.5","6","7"],"passed":true},{"actual":["5","5.5","5.6","5.7","6","7"],"check":"insert after a deep position","expected":["5","5.5","5.6","5.7","6","7"],"passed":true},{"actual":["2","5","7"],"check":"mixed positions","expected":["2","5","7"],"passed":true},{"actual":["3.7","3.8","4.8"],"check":"upper neighbour stops constraining after divergence","expected":["3.7","3.8","4.8"],"passed":true},{"actual":["2","2.2","2.5","3.1.4"],"check":"deep upper neighbour after a one-digit step","expected":["2","2.2","2.5","3.1.4"],"passed":true},{"actual":["1.2.9","1.6","2.0.5"],"check":"long lower neighbour below a deep upper neighbour","expected":["1.2.9","1.6","2.0.5"],"passed":true},{"actual":["8","9.9","9.9.5","9.9.7"],"check":"open end after high digits","expected":["8","9.9","9.9.5","9.9.7"],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"first insert\", \"actual\": [\"5\"], \"expected\": [\"5\"], \"passed\": true}, {\"check\": \"append repeatedly\", \"actual\": [\"5\", \"7\", \"8\", \"9\", \"9.5\"], \"expected\": [\"5\", \"7\", \"8\", \"9\", \"9.5\"], \"passed\": true}, {\"check\": \"prepend repeatedly\", \"actual\": [\"0.2\", \"0.5\", \"1\", \"2\", \"5\"], \"expected\": [\"0.2\", \"0.5\", \"1\", \"2\", \"5\"], \"passed\": true}, {\"check\": \"insert between adjacent digits\", \"actual\": [\"5\", \"5.2\", \"5.5\", \"6\", \"7\"], \"expected\": [\"5\", \"5.2\", \"5.5\", \"6\", \"7\"], \"passed\": true}, {\"check\": \"insert after a deep position\", \"actual\": [\"5\", \"5.5\", \"5.6\", \"5.7\", \"6\", \"7\"], \"expected\": [\"5\", \"5.5\", \"5.6\", \"5.7\", \"6\", \"7\"], \"passed\": true}, {\"check\": \"mixed positions\", \"actual\": [\"2\", \"5\", \"7\"], \"expected\": [\"2\", \"5\", \"7\"], \"passed\": true}, {\"check\": \"upper neighbour stops constraining after divergence\", \"actual\": [\"3.7\", \"3.8\", \"4.8\"], \"expected\": [\"3.7\", \"3.8\", \"4.8\"], \"passed\": true}, {\"check\": \"deep upper neighbour after a one-digit step\", \"actual\": [\"2\", \"2.2\", \"2.5\", \"3.1.4\"], \"expected\": [\"2\", \"2.2\", \"2.5\", \"3.1.4\"], \"passed\": true}, {\"check\": \"long lower neighbour below a deep upper neighbour\", \"actual\": [\"1.2.9\", \"1.6\", \"2.0.5\"], \"expected\": [\"1.2.9\", \"1.6\", \"2.0.5\"], \"passed\": true}, {\"check\": \"open end after high digits\", \"actual\": [\"8\", \"9.9\", \"9.9.5\", \"9.9.7\"], \"expected\": [\"8\", \"9.9\", \"9.9.5\", \"9.9.7\"], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}