FAILURE MAP
← Case archive

FA-97111 / Recipe scaling and nutrition / Open access

Home canning altitude table: dial gauge ceiling · case 01

A dial gauge at 9000 ft is told 14 psi instead of being refused.

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

ROOT CAUSE

The dial gauge reuses the water bath 10000 ft ceiling instead of its 8000 ft table limit.

VERIFIED REPAIR

Refuse dial gauges above 8000 ft.

Unsuccessful approach: Refusing at 10000 ft still answers 8001-9999 ft.

Case contract

Above 10000 ft -> "error: altitude out of range". Water bath adds 0 (<=1000 ft), 5 (<=3000), 10 (<=6000), 15 (<=8000), 20 (<=10000) minutes to base, psi None. Dial gauge keeps base minutes, psi 11 (<=2000), 12 (<=4000), 13 (<=6000), 14 (<=8000), above 8000 error. Weighted gauge keeps base minutes, psi 10 at <=1000 ft else 15. Other methods -> "error: method".

Why this case matters

Preserving recipes must lengthen time or raise pressure at altitude to stay safe (toy table).

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(method, altitude_ft, base_minutes):
    if altitude_ft > 10000:
        return 'error: altitude out of range'
    add = 0 if altitude_ft <= 1000 else 5 if altitude_ft <= 3000 else 10 if altitude_ft <= 6000 else 15 if altitude_ft <= 8000 else 20
    if method == 'water bath':
        return {'minutes': base_minutes + add, 'psi': None}
    if method == 'dial':
        if altitude_ft > 10000:
            return 'error: altitude out of range'
        psi = 11 if altitude_ft <= 2000 else 12 if altitude_ft <= 4000 else 13 if altitude_ft <= 6000 else 14
        return {'minutes': base_minutes, 'psi': psi}
    if method == 'weighted':
        return {'minutes': base_minutes, 'psi': 10 if altitude_ft <= 1000 else 15}
    return 'error: method' 
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['regression: dial gauge ceiling', ['dial', 8500, 25], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 15], 'error: altitude out of range'],
  ['generated control 1', ['steam', 0, 20], 'error: method'],
  ['generated control 2', ['steam', 3000, 85], 'error: method'],
  ['generated control 3', ['water bath', 3000, 40], {'minutes': 45, 'psi': None}]],
 [['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['regression: dial gauge ceiling', ['dial', 8500, 20], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 40], 'error: altitude out of range'],
  ['generated control 1', ['water bath', 3500, 85], {'minutes': 95, 'psi': None}],
  ['generated control 2', ['steam', 10000, 15], 'error: method'],
  ['generated control 3', ['steam', 8500, 20], 'error: method']],
 [['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['unknown method', ['steam', 500, 10], 'error: method'],
  ['regression: dial gauge ceiling', ['dial', 10000, 85], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 15], 'error: altitude out of range'],
  ['generated control 1', ['steam', 4000, 25], 'error: method'],
  ['generated control 2', ['dial', 1001, 40], {'minutes': 40, 'psi': 11}],
  ['generated control 3', ['weighted', 2001, 15], {'minutes': 15, 'psi': 15}]],
 [['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['unknown method', ['steam', 500, 10], 'error: method'],
  ['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['regression: dial gauge ceiling', ['dial', 8500, 85], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 25], 'error: altitude out of range'],
  ['generated control 1', ['dial', 2000, 15], {'minutes': 15, 'psi': 11}],
  ['generated control 2', ['dial', 3500, 25], {'minutes': 25, 'psi': 12}],
  ['generated control 3', ['dial', 2000, 10], {'minutes': 10, 'psi': 11}]],
 [['unknown method', ['steam', 500, 10], 'error: method'],
  ['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['regression: dial gauge ceiling', ['dial', 10000, 20], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 10], 'error: altitude out of range'],
  ['generated control 1', ['dial', 2000, 85], {'minutes': 85, 'psi': 11}],
  ['generated control 2', ['water bath', 4000, 10], {'minutes': 20, 'psi': None}],
  ['generated control 3', ['weighted', 1001, 85], {'minutes': 85, 'psi': 15}]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
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
sea level bath{'minutes': 10, 'psi': None}{'minutes': 10, 'psi': None}Passed
band edge 1000{'minutes': 10, 'psi': None}{'minutes': 10, 'psi': None}Passed
dial mid{'minutes': 25, 'psi': 12}{'minutes': 25, 'psi': 12}Passed
regression: dial gauge ceiling{'minutes': 25, 'psi': 14}error: altitude out of rangeFailed
repair check: dial gauge ceiling{'minutes': 15, 'psi': 14}error: altitude out of rangeFailed
generated control 1error: methoderror: methodPassed
generated control 2error: methoderror: methodPassed
generated control 3{'minutes': 45, 'psi': None}{'minutes': 45, 'psi': None}Passed

SHA-256 / 5c048bfe5f1329c3931866d190b03285c073714a73b08d87ab74692ddee04654

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(method, altitude_ft, base_minutes):
    if altitude_ft > 10000:
        return 'error: altitude out of range'
    add = 0 if altitude_ft <= 1000 else 5 if altitude_ft <= 3000 else 10 if altitude_ft <= 6000 else 15 if altitude_ft <= 8000 else 20
    if method == 'water bath':
        return {'minutes': base_minutes + add, 'psi': None}
    if method == 'dial':
        if altitude_ft >= 10000:
            return 'error: altitude out of range'
        psi = 11 if altitude_ft <= 2000 else 12 if altitude_ft <= 4000 else 13 if altitude_ft <= 6000 else 14
        return {'minutes': base_minutes, 'psi': psi}
    if method == 'weighted':
        return {'minutes': base_minutes, 'psi': 10 if altitude_ft <= 1000 else 15}
    return 'error: method' 
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['regression: dial gauge ceiling', ['dial', 8500, 25], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 15], 'error: altitude out of range'],
  ['generated control 1', ['steam', 0, 20], 'error: method'],
  ['generated control 2', ['steam', 3000, 85], 'error: method'],
  ['generated control 3', ['water bath', 3000, 40], {'minutes': 45, 'psi': None}]],
 [['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['regression: dial gauge ceiling', ['dial', 8500, 20], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 40], 'error: altitude out of range'],
  ['generated control 1', ['water bath', 3500, 85], {'minutes': 95, 'psi': None}],
  ['generated control 2', ['steam', 10000, 15], 'error: method'],
  ['generated control 3', ['steam', 8500, 20], 'error: method']],
 [['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['unknown method', ['steam', 500, 10], 'error: method'],
  ['regression: dial gauge ceiling', ['dial', 10000, 85], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 15], 'error: altitude out of range'],
  ['generated control 1', ['steam', 4000, 25], 'error: method'],
  ['generated control 2', ['dial', 1001, 40], {'minutes': 40, 'psi': 11}],
  ['generated control 3', ['weighted', 2001, 15], {'minutes': 15, 'psi': 15}]],
 [['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['unknown method', ['steam', 500, 10], 'error: method'],
  ['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['regression: dial gauge ceiling', ['dial', 8500, 85], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 25], 'error: altitude out of range'],
  ['generated control 1', ['dial', 2000, 15], {'minutes': 15, 'psi': 11}],
  ['generated control 2', ['dial', 3500, 25], {'minutes': 25, 'psi': 12}],
  ['generated control 3', ['dial', 2000, 10], {'minutes': 10, 'psi': 11}]],
 [['unknown method', ['steam', 500, 10], 'error: method'],
  ['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['regression: dial gauge ceiling', ['dial', 10000, 20], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 10], 'error: altitude out of range'],
  ['generated control 1', ['dial', 2000, 85], {'minutes': 85, 'psi': 11}],
  ['generated control 2', ['water bath', 4000, 10], {'minutes': 20, 'psi': None}],
  ['generated control 3', ['weighted', 1001, 85], {'minutes': 85, 'psi': 15}]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
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
sea level bath{'minutes': 10, 'psi': None}{'minutes': 10, 'psi': None}Passed
band edge 1000{'minutes': 10, 'psi': None}{'minutes': 10, 'psi': None}Passed
dial mid{'minutes': 25, 'psi': 12}{'minutes': 25, 'psi': 12}Passed
regression: dial gauge ceiling{'minutes': 25, 'psi': 14}error: altitude out of rangeFailed
repair check: dial gauge ceiling{'minutes': 15, 'psi': 14}error: altitude out of rangeFailed
generated control 1error: methoderror: methodPassed
generated control 2error: methoderror: methodPassed
generated control 3{'minutes': 45, 'psi': None}{'minutes': 45, 'psi': None}Passed

SHA-256 / 451d606f76779d4c144dc601e47951ec2198fc7a39b68f0946d210f8aa24aa14

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json
import math
from fractions import Fraction
N = 1
observations = []
def solve(method, altitude_ft, base_minutes):
    if altitude_ft > 10000:
        return 'error: altitude out of range'
    add = 0 if altitude_ft <= 1000 else 5 if altitude_ft <= 3000 else 10 if altitude_ft <= 6000 else 15 if altitude_ft <= 8000 else 20
    if method == 'water bath':
        return {'minutes': base_minutes + add, 'psi': None}
    if method == 'dial':
        if altitude_ft > 8000:
            return 'error: altitude out of range'
        psi = 11 if altitude_ft <= 2000 else 12 if altitude_ft <= 4000 else 13 if altitude_ft <= 6000 else 14
        return {'minutes': base_minutes, 'psi': psi}
    if method == 'weighted':
        return {'minutes': base_minutes, 'psi': 10 if altitude_ft <= 1000 else 15}
    return 'error: method' 
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
fixtures = [[['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['regression: dial gauge ceiling', ['dial', 8500, 25], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 15], 'error: altitude out of range'],
  ['generated control 1', ['steam', 0, 20], 'error: method'],
  ['generated control 2', ['steam', 3000, 85], 'error: method'],
  ['generated control 3', ['water bath', 3000, 40], {'minutes': 45, 'psi': None}]],
 [['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['regression: dial gauge ceiling', ['dial', 8500, 20], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 40], 'error: altitude out of range'],
  ['generated control 1', ['water bath', 3500, 85], {'minutes': 95, 'psi': None}],
  ['generated control 2', ['steam', 10000, 15], 'error: method'],
  ['generated control 3', ['steam', 8500, 20], 'error: method']],
 [['dial mid', ['dial', 3000, 25], {'minutes': 25, 'psi': 12}],
  ['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['unknown method', ['steam', 500, 10], 'error: method'],
  ['regression: dial gauge ceiling', ['dial', 10000, 85], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 15], 'error: altitude out of range'],
  ['generated control 1', ['steam', 4000, 25], 'error: method'],
  ['generated control 2', ['dial', 1001, 40], {'minutes': 40, 'psi': 11}],
  ['generated control 3', ['weighted', 2001, 15], {'minutes': 15, 'psi': 15}]],
 [['too high', ['water bath', 10500, 10], 'error: altitude out of range'],
  ['unknown method', ['steam', 500, 10], 'error: method'],
  ['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['regression: dial gauge ceiling', ['dial', 8500, 85], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 25], 'error: altitude out of range'],
  ['generated control 1', ['dial', 2000, 15], {'minutes': 15, 'psi': 11}],
  ['generated control 2', ['dial', 3500, 25], {'minutes': 25, 'psi': 12}],
  ['generated control 3', ['dial', 2000, 10], {'minutes': 10, 'psi': 11}]],
 [['unknown method', ['steam', 500, 10], 'error: method'],
  ['sea level bath', ['water bath', 0, 10], {'minutes': 10, 'psi': None}],
  ['band edge 1000', ['water bath', 1000, 10], {'minutes': 10, 'psi': None}],
  ['regression: dial gauge ceiling', ['dial', 10000, 20], 'error: altitude out of range'],
  ['repair check: dial gauge ceiling', ['dial', 8500, 10], 'error: altitude out of range'],
  ['generated control 1', ['dial', 2000, 85], {'minutes': 85, 'psi': 11}],
  ['generated control 2', ['water bath', 4000, 10], {'minutes': 20, 'psi': None}],
  ['generated control 3', ['weighted', 1001, 85], {'minutes': 85, 'psi': 15}]]]
for label, args, expected in fixtures[N - 1]:
    check(label, solve(*args), expected)
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
sea level bath{'minutes': 10, 'psi': None}{'minutes': 10, 'psi': None}Passed
band edge 1000{'minutes': 10, 'psi': None}{'minutes': 10, 'psi': None}Passed
dial mid{'minutes': 25, 'psi': 12}{'minutes': 25, 'psi': 12}Passed
regression: dial gauge ceilingerror: altitude out of rangeerror: altitude out of rangePassed
repair check: dial gauge ceilingerror: altitude out of rangeerror: altitude out of rangePassed
generated control 1error: methoderror: methodPassed
generated control 2error: methoderror: methodPassed
generated control 3{'minutes': 45, 'psi': None}{'minutes': 45, 'psi': None}Passed

SHA-256 / fedf7ad1821a02a991a3ae03a8e31985a94699d497b436a111f53bfeba4244c9

Verification & scope

A deterministic toy contract stated in full here; it is a bounded teaching model, not an authoritative reference or standards implementation. 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:52:28.955279+00:00.

Case digest / ed048a1110c873632c4e6b3a4bc2b38405d3a3e93c057694a8e9bf0e8f30d092