FAILURE MAP
← Case archive

FA-21896 / Autocomplete interactions / Open access

Suggestion request context: outgoing search is tagged with the next unissued epoch · case 01

The epoch completion transition produces an incorrect observable state.

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

ROOT CAUSE

At request-context/epoch, the implementation evaluates `d['epoch']+1` instead of preserving the specified completion transition.

THE FAILURE

At request-context/epoch, the implementation evaluates `d['epoch']+1` instead of preserving the specified completion transition.

Unsuccessful approach: The attempted repair uses `d['epoch']-1`, which still violates a normal or boundary completion fixture.

Case contract

A suggestion request is bound to draft, field identity, selection range, locale and dependency scope. Each outgoing descriptor carries those values from the initiating snapshot; accepting a response requires the same query epoch and field instance. No transport behavior is modeled.

Why this case matters

Autocomplete couples draft text, suggestion identity and asynchronous presentation; this bounded lifecycle model isolates one observable interaction defect.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(event, d):
    if event == 'query': return {'text':d['query']}
    if event == 'epoch': return d['epoch']+1
    if event == 'field': return d['field']
    if event == 'instance': return d['instance']
    if event == 'locale': return d['locale']
    if event == 'scope': return d['scope']
    if event == 'range': return [d['start'],d['end']]
    if event == 'exclusions': return d['selected']
    if event == 'limit': return d['limit']
    if event == 'accept': return d['response_epoch']==d['epoch'] and d['response_field']==d['field']
    return {'unchanged': True}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
normal = {'query':'pear','epoch':N,'field':'billing','instance':N+2,'locale':'fr','scope':'fruit','start':1,'end':3,'selected':['p1'],'limit':7,'response_epoch':N-1,'response_field':'shipping'}
boundary = {'query':'','epoch':N,'field':'billing','instance':N,'locale':'en','scope':'all','start':0,'end':0,'selected':[],'limit':0,'response_epoch':N,'response_field':'billing'}
check('normal query', solve('query', normal), {'text':'pear'})
check('boundary query', solve('query', boundary), {'text':''})
check('normal epoch', solve('epoch', normal), N)
check('boundary epoch', solve('epoch', boundary), N)
check('normal field', solve('field', normal), 'billing')
check('boundary field', solve('field', boundary), 'billing')
check('normal instance', solve('instance', normal), N+2)
check('boundary instance', solve('instance', boundary), N)
check('normal locale', solve('locale', normal), 'fr')
check('boundary locale', solve('locale', boundary), 'en')
check('normal scope', solve('scope', normal), 'fruit')
check('boundary scope', solve('scope', boundary), 'all')
check('normal range', solve('range', normal), [1,3])
check('boundary range', solve('range', boundary), [0,0])
check('normal exclusions', solve('exclusions', normal), ['p1'])
check('boundary exclusions', solve('exclusions', boundary), [])
check('normal limit', solve('limit', normal), 7)
check('boundary limit', solve('limit', boundary), 0)
check('normal accept', solve('accept', normal), False)
check('boundary accept', solve('accept', boundary), True)
variant = dict(normal, **{'query':'q'*N})
check('variant query or selection payload', solve('query', variant), {'text':'q'*N})
check('unknown completion event', solve('unrecognized', normal), {'unchanged': True})
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
normal query{'text': 'pear'}{'text': 'pear'}Passed
boundary query{'text': ''}{'text': ''}Passed
normal epoch21Failed
boundary epoch21Failed
normal fieldbillingbillingPassed
boundary fieldbillingbillingPassed
normal instance33Passed
boundary instance11Passed
normal localefrfrPassed
boundary localeenenPassed
normal scopefruitfruitPassed
boundary scopeallallPassed
normal range[1, 3][1, 3]Passed
boundary range[0, 0][0, 0]Passed
normal exclusions['p1']['p1']Passed
boundary exclusions[][]Passed
normal limit77Passed
boundary limit00Passed
normal acceptFalseFalsePassed
boundary acceptTrueTruePassed
variant query or selection payload{'text': 'q'}{'text': 'q'}Passed
unknown completion event{'unchanged': True}{'unchanged': True}Passed

