v0.258.0: the last four Hungarian things an English household met
gates / gates (push) Successful in 24s

R-589 the update badge, R-590 the data-folder backup sentence, R-573 the two channel
banners, R-572 two dead helpers. All four were built in Go, which is why neither the
template parity fixtures nor TestI18nEnglishPages could see them; slice 5's LIVE proof
is what found them.

R-590 is the one that matters most: it is a promise about the customer's files. It
said, in Hungarian and under an already-English folder label, that a drop-zone is
temporary and unbacked. The test now asserts the CONSEQUENCE in both languages — and
that the two languages do not produce the same string, which would mean the English
fell back.

R-572 is not what its row said. The row claimed a template renders "vasárnap" on an
English page; measured, NO template and no Go file called pruneLabel or
nextPruneLabel. They were dead func-map entries returning Hungarian, so they are
deleted rather than translated — translating dead code would add machinery with no
reader and a test pinning a fiction. Deletion is fail-loud and that was proven: a
template naming the removed function panics loadTemplates at startup.

Five red-proofs. One of them says something about the gate rather than the code: the
Go-parity gate does not measure localeFuncs keys against the base capture, so the
citation to TestLocaleFuncsHungarianBundleMatchesFuncMap is what carries them — the
test was extended to make that citation true.

MinAgent: 0.131.0 (unchanged). Hungarian byte-identical.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0159rPz1ZhFKsS53msqPYxtS
This commit is contained in:
2026-09-20 18:10:53 +02:00
parent ecefdf2dc5
commit 7c4a33b6d1
12 changed files with 425 additions and 74 deletions
+10 -32
View File
@@ -6,7 +6,6 @@ import (
"hash/fnv"
"html/template"
"regexp"
"strings"
"sync"
"time"
"unicode"
@@ -360,37 +359,16 @@ func (s *Server) templateFuncMap() template.FuncMap {
}
return lt.Format("2006-01-02") + " " + timeStr
},
"pruneLabel": func(s string) string {
switch strings.ToLower(s) {
case "weekly":
return "vasárnap"
case "daily":
return "naponta"
case "sunday":
return "vasárnap"
default:
return s
}
},
"nextPruneLabel": func(schedule string) string {
now := time.Now().In(loc)
var next time.Time
switch strings.ToLower(schedule) {
case "daily":
next = now.Add(24 * time.Hour)
default: // weekly/sunday
daysUntilSunday := (7 - int(now.Weekday())) % 7
if daysUntilSunday == 0 {
if now.Hour() >= 4 {
daysUntilSunday = 7 // Already ran today, next week
} else {
return "ma" // Today (Sunday), hasn't run yet
}
}
next = now.AddDate(0, 0, daysUntilSunday)
}
return next.Format("2006-01-02")
},
// R-572 (v0.258.0) — `pruneLabel` and `nextPruneLabel` WERE HERE, and they are deleted
// rather than translated. The row said "a template calling either renders Hungarian on an
// English page"; measured 2026-09-2X, NO template and no Go file called either — they were
// dead func-map entries returning „vasárnap" / „naponta" / „ma". Translating dead code
// would have added machinery with no reader and a test pinning a fiction.
//
// Deleting is FAIL-LOUD, which is why it is the safe direction: html/template refuses to
// parse a template naming an undefined function, and loadTemplates parses every template
// once per supported language at startup. A future template that needs a weekday will get
// "function ... not defined" at boot rather than Hungarian on an English page.
"fmtDuration": func(d time.Duration) string {
if d < time.Second {
return "< 1s"