FA-7421 / DNS resolution / Open access
Dns server retry excludes already failed servers · case 01
Dns server retry excludes already failed servers.
ROOT CAUSE
The faulty implementation uses `servers` for the dns-server-retry-excludes-already-failed-servers decision.
VERIFIED REPAIR
Apply the explicit dns-server-retry-excludes-already-failed-servers contract, including the tested boundary and negative cases.
Unsuccessful approach: The attempted repair uses `[s for s in servers if not any(f[0] == s for f in failures)]` and still violates a separate fixture.
Case contract
Given servers, failures, transport, dns server retry excludes already failed servers. Return the protocol decision or transformed value; fields are validated and fixtures state boundary outcomes.
Why this case matters
This deterministic dns resolution model isolates the dns-server-retry-excludes-already-failed-servers 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(servers, failures, transport):
return servers
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
_fixtures = ["check('fixture 1', solve(['a', 'b'], [('a', 'udp')], 'udp'), ['b'])", "check('fixture 2', solve(['a'], [('a', 'udp')], 'tcp'), ['a'])", "check('fixture 3', solve([], [], 'udp'), [])", "check('fixture 4', solve(['a'], [], 'udp'), ['a'])"]
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| fixture 2 | ['a'] | ['a'] | Passed |
| fixture 3 | [] | [] | Passed |
| fixture 4 | ['a'] | ['a'] | Passed |
| fixture 1 | ['a', 'b'] | ['b'] | Failed |
SHA-256 / aad6913a3a28384fba164de656dcdf83f072063ceb6866bb122b38e18ab2bb07
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(servers, failures, transport):
return [s for s in servers if not any(f[0] == s for f in failures)]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
_fixtures = ["check('fixture 1', solve(['a', 'b'], [('a', 'udp')], 'udp'), ['b'])", "check('fixture 2', solve(['a'], [('a', 'udp')], 'tcp'), ['a'])", "check('fixture 3', solve([], [], 'udp'), [])", "check('fixture 4', solve(['a'], [], 'udp'), ['a'])"]
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| fixture 2 | [] | ['a'] | Failed |
| fixture 3 | [] | [] | Passed |
| fixture 4 | ['a'] | ['a'] | Passed |
| fixture 1 | ['b'] | ['b'] | Passed |
SHA-256 / 5ad2c4af502534b6e66a1be73ed89fa5db6356ad1cfe6fdc3463a298da4d68f9
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(servers, failures, transport):
return [s for s in servers if (s,transport) not in failures]
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
_fixtures = ["check('fixture 1', solve(['a', 'b'], [('a', 'udp')], 'udp'), ['b'])", "check('fixture 2', solve(['a'], [('a', 'udp')], 'tcp'), ['a'])", "check('fixture 3', solve([], [], 'udp'), [])", "check('fixture 4', solve(['a'], [], 'udp'), ['a'])"]
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 fixture | Actual | Expected | Outcome |
|---|---|---|---|
| fixture 2 | ['a'] | ['a'] | Passed |
| fixture 3 | [] | [] | Passed |
| fixture 4 | ['a'] | ['a'] | Passed |
| fixture 1 | ['b'] | ['b'] | Passed |
SHA-256 / f4d421d160f26f883c019afadc8a2a03b75b02a7f9e2e138a0e0e433a53b4d92
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:11.774495+00:00.
Case digest / f49cb2c03414eeb8eb489fe158c263f8db877699acafe171478a0b7ca8fa68d6