FA-8666 / Client navigation / Open access
Navigation active-link matching: Case-insensitive navigation still compares raw case · case 01
Case-insensitive navigation still compares raw case.
ROOT CAUSE
The case operation uses `if False:` where the contract requires `if not case_sensitive:`.
VERIFIED REPAIR
Implement the case operation as `if not case_sensitive:`.
Unsuccessful approach: Always folding incorrectly activates case-sensitive links.
Case contract
Ignore URL query and fragment; normalize trailing slashes with root preserved; honor case policy; section matches require a slash boundary and root matches exactly.
Why this case matters
A deterministic model of navigation active-link matching; this isolates one interface invariant without requiring a browser.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(path, link, exact, case_sensitive):
path = path.split('?', 1)[0].split('#', 1)[0]
link = link.rstrip('/') or '/'
path = path.rstrip('/') or '/'
if False: path, link = path.casefold(), link.casefold()
if exact or link == '/': return path == link
return path == link or path.startswith(link + '/')
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('query', solve('/docs?x=1', '/docs', True, True), True)
check('fragment', solve('/docs#intro', '/docs', True, True), True)
check('slash', solve('/docs', '/docs/', True, True), True)
check('root', solve('/docs', '/', False, True), False)
check('root itself', solve('/', '/', True, True), True)
check('fold', solve("/DOCS", "/docs", True, False), True)
check('sensitive', solve("/DOCS", "/docs", True, True), False)
check('child', solve('/docs/a', '/docs', False, True), True)
check('prefix sibling', solve('/docstring', '/docs', False, True), False)
check('parameterized route segment', solve('/section'+str(N)+'/child','/section'+str(N),False,True), True)
for repetition in range(N):
check('repeat prefix sibling', solve('/docstring', '/docs', False, True), False)
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 |
|---|---|---|---|
| query | True | True | Passed |
| fragment | True | True | Passed |
| slash | True | True | Passed |
| root | False | False | Passed |
| root itself | True | True | Passed |
| fold | False | True | Failed |
| sensitive | False | False | Passed |
| child | True | True | Passed |
| prefix sibling | False | False | Passed |
| parameterized route segment | True | True | Passed |
| repeat prefix sibling | False | False | Passed |
SHA-256 / 2c714859774522b03814aece423232a713f5f9d2645be54641ca335fadb01a05
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(path, link, exact, case_sensitive):
path = path.split('?', 1)[0].split('#', 1)[0]
link = link.rstrip('/') or '/'
path = path.rstrip('/') or '/'
if True: path, link = path.casefold(), link.casefold()
if exact or link == '/': return path == link
return path == link or path.startswith(link + '/')
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('query', solve('/docs?x=1', '/docs', True, True), True)
check('fragment', solve('/docs#intro', '/docs', True, True), True)
check('slash', solve('/docs', '/docs/', True, True), True)
check('root', solve('/docs', '/', False, True), False)
check('root itself', solve('/', '/', True, True), True)
check('fold', solve("/DOCS", "/docs", True, False), True)
check('sensitive', solve("/DOCS", "/docs", True, True), False)
check('child', solve('/docs/a', '/docs', False, True), True)
check('prefix sibling', solve('/docstring', '/docs', False, True), False)
check('parameterized route segment', solve('/section'+str(N)+'/child','/section'+str(N),False,True), True)
for repetition in range(N):
check('repeat prefix sibling', solve('/docstring', '/docs', False, True), False)
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 |
|---|---|---|---|
| query | True | True | Passed |
| fragment | True | True | Passed |
| slash | True | True | Passed |
| root | False | False | Passed |
| root itself | True | True | Passed |
| fold | True | True | Passed |
| sensitive | True | False | Failed |
| child | True | True | Passed |
| prefix sibling | False | False | Passed |
| parameterized route segment | True | True | Passed |
| repeat prefix sibling | False | False | Passed |
SHA-256 / 38d0d1045183ae4b36ff052d18b4c6021e54ef68deb88ba7a0a3c61b19ee44db
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
N = 1
observations = []
def solve(path, link, exact, case_sensitive):
path = path.split('?', 1)[0].split('#', 1)[0]
link = link.rstrip('/') or '/'
path = path.rstrip('/') or '/'
if not case_sensitive: path, link = path.casefold(), link.casefold()
if exact or link == '/': return path == link
return path == link or path.startswith(link + '/')
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('query', solve('/docs?x=1', '/docs', True, True), True)
check('fragment', solve('/docs#intro', '/docs', True, True), True)
check('slash', solve('/docs', '/docs/', True, True), True)
check('root', solve('/docs', '/', False, True), False)
check('root itself', solve('/', '/', True, True), True)
check('fold', solve("/DOCS", "/docs", True, False), True)
check('sensitive', solve("/DOCS", "/docs", True, True), False)
check('child', solve('/docs/a', '/docs', False, True), True)
check('prefix sibling', solve('/docstring', '/docs', False, True), False)
check('parameterized route segment', solve('/section'+str(N)+'/child','/section'+str(N),False,True), True)
for repetition in range(N):
check('repeat prefix sibling', solve('/docstring', '/docs', False, True), False)
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 |
|---|---|---|---|
| query | True | True | Passed |
| fragment | True | True | Passed |
| slash | True | True | Passed |
| root | False | False | Passed |
| root itself | True | True | Passed |
| fold | True | True | Passed |
| sensitive | False | False | Passed |
| child | True | True | Passed |
| prefix sibling | False | False | Passed |
| parameterized route segment | True | True | Passed |
| repeat prefix sibling | False | False | Passed |
SHA-256 / 5f4fba5b804be1fd36d31301a615d617455f49d9f15a48c72b61e31b818c9a6b
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:38:23.314179+00:00.
Case digest / ff50d612799c7b172ac5303f43f1e8498a2b3c09ed97356a212aaf7de161c124