{"abstract":"An instant just before the Unix epoch is assigned to second zero, or rounding moves a positive fraction into a later second.","category":"Time representation","checks":7,"contract":"Convert an integer count of milliseconds since the Unix epoch to the integer second s satisfying 1000*s <= milliseconds < 1000*(s+1). Do not round to the nearest second and do not pass through floating point.","evaluation_group":"model-657b07e0946b06cd","failed_approach":"Nearest rounding corrects some negative fractions but changes the containing second for values beyond a midpoint.","family":"time-negative-epoch-floor","id":"FA-296","implementations":{"attempt":{"sha256":"8ea7d7cc5f527b99ee94c8291c2515b136bea470dff2f202448943480a63e3da","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(milliseconds):\n    return round(milliseconds / 1000)\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('negative fractional second', solve(-1000 * N - 1), -N - 1)\ncheck('negative fraction close to next boundary', solve(-1000 * N + 1), -N)\ncheck('positive late fraction stays in containing second', solve(1000 * N + 999), N)\ncheck('exact negative second', solve(-1000 * N), -N)\ncheck('exact positive second', solve(1000 * N), N)\ncheck('epoch itself', solve(0), 0)\ncheck('large timestamp retains integer precision', solve((2 ** 60 + N) * 1000 + 999), 2 ** 60 + N)\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":"abbf59ad6a730602409aee204482de869cd7cbe337af7fb1bcd6538dc7f4690f","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(milliseconds):\n    return int(milliseconds / 1000)\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('negative fractional second', solve(-1000 * N - 1), -N - 1)\ncheck('negative fraction close to next boundary', solve(-1000 * N + 1), -N)\ncheck('positive late fraction stays in containing second', solve(1000 * N + 999), N)\ncheck('exact negative second', solve(-1000 * N), -N)\ncheck('exact positive second', solve(1000 * N), N)\ncheck('epoch itself', solve(0), 0)\ncheck('large timestamp retains integer precision', solve((2 ** 60 + N) * 1000 + 999), 2 ** 60 + N)\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":"60a2509bdc07ca46ada685ef5d312e38aa3057cf1cb4d7e769450a131b9dd607","source":"\"\"\"Failure Map reference implementation. Python standard library only.\"\"\"\nimport json\n\nN = 1\nobservations = []\ndef solve(milliseconds):\n    return milliseconds // 1000\ndef check(label, actual, expected):\n    observations.append({\"check\": label, \"actual\": actual, \"expected\": expected, \"passed\": actual == expected})\ncheck('negative fractional second', solve(-1000 * N - 1), -N - 1)\ncheck('negative fraction close to next boundary', solve(-1000 * N + 1), -N)\ncheck('positive late fraction stays in containing second', solve(1000 * N + 999), N)\ncheck('exact negative second', solve(-1000 * N), -N)\ncheck('exact positive second', solve(1000 * N), N)\ncheck('epoch itself', solve(0), 0)\ncheck('large timestamp retains integer precision', solve((2 ** 60 + N) * 1000 + 999), 2 ** 60 + N)\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":" 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":"time-negative-epoch-floor","generated_at":"2026-09-29T14:36:52.067800+00:00","license":"CC0-1.0","python":"3.12.14","seed":1,"split":"open-access"},"relevance":"Pre-epoch timestamps and high-magnitude archival timestamps reveal a distinction hidden by common positive, whole-second fixtures.","repair":"Use exact integer floor division on the signed millisecond timestamp.","root_cause":"Truncation or nearest rounding is used where the timestamp representation requires the lower containing second.","sha256":"0923354fc1d46db0dc68a7900201efd139ac059a735b3a88ed05c5292284cf67","title":"Truncating a negative epoch fraction selects the next second · case 01","variant":1,"variant_policy":"Five numbered records share a model and may reuse boundary fixtures.","verification":{"attempt":{"elapsed_ms":34.909,"exit_code":1,"observations":[{"actual":-1,"check":"negative fractional second","expected":-2,"passed":false},{"actual":-1,"check":"negative fraction close to next boundary","expected":-1,"passed":true},{"actual":2,"check":"positive late fraction stays in containing second","expected":1,"passed":false},{"actual":-1,"check":"exact negative second","expected":-1,"passed":true},{"actual":1,"check":"exact positive second","expected":1,"passed":true},{"actual":0,"check":"epoch itself","expected":0,"passed":true},{"actual":1152921504606846976,"check":"large timestamp retains integer precision","expected":1152921504606846977,"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"negative fractional second\", \"actual\": -1, \"expected\": -2, \"passed\": false}, {\"check\": \"negative fraction close to next boundary\", \"actual\": -1, \"expected\": -1, \"passed\": true}, {\"check\": \"positive late fraction stays in containing second\", \"actual\": 2, \"expected\": 1, \"passed\": false}, {\"check\": \"exact negative second\", \"actual\": -1, \"expected\": -1, \"passed\": true}, {\"check\": \"exact positive second\", \"actual\": 1, \"expected\": 1, \"passed\": true}, {\"check\": \"epoch itself\", \"actual\": 0, \"expected\": 0, \"passed\": true}, {\"check\": \"large timestamp retains integer precision\", \"actual\": 1152921504606846976, \"expected\": 1152921504606846977, \"passed\": false}], \"passed\": false}\n"},"broken":{"elapsed_ms":34.093,"exit_code":1,"observations":[{"actual":-1,"check":"negative fractional second","expected":-2,"passed":false},{"actual":0,"check":"negative fraction close to next boundary","expected":-1,"passed":false},{"actual":1,"check":"positive late fraction stays in containing second","expected":1,"passed":true},{"actual":-1,"check":"exact negative second","expected":-1,"passed":true},{"actual":1,"check":"exact positive second","expected":1,"passed":true},{"actual":0,"check":"epoch itself","expected":0,"passed":true},{"actual":1152921504606846976,"check":"large timestamp retains integer precision","expected":1152921504606846977,"passed":false}],"passed":false,"stderr":"","stdout":"{\"observations\": [{\"check\": \"negative fractional second\", \"actual\": -1, \"expected\": -2, \"passed\": false}, {\"check\": \"negative fraction close to next boundary\", \"actual\": 0, \"expected\": -1, \"passed\": false}, {\"check\": \"positive late fraction stays in containing second\", \"actual\": 1, \"expected\": 1, \"passed\": true}, {\"check\": \"exact negative second\", \"actual\": -1, \"expected\": -1, \"passed\": true}, {\"check\": \"exact positive second\", \"actual\": 1, \"expected\": 1, \"passed\": true}, {\"check\": \"epoch itself\", \"actual\": 0, \"expected\": 0, \"passed\": true}, {\"check\": \"large timestamp retains integer precision\", \"actual\": 1152921504606846976, \"expected\": 1152921504606846977, \"passed\": false}], \"passed\": false}\n"},"fixed":{"elapsed_ms":35.923,"exit_code":0,"observations":[{"actual":-2,"check":"negative fractional second","expected":-2,"passed":true},{"actual":-1,"check":"negative fraction close to next boundary","expected":-1,"passed":true},{"actual":1,"check":"positive late fraction stays in containing second","expected":1,"passed":true},{"actual":-1,"check":"exact negative second","expected":-1,"passed":true},{"actual":1,"check":"exact positive second","expected":1,"passed":true},{"actual":0,"check":"epoch itself","expected":0,"passed":true},{"actual":1152921504606846977,"check":"large timestamp retains integer precision","expected":1152921504606846977,"passed":true}],"passed":true,"stderr":"","stdout":"{\"observations\": [{\"check\": \"negative fractional second\", \"actual\": -2, \"expected\": -2, \"passed\": true}, {\"check\": \"negative fraction close to next boundary\", \"actual\": -1, \"expected\": -1, \"passed\": true}, {\"check\": \"positive late fraction stays in containing second\", \"actual\": 1, \"expected\": 1, \"passed\": true}, {\"check\": \"exact negative second\", \"actual\": -1, \"expected\": -1, \"passed\": true}, {\"check\": \"exact positive second\", \"actual\": 1, \"expected\": 1, \"passed\": true}, {\"check\": \"epoch itself\", \"actual\": 0, \"expected\": 0, \"passed\": true}, {\"check\": \"large timestamp retains integer precision\", \"actual\": 1152921504606846977, \"expected\": 1152921504606846977, \"passed\": true}], \"passed\": true}\n"}},"verified":true,"visibility":"public"}