Files
hassio-integration-perfectd…/custom_components/perfectdraft/strings.json
T
rickandCursor f5c9019802 feat: detect keg change by volume jump + manual reset button
Keg-change detection previously fired only when the pour counter reset
to 0 while the keg read near full. That misses the common case where the
user swaps the keg and pours immediately, so pours never reads 0.

Detection now also fires on two volume-based signals (independent of the
pour counter): (b) remaining volume jumping from below 80% to at least
95%, and (c) any upward jump of at least 50 percentage points. The
decision logic is extracted to a dependency-free keg_detection module
with unit tests covering each trigger and the swap-then-pour case.

Adds a "Mark Keg Changed" button as a deterministic manual override,
wired to the freshness sensor via a dispatcher signal; the sensor now
tracks and restores last_volume alongside last_pours.

Bumps version to 0.3.0.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-05-31 21:04:44 +02:00

65 lines
2.1 KiB
JSON

{
"config": {
"step": {
"user": {
"title": "PerfectDraft Account",
"description": "Enter your PerfectDraft app credentials.",
"data": {
"email": "Email",
"password": "Password"
}
},
"token": {
"title": "Verification Token",
"description": "Paste a verification token from PerfectDraft's website. See the [setup instructions](https://github.com/Falkvinge/hassio-integration-perfectdraft-pro#step-2-verification-token) for the 30-second walkthrough. The token expires in 2 minutes, so generate it right before pasting.",
"data": {
"recaptcha_token": "Verification Token"
}
},
"reauth_confirm": {
"title": "Re-authenticate PerfectDraft",
"description": "Your session has expired. Please re-enter your credentials.",
"data": {
"email": "Email",
"password": "Password"
}
}
},
"error": {
"invalid_auth": "Authentication failed. Token may have expired (2 min limit) or credentials are wrong. Try again with a fresh token.",
"cannot_connect": "Cannot connect to PerfectDraft service.",
"unknown": "An unexpected error occurred."
},
"abort": {
"already_configured": "This PerfectDraft account is already configured.",
"reauth_successful": "Re-authentication successful."
}
},
"entity": {
"sensor": {
"temperature": { "name": "Temperature" },
"keg_remaining": { "name": "Keg Remaining" },
"connection": { "name": "Connection" },
"door": { "name": "Door" },
"pours": { "name": "Pours" },
"last_pour": { "name": "Last Pour" },
"firmware": { "name": "Firmware" },
"mode": { "name": "Mode" },
"keg_freshness": { "name": "Keg Freshness" }
},
"button": {
"mark_keg_changed": { "name": "Mark Keg Changed" }
}
},
"options": {
"step": {
"init": {
"title": "PerfectDraft Options",
"data": {
"scan_interval": "Polling interval (seconds)"
}
}
}
}
}