SHA-256 / 921cf4ef057067da6f06b075b7852704eeeeac9f56d939460d36db603353b301

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(event, d):
    if event == 'query': return {'text':d['query']}
    if event == 'epoch': return d['epoch']-1
    if event == 'field': return d['field']
    if event == 'instance': return d['instance']
    if event == 'locale': return d['locale']
    if event == 'scope': return d['scope']
    if event == 'range': return [d['start'],d['end']]
    if event == 'exclusions': return d['selected']
    if event == 'limit': return d['limit']
    if event == 'accept': return d['response_epoch']==d['epoch'] and d['response_field']==d['field']
    return {'unchanged': True}
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
normal = {'query':'pear','epoch':N,'field':'billing','instance':N+2,'locale':'fr','scope':'fruit','start':1,'end':3,'selected':['p1'],'limit':7,'response_epoch':N-1,'response_field':'shipping'}
boundary = {'query':'','epoch':N,'field':'billing','instance':N,'locale':'en','scope':'all','start':0,'end':0,'selected':[],'limit':0,'response_epoch':N,'response_field':'billing'}
check('normal query', solve('query', normal), {'text':'pear'})
check('boundary query', solve('query', boundary), {'text':''})
check('normal epoch', solve('epoch', normal), N)
check('boundary epoch', solve('epoch', boundary), N)
check('normal field', solve('field', normal), 'billing')
check('boundary field', solve('field', boundary), 'billing')
check('normal instance', solve('instance', normal), N+2)
check('boundary instance', solve('instance', boundary), N)
check('normal locale', solve('locale', normal), 'fr')
check('boundary locale', solve('locale', boundary), 'en')
check('normal scope', solve('scope', normal), 'fruit')
check('boundary scope', solve('scope', boundary), 'all')
check('normal range', solve('range', normal), [1,3])
check('boundary range', solve('range', boundary), [0,0])
check('normal exclusions', solve('exclusions', normal), ['p1'])
check('boundary exclusions', solve('exclusions', boundary), [])
check('normal limit', solve('limit', normal), 7)
check('boundary limit', solve('limit', boundary), 0)
check('normal accept', solve('accept', normal), False)
check('boundary accept', solve('accept', boundary), True)
variant = dict(normal, **{'query':'q'*N})
check('variant query or selection payload', solve('query', variant), {'text':'q'*N})
check('unknown completion event', solve('unrecognized', normal), {'unchanged': True})
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
normal query{'text': 'pear'}{'text': 'pear'}Passed
boundary query{'text': ''}{'text': ''}Passed
normal epoch01Failed
boundary epoch01Failed
normal fieldbillingbillingPassed
boundary fieldbillingbillingPassed
normal instance33Passed
boundary instance11Passed
normal localefrfrPassed
boundary localeenenPassed
normal scopefruitfruitPassed
boundary scopeallallPassed
normal range[1, 3][1, 3]Passed
boundary range[0, 0][0, 0]Passed
normal exclusions['p1']['p1']Passed
boundary exclusions[][]Passed
normal limit77Passed
boundary limit00Passed
normal acceptFalseFalsePassed
boundary acceptTrueTruePassed
variant query or selection payload{'text': 'q'}{'text': 'q'}Passed
unknown completion event{'unchanged': True}{'unchanged': True}Passed

SHA-256 / 794c6cf23de0fe69bc3603aaaadb8319786f1fcfdf0dae46a909caf3775d070b

HELD IN THE MEMBER ARCHIVE

The verified repair and its recorded checks are member-only.

This mechanism has 22 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

Stipulated deterministic widget transition model; inputs are validated snapshots. It does not model browser event dispatch, network transport, or linguistic standards. 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:40:33.632794+00:00.

Case digest / f24c1d11294b1babb4c4ea715e5891d622dca02bc3d75d21e100c26883ad04f3