{"abstract":"Stitched rings lose their closing vertex and contain doubled junctions.","category":"GIS polygon topology","checks":8,"contract":"Input [arcs, transform, ring]. Each arc is a list of quantized delta positions (the first is absolute, later ones add to the running position within that arc). transform [sx, sy, tx, ty] maps q to q*s + t per axis; a null transform is the identity [1, 1, 0, 0]. A ring lists arc indexes; a negative index i means arc ~i (bitwise complement) traversed backwards. Arcs after the first contribute all but their first position, which duplicates the previous arc end. Return the stitched list of [x, y].","evaluation_group":"w2-gis-polygon-topology-topojson-arc-rings","failed_approach":"The junction is dropped for forward arcs only; backward arcs still repeat it.","family":"w2-gis-polygon-topology-topojson-arc-rings-junction-de-duplication","id":"FA-70491","implementations":{"attempt":{"sha256":"c3d8a6b75c95cab627499487f5970eda9d7379473503e109a10cda4de57a4d72","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(x):\n    arcs, transform, ring = x\n    sx, sy, tx, ty = transform or [1, 1, 0, 0]\n    def decode(i):\n        pts = []\n        qx = qy = 0\n        for dx, dy in arcs[i]:\n            qx += dx\n            qy += dy\n            pts.append([qx * sx + tx, qy * sy + ty])\n        return pts\n    out = []\n    for ref in ring:\n        idx = ~ref if ref < 0 else ref\n        pts = decode(idx)\n        if ref < 0:\n            pts = pts[::-1]\n        if out and ref >= 0:\n            pts = pts[1:]\n        out.extend(pts)\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[('control #0', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #1', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #2', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-2, -1]], [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #4', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, -3, -4]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #1', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #5', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [4, -2]], [[100.0, 202.5], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5], [100.0, 202.5], [105.0, 202.5]]), ('control #6', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [1, 4]], [[105.0, 202.5], [100.0, 202.5], [100.0, 200.0], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5]]), ('control #7', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [0, 1]], [[0, 0], [10, 0], [10, 10], [0, 10], [0, 0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #2', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-2, -1]], [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('control #5', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [4, -2]], [[100.0, 202.5], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5], [100.0, 202.5], [105.0, 202.5]]), ('control #8', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [-2, -1]], [[0, 0], [0, 10], [10, 10], [10, 0], [0, 0]]), ('control #9', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [2, 3, -1]], [[10, 10], [15, 10], [15, 0], [10, 0], [10, 0], [0, 0]]), ('control #10', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [1, 4]], [[10, 10], [0, 10], [0, 0], [0, 15], [10, 15], [10, 10]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #8', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [-2, -1]], [[0, 0], [0, 10], [10, 10], [10, 0], [0, 0]]), ('regression #11', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [2.0, 3.0, -5.0, 7.0], [0, -3, -4]], [[-5.0, 7.0], [15.0, 7.0], [15.0, 37.0], [25.0, 37.0], [15.0, 37.0], [25.0, 7.0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #14', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [1.0, 1.0, 0.0, 0.0], [-5, 0]], [[10.0, 10.0], [10.0, 15.0], [0.0, 15.0], [0.0, 10.0], [10.0, 0.0], [10.0, 10.0]]), ('control #15', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.1, 0.1, -1.0, 2.0], [3, -3, 1]], [[0.5, 2.0], [0.0, 2.0], [0.5, 3.0], [0.0, 3.0], [-1.0, 3.0], [-1.0, 2.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #0', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #4', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, -3, -4]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]]), ('control #9', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [2, 3, -1]], [[10, 10], [15, 10], [15, 0], [10, 0], [10, 0], [0, 0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('regression #14', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [1.0, 1.0, 0.0, 0.0], [-5, 0]], [[10.0, 10.0], [10.0, 15.0], [0.0, 15.0], [0.0, 10.0], [10.0, 0.0], [10.0, 10.0]]), ('control #15', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.1, 0.1, -1.0, 2.0], [3, -3, 1]], [[0.5, 2.0], [0.0, 2.0], [0.5, 3.0], [0.0, 3.0], [-1.0, 3.0], [-1.0, 2.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]]), ('regression #17', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [-1]], [[3.0, 8.0], [5.0, 12.0], [5.0, 8.0], [3.0, 8.0]])]]\nfor label, args, expected in fixtures[N-1]:\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":"c56fab5c5002616f37e592eae5e3bf131f0b2eccf78e425009843c7ed51d588a","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(x):\n    arcs, transform, ring = x\n    sx, sy, tx, ty = transform or [1, 1, 0, 0]\n    def decode(i):\n        pts = []\n        qx = qy = 0\n        for dx, dy in arcs[i]:\n            qx += dx\n            qy += dy\n            pts.append([qx * sx + tx, qy * sy + ty])\n        return pts\n    out = []\n    for ref in ring:\n        idx = ~ref if ref < 0 else ref\n        pts = decode(idx)\n        if ref < 0:\n            pts = pts[::-1]\n        if out:\n            pts = pts[:-1]\n        out.extend(pts)\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[('control #0', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #1', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #2', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-2, -1]], [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #4', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, -3, -4]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #1', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #5', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [4, -2]], [[100.0, 202.5], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5], [100.0, 202.5], [105.0, 202.5]]), ('control #6', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [1, 4]], [[105.0, 202.5], [100.0, 202.5], [100.0, 200.0], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5]]), ('control #7', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [0, 1]], [[0, 0], [10, 0], [10, 10], [0, 10], [0, 0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #2', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-2, -1]], [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('control #5', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [4, -2]], [[100.0, 202.5], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5], [100.0, 202.5], [105.0, 202.5]]), ('control #8', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [-2, -1]], [[0, 0], [0, 10], [10, 10], [10, 0], [0, 0]]), ('control #9', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [2, 3, -1]], [[10, 10], [15, 10], [15, 0], [10, 0], [10, 0], [0, 0]]), ('control #10', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [1, 4]], [[10, 10], [0, 10], [0, 0], [0, 15], [10, 15], [10, 10]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #8', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [-2, -1]], [[0, 0], [0, 10], [10, 10], [10, 0], [0, 0]]), ('regression #11', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [2.0, 3.0, -5.0, 7.0], [0, -3, -4]], [[-5.0, 7.0], [15.0, 7.0], [15.0, 37.0], [25.0, 37.0], [15.0, 37.0], [25.0, 7.0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #14', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [1.0, 1.0, 0.0, 0.0], [-5, 0]], [[10.0, 10.0], [10.0, 15.0], [0.0, 15.0], [0.0, 10.0], [10.0, 0.0], [10.0, 10.0]]), ('control #15', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.1, 0.1, -1.0, 2.0], [3, -3, 1]], [[0.5, 2.0], [0.0, 2.0], [0.5, 3.0], [0.0, 3.0], [-1.0, 3.0], [-1.0, 2.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #0', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #4', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, -3, -4]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]]), ('control #9', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [2, 3, -1]], [[10, 10], [15, 10], [15, 0], [10, 0], [10, 0], [0, 0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('regression #14', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [1.0, 1.0, 0.0, 0.0], [-5, 0]], [[10.0, 10.0], [10.0, 15.0], [0.0, 15.0], [0.0, 10.0], [10.0, 0.0], [10.0, 10.0]]), ('control #15', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.1, 0.1, -1.0, 2.0], [3, -3, 1]], [[0.5, 2.0], [0.0, 2.0], [0.5, 3.0], [0.0, 3.0], [-1.0, 3.0], [-1.0, 2.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]]), ('regression #17', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [-1]], [[3.0, 8.0], [5.0, 12.0], [5.0, 8.0], [3.0, 8.0]])]]\nfor label, args, expected in fixtures[N-1]:\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":"8a4c1f22d2c4d4d9e4b5b5fc16123d9f4ee86ca10e43aaf7ea63b8cc308c17e0","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\nimport math\nN = 1\nobservations = []\ndef solve(x):\n    arcs, transform, ring = x\n    sx, sy, tx, ty = transform or [1, 1, 0, 0]\n    def decode(i):\n        pts = []\n        qx = qy = 0\n        for dx, dy in arcs[i]:\n            qx += dx\n            qy += dy\n            pts.append([qx * sx + tx, qy * sy + ty])\n        return pts\n    out = []\n    for ref in ring:\n        idx = ~ref if ref < 0 else ref\n        pts = decode(idx)\n        if ref < 0:\n            pts = pts[::-1]\n        if out:\n            pts = pts[1:]\n        out.extend(pts)\n    return out\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\nfixtures = [[('control #0', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #1', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #2', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-2, -1]], [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #4', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, -3, -4]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #1', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #5', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [4, -2]], [[100.0, 202.5], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5], [100.0, 202.5], [105.0, 202.5]]), ('control #6', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [1, 4]], [[105.0, 202.5], [100.0, 202.5], [100.0, 200.0], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5]]), ('control #7', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [0, 1]], [[0, 0], [10, 0], [10, 10], [0, 10], [0, 0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #2', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-2, -1]], [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('control #5', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [4, -2]], [[100.0, 202.5], [100.0, 203.75], [105.0, 203.75], [105.0, 202.5], [100.0, 202.5], [105.0, 202.5]]), ('control #8', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [-2, -1]], [[0, 0], [0, 10], [10, 10], [10, 0], [0, 0]]), ('control #9', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [2, 3, -1]], [[10, 10], [15, 10], [15, 0], [10, 0], [10, 0], [0, 0]]), ('control #10', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [1, 4]], [[10, 10], [0, 10], [0, 0], [0, 15], [10, 15], [10, 10]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #3', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [2, 3, -1]], [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]]), ('control #8', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [-2, -1]], [[0, 0], [0, 10], [10, 10], [10, 0], [0, 0]]), ('regression #11', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [2.0, 3.0, -5.0, 7.0], [0, -3, -4]], [[-5.0, 7.0], [15.0, 7.0], [15.0, 37.0], [25.0, 37.0], [15.0, 37.0], [25.0, 7.0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('boundary #13', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [-1]], [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]]), ('regression #14', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [1.0, 1.0, 0.0, 0.0], [-5, 0]], [[10.0, 10.0], [10.0, 15.0], [0.0, 15.0], [0.0, 10.0], [10.0, 0.0], [10.0, 10.0]]), ('control #15', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.1, 0.1, -1.0, 2.0], [3, -3, 1]], [[0.5, 2.0], [0.0, 2.0], [0.5, 3.0], [0.0, 3.0], [-1.0, 3.0], [-1.0, 2.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]])], [('control #0', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, 1]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]]), ('control #4', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0, -3, -4]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]]), ('control #9', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], None, [2, 3, -1]], [[10, 10], [15, 10], [15, 0], [10, 0], [10, 0], [0, 0]]), ('boundary #12', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.5, 0.25, 100.0, 200.0], [0]], [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]]), ('regression #14', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [1.0, 1.0, 0.0, 0.0], [-5, 0]], [[10.0, 10.0], [10.0, 15.0], [0.0, 15.0], [0.0, 10.0], [10.0, 0.0], [10.0, 10.0]]), ('control #15', [[[[0, 0], [10, 0], [0, 10]], [[10, 10], [-10, 0], [0, -10]], [[10, 10], [5, 0], [0, -10]], [[15, 0], [-5, 0]], [[0, 10], [0, 5], [10, 0], [0, -5]]], [0.1, 0.1, -1.0, 2.0], [3, -3, 1]], [[0.5, 2.0], [0.0, 2.0], [0.5, 3.0], [0.0, 3.0], [-1.0, 3.0], [-1.0, 2.0]]), ('regression #16', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [0]], [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]]), ('regression #17', [[[[3, 4], [2, 0], [0, 2], [-2, -2]]], [1.0, 2.0, 0.0, 0.0], [-1]], [[3.0, 8.0], [5.0, 12.0], [5.0, 8.0], [3.0, 8.0]])]]\nfor label, args, expected in fixtures[N-1]:\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":"Stipulated deterministic toy contract on a bounded input domain; results are rounded as stated and no conformance with any published standard or library is claimed. 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-gis-polygon-topology-topojson-arc-rings-junction-de-duplication","generated_at":"2026-09-29T14:48:21.205186+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Shared-boundary topology formats store each border once; decoding errors break rings, reverse borders or duplicate junction vertices.","repair":"At the junction de-duplication step restore `if out:         pts = pts[1:]`, leaving the rest of the model unchanged.","root_cause":"Subsequent arcs drop their last position instead of the first, which duplicates the previous arc end.","sha256":"677fe3cfd246c17e8f564834b3ab012e74e5817ca4e5258ede3ca1571b258165","title":"TopoJSON arc stitching into rings: junction de-duplication · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":42.37,"exit_code":1,"observations":[{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"check":"control #0","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"passed":true},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"check":"control #1","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"passed":true},{"actual":[[100.0,200.0],[100.0,202.5],[105.0,202.5],[105.0,202.5],[105.0,200.0],[100.0,200.0]],"check":"control #2","expected":[[100.0,200.0],[100.0,202.5],[105.0,202.5],[105.0,200.0],[100.0,200.0]],"passed":false},{"actual":[[105.0,202.5],[107.5,202.5],[107.5,200.0],[105.0,200.0],[105.0,202.5],[105.0,200.0],[100.0,200.0]],"check":"control #3","expected":[[105.0,202.5],[107.5,202.5],[107.5,200.0],[105.0,200.0],[105.0,200.0],[100.0,200.0]],"passed":false},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[107.5,200.0],[107.5,202.5],[105.0,202.5],[105.0,200.0],[107.5,200.0]],"check":"control #4","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[107.5,202.5],[105.0,202.5],[107.5,200.0]],"passed":false},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5]],"check":"boundary #12","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5]],"passed":true},{"actual":[[105.0,202.5],[105.0,200.0],[100.0,200.0]],"check":"boundary #13","expected":[[105.0,202.5],[105.0,200.0],[100.0,200.0]],"passed":true},{"actual":[[3.0,8.0],[5.0,8.0],[5.0,12.0],[3.0,8.0]],"check":"regression #16","expected":[[3.0,8.0],[5.0,8.0],[5.0,12.0],[3.0,8.0]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"control #0\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"passed\": true}, {\"check\": \"control #1\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"passed\": true}, {\"check\": \"control #2\", \"actual\": [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"expected\": [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"passed\": false}, {\"check\": \"control #3\", \"actual\": [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"expected\": [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]], \"passed\": false}, {\"check\": \"control #4\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 200.0], [107.5, 202.5], [105.0, 202.5], [105.0, 200.0], [107.5, 200.0]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]], \"passed\": false}, {\"check\": \"boundary #12\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]], \"passed\": true}, {\"check\": \"boundary #13\", \"actual\": [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"expected\": [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"passed\": true}, {\"check\": \"regression #16\", \"actual\": [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]], \"expected\": [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]], \"passed\": true}], \"passed\": false}\n"},"broken":{"elapsed_ms":42.107,"exit_code":1,"observations":[{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[105.0,202.5],[100.0,202.5]],"check":"control #0","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"passed":false},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[105.0,202.5],[100.0,202.5]],"check":"control #1","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"passed":false},{"actual":[[100.0,200.0],[100.0,202.5],[105.0,202.5],[105.0,202.5],[105.0,200.0]],"check":"control #2","expected":[[100.0,200.0],[100.0,202.5],[105.0,202.5],[105.0,200.0],[100.0,200.0]],"passed":false},{"actual":[[105.0,202.5],[107.5,202.5],[107.5,200.0],[107.5,200.0],[105.0,202.5],[105.0,200.0]],"check":"control #3","expected":[[105.0,202.5],[107.5,202.5],[107.5,200.0],[105.0,200.0],[105.0,200.0],[100.0,200.0]],"passed":false},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[107.5,200.0],[107.5,202.5],[105.0,200.0]],"check":"control #4","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[107.5,202.5],[105.0,202.5],[107.5,200.0]],"passed":false},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5]],"check":"boundary #12","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5]],"passed":true},{"actual":[[105.0,202.5],[105.0,200.0],[100.0,200.0]],"check":"boundary #13","expected":[[105.0,202.5],[105.0,200.0],[100.0,200.0]],"passed":true},{"actual":[[3.0,8.0],[5.0,8.0],[5.0,12.0],[3.0,8.0]],"check":"regression #16","expected":[[3.0,8.0],[5.0,8.0],[5.0,12.0],[3.0,8.0]],"passed":true}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"control #0\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [105.0, 202.5], [100.0, 202.5]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"passed\": false}, {\"check\": \"control #1\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [105.0, 202.5], [100.0, 202.5]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"passed\": false}, {\"check\": \"control #2\", \"actual\": [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 202.5], [105.0, 200.0]], \"expected\": [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"passed\": false}, {\"check\": \"control #3\", \"actual\": [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [107.5, 200.0], [105.0, 202.5], [105.0, 200.0]], \"expected\": [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]], \"passed\": false}, {\"check\": \"control #4\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 200.0], [107.5, 202.5], [105.0, 200.0]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]], \"passed\": false}, {\"check\": \"boundary #12\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]], \"passed\": true}, {\"check\": \"boundary #13\", \"actual\": [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"expected\": [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"passed\": true}, {\"check\": \"regression #16\", \"actual\": [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]], \"expected\": [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]], \"passed\": true}], \"passed\": false}\n"},"fixed":{"elapsed_ms":39.07,"exit_code":0,"observations":[{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"check":"control #0","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"passed":true},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"check":"control #1","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[100.0,202.5],[100.0,200.0]],"passed":true},{"actual":[[100.0,200.0],[100.0,202.5],[105.0,202.5],[105.0,200.0],[100.0,200.0]],"check":"control #2","expected":[[100.0,200.0],[100.0,202.5],[105.0,202.5],[105.0,200.0],[100.0,200.0]],"passed":true},{"actual":[[105.0,202.5],[107.5,202.5],[107.5,200.0],[105.0,200.0],[105.0,200.0],[100.0,200.0]],"check":"control #3","expected":[[105.0,202.5],[107.5,202.5],[107.5,200.0],[105.0,200.0],[105.0,200.0],[100.0,200.0]],"passed":true},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[107.5,202.5],[105.0,202.5],[107.5,200.0]],"check":"control #4","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5],[107.5,202.5],[105.0,202.5],[107.5,200.0]],"passed":true},{"actual":[[100.0,200.0],[105.0,200.0],[105.0,202.5]],"check":"boundary #12","expected":[[100.0,200.0],[105.0,200.0],[105.0,202.5]],"passed":true},{"actual":[[105.0,202.5],[105.0,200.0],[100.0,200.0]],"check":"boundary #13","expected":[[105.0,202.5],[105.0,200.0],[100.0,200.0]],"passed":true},{"actual":[[3.0,8.0],[5.0,8.0],[5.0,12.0],[3.0,8.0]],"check":"regression #16","expected":[[3.0,8.0],[5.0,8.0],[5.0,12.0],[3.0,8.0]],"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"control #0\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"passed\": true}, {\"check\": \"control #1\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [100.0, 202.5], [100.0, 200.0]], \"passed\": true}, {\"check\": \"control #2\", \"actual\": [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"expected\": [[100.0, 200.0], [100.0, 202.5], [105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"passed\": true}, {\"check\": \"control #3\", \"actual\": [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]], \"expected\": [[105.0, 202.5], [107.5, 202.5], [107.5, 200.0], [105.0, 200.0], [105.0, 200.0], [100.0, 200.0]], \"passed\": true}, {\"check\": \"control #4\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5], [107.5, 202.5], [105.0, 202.5], [107.5, 200.0]], \"passed\": true}, {\"check\": \"boundary #12\", \"actual\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]], \"expected\": [[100.0, 200.0], [105.0, 200.0], [105.0, 202.5]], \"passed\": true}, {\"check\": \"boundary #13\", \"actual\": [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"expected\": [[105.0, 202.5], [105.0, 200.0], [100.0, 200.0]], \"passed\": true}, {\"check\": \"regression #16\", \"actual\": [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]], \"expected\": [[3.0, 8.0], [5.0, 8.0], [5.0, 12.0], [3.0, 8.0]], \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}