FA-5016 / Descriptor lookup / Open access
Getattr fallback: Looks only in the instance dictionary and skips class descriptors · case 01
Looks only in the instance dictionary and skips class descriptors and changes the required Python-language result.
ROOT CAUSE
Looks only in the instance dictionary and skips class descriptors. The executable reproducer isolates this operation from the rest of the contract.
THE FAILURE
Looks only in the instance dictionary and skips class descriptors. The executable reproducer isolates this operation from the rest of the contract.
Unsuccessful approach: The alternative still fails because it changes an AttributeError getter into ValueError so fallback no longer runs.
Case contract
Read attributes normally: instance attributes override plain class values; __getattr__ supplies missing:name only after AttributeError, including AttributeError from a property getter. Inputs use the finite Python types shown in the fixtures. An error string denotes the specified caught exception, not an unhandled process failure.
Why this case matters
Runs Python standard-library language operations in a deterministic local reproducer. Literal expected answers are authored independently. Related defects share an evaluation group to avoid benchmark split leakage.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(values, names):
class C:
present='class-value'
@property
def trouble(self):
raise AttributeError('getter failed')
def __getattr__(self,name):
return 'missing:'+name
c=C(); c.__dict__.update(values)
out=[]
for name in names:
try: out.append(c.__dict__.get(name,'missing:'+name))
except Exception as exc: out.append(type(exc).__name__)
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('existing class and missing', solve({}, ['present', 'other']), ['class-value', 'missing:other'])
check('instance override', solve({'present': 0}, ['present']), [0])
check('property AttributeError falls back', solve({}, ['trouble']), ['missing:trouble'])
check('stored None is present', solve({'other': None}, ['other', 'absent']), [None, 'missing:absent'])
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 |
|---|---|---|---|
| existing class and missing | ['missing:present', 'missing:other'] | ['class-value', 'missing:other'] | Failed |
| instance override | [0] | [0] | Passed |
| property AttributeError falls back | ['missing:trouble'] | ['missing:trouble'] | Passed |
| stored None is present | [None, 'missing:absent'] | [None, 'missing:absent'] | Passed |
SHA-256 / bfdd0b2d3dd326d09990a074b7d9da76e6d866141fd4b4a72274ec7c92d37dc7
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(values, names):
class C:
present='class-value'
@property
def trouble(self):
raise ValueError('getter failed')
def __getattr__(self,name):
return 'missing:'+name
c=C(); c.__dict__.update(values)
out=[]
for name in names:
try: out.append(getattr(c,name))
except Exception as exc: out.append(type(exc).__name__)
return out
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('existing class and missing', solve({}, ['present', 'other']), ['class-value', 'missing:other'])
check('instance override', solve({'present': 0}, ['present']), [0])
check('property AttributeError falls back', solve({}, ['trouble']), ['missing:trouble'])
check('stored None is present', solve({'other': None}, ['other', 'absent']), [None, 'missing:absent'])
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 |
|---|---|---|---|
| existing class and missing | ['class-value', 'missing:other'] | ['class-value', 'missing:other'] | Passed |
| instance override | [0] | [0] | Passed |
| property AttributeError falls back | ['ValueError'] | ['missing:trouble'] | Failed |
| stored None is present | [None, 'missing:absent'] | [None, 'missing:absent'] | Passed |
SHA-256 / 6861819fa2c91f44e8872a444b252c884117233c51a0cee14d0c83cdf3b5be1e
HELD IN THE MEMBER ARCHIVE
The verified repair and its recorded checks are member-only.
This mechanism has 4 recorded checks per implementation. The open-access tier publishes the failure and the unsuccessful fix; the repaired source that passes every check, and the observations that prove it, are available to members.
Every case sharing this mechanism uses the same contract and the same repair, so this one record is held back for all of them.
Member access is invitation-based. Sign in with your invited account to inspect the repair.
Sign in to the archive ↗Verification & scope
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:37:45.219247+00:00.
Case digest / 15fee0935af141735a563294b7a6d4708f19a7164d20872c1a7b2cefe2f693e8