FAILURE MAP
← Case archive

FA-6811 / HTTP caching / Open access

If unmodified since is ignored when if match present · case 01

If unmodified since is ignored when if match present.

Verified by executionVariant 1 · 4 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

The faulty implementation uses `tag_ok and (since is None or modified <= since)` for the if-unmodified-since-is-ignored-when-if-match-present decision.

VERIFIED REPAIR

Apply the explicit if-unmodified-since-is-ignored-when-if-match-present contract, including the tested boundary and negative cases.

Unsuccessful approach: The attempted repair uses `tag_ok if has_match else since is None or modified < since` and still violates a separate fixture.

Case contract

Given has_match, tag_ok, modified, since, if unmodified since is ignored when if match present. Return the protocol decision or transformed value; fields are validated and fixtures state boundary outcomes.

Why this case matters

This deterministic http caching model isolates the if-unmodified-since-is-ignored-when-if-match-present policy at a network component boundary.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import ipaddress
import re
from urllib.parse import urlsplit, urljoin
N = 1
observations = []
def solve(has_match, tag_ok, modified, since):
    return tag_ok and (since is None or modified <= since)
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
_fixtures = ["check('fixture 1', solve(True, True, 20, 10), True)", "check('fixture 2', solve(True, False, 0, 10), False)", "check('fixture 3', solve(False, False, 10, 10), True)", "check('fixture 4', solve(False, False, 20, None), True)"]
for _line in _fixtures[N % len(_fixtures):] + _fixtures[:N % len(_fixtures)]:
    exec(_line)
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 fixtureActualExpectedOutcome
fixture 2FalseFalsePassed
fixture 3FalseTrueFailed
fixture 4FalseTrueFailed
fixture 1FalseTrueFailed

SHA-256 / 58db0310e48c61cfcf5f704b6df71851850ed9463e371b6bb4a970c81c701634

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import ipaddress
import re
from urllib.parse import urlsplit, urljoin
N = 1
observations = []
def solve(has_match, tag_ok, modified, since):
    return tag_ok if has_match else since is None or modified < since
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
_fixtures = ["check('fixture 1', solve(True, True, 20, 10), True)", "check('fixture 2', solve(True, False, 0, 10), False)", "check('fixture 3', solve(False, False, 10, 10), True)", "check('fixture 4', solve(False, False, 20, None), True)"]
for _line in _fixtures[N % len(_fixtures):] + _fixtures[:N % len(_fixtures)]:
    exec(_line)
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 fixtureActualExpectedOutcome
fixture 2FalseFalsePassed
fixture 3FalseTrueFailed
fixture 4TrueTruePassed
fixture 1TrueTruePassed

SHA-256 / 3bf9c6a11494c3d4ffde9ab973d75f86f42ff88fc5b508908e2ef4a4f8116245

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json
import ipaddress
import re
from urllib.parse import urlsplit, urljoin
N = 1
observations = []
def solve(has_match, tag_ok, modified, since):
    return tag_ok if has_match else since is None or modified <= since
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
_fixtures = ["check('fixture 1', solve(True, True, 20, 10), True)", "check('fixture 2', solve(True, False, 0, 10), False)", "check('fixture 3', solve(False, False, 10, 10), True)", "check('fixture 4', solve(False, False, 20, None), True)"]
for _line in _fixtures[N % len(_fixtures):] + _fixtures[:N % len(_fixtures)]:
    exec(_line)
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 fixtureActualExpectedOutcome
fixture 2FalseFalsePassed
fixture 3TrueTruePassed
fixture 4TrueTruePassed
fixture 1TrueTruePassed

SHA-256 / c53acbfa3443f74b97f6b3320b9e089e4f966dfff580a089cb2e2d8c4d2cc193

Verification & scope

Bounded deterministic policy model over validated inputs; not a complete protocol stack or an interoperability claim. The five variants rotate the same explicit fixture set. 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:38:05.487399+00:00.

Case digest / 550925707ebdd026565c212dd62671a90f047262ad3d980dbd4b2fa633c35136