refactor: Eliminated global TZ cache

The configured timezone (or local) is now set on Site directly.
This commit is contained in:
Spencer Brower
2026-07-24 11:32:47 -04:00
parent 4f09312daf
commit 75a7d7a14b
9 changed files with 114 additions and 144 deletions
+3 -1
View File
@@ -33,11 +33,13 @@
- [x] Accept "strings"
- [x] Accept keys
- [x] handle timezones
- [ ] Fix TZ cache leak in parallel tests: `tz_cache` uses `context.allocator` (tracking allocator in tests), but it's global state shared across parallel test threads. Race causes leak warnings. Fix: use heap allocator for TZ cache.
- [ ] display an error when no part of the date appears in the output.
- [x] use `date.format` as the default format.
- [ ] Handle 0 and whitespace padding i.e. "_2" -> " 2"
- [ ] Do we *need* mustache.Date_Components, or can we use core:time/datetime.DateTime?
- [ ] show a proper diagnostic for timezones
- currently "unable to load timezone 'America/New_Yorkskie'"
- want rust style diagnostic and better message, maybe "unknown timezone 'America/New_Yorkskie'"
## General
- [ ] Integrity hash