chore(world): 2.4.1 changelog; PWA guardrail asserts real precache intent
The stale guard demanded an html-free precache glob, contradicting the committed vite.config (offline.html precached, index/settings excluded via globIgnores). Assert the actual invariant instead. Claude-Session: https://claude.ai/code/session_01SpMZ69ur3tjAXCiwaa7Wv2
This commit is contained in:
@@ -2,6 +2,27 @@
|
||||
|
||||
All notable changes to World Monitor are documented here.
|
||||
|
||||
## [2.4.1]
|
||||
|
||||
### Added
|
||||
|
||||
- **Western Pacific cyclones**: cross-agency tropical-cyclone attribution (GDACS + HKO warnings via new `/v1/world/hko-warnings` proxy) with per-agency wind observations, canonical dedup, and map popup detail rows
|
||||
- **China macro snapshot**: `/v1/world/china-macro` — CPI/CLI (OECD), policy rate, USD/CNY (FRED), HKMA context, NBS release calendar + PBoC LPR dates, surfaced with staleness-honest indicator tiles
|
||||
- **Model roster**: `Best (auto)` leads the analyst model picker — the gateway routing alias that always resolves
|
||||
|
||||
### Changed
|
||||
|
||||
- **AI default model**: `zen5` → `best`; a pinned family id goes dark when the inference plane's claim catalog shifts, the routing alias never does
|
||||
- **Server cache is now stale-while-revalidate**: `cachedJSON`/`passthrough` serve stale instantly and refresh in the background (single-flight); GDELT/theater-posture no longer stall requests ~10s on TTL expiry
|
||||
- **GDELT cache warmers**: hot keys (analyst grounding, protests layer) refreshed every ~4min so no user ever eats a cold miss
|
||||
- **Sparkline payloads**: close arrays rounded to 7 significant digits (float32-widening noise stripped, ~40% smaller; scalars untouched)
|
||||
|
||||
### Fixed
|
||||
|
||||
- **News first paint**: panels no longer gate their first DOM write on a 65MB ML sentiment model download — headlines paint immediately, sentiment refines in place
|
||||
- **Analyst grounding snapshot**: context fetches bounded at 2.5s so a cold endpoint can't hold the chat send hostage
|
||||
- **AI errors are honest**: upstream error codes (`insufficient_balance`, `spend_cap_exceeded`, …) surface in the chat instead of a bare `status 402`
|
||||
|
||||
## [2.4.0] - 2026-02-19
|
||||
|
||||
### Added
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "world-monitor",
|
||||
"private": true,
|
||||
"version": "2.4.0",
|
||||
"version": "2.4.1",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"lint:md": "markdownlint-cli2 '**/*.md'",
|
||||
|
||||
@@ -27,12 +27,15 @@ describe('deploy/cache configuration guardrails', () => {
|
||||
);
|
||||
});
|
||||
|
||||
it('keeps PWA precache glob free of HTML files', () => {
|
||||
it('precaches offline.html but never the app shells', () => {
|
||||
// html stays in the glob so offline.html is precached; the shells are
|
||||
// excluded via globIgnores so a stale index/settings can never be served.
|
||||
assert.match(
|
||||
viteConfigSource,
|
||||
/globPatterns:\s*\['\*\*\/\*\.\{js,css,ico,png,svg,woff2\}'\]/
|
||||
/globPatterns:\s*\['\*\*\/\*\.\{js,css,html,ico,png,svg,woff2\}'\]/
|
||||
);
|
||||
assert.doesNotMatch(viteConfigSource, /globPatterns:\s*\['\*\*\/\*\.\{js,css,html/);
|
||||
assert.match(viteConfigSource, /globIgnores:\s*\[[^\]]*'index\.html'/);
|
||||
assert.match(viteConfigSource, /globIgnores:\s*\[[^\]]*'settings\.html'/);
|
||||
});
|
||||
|
||||
it('uses network-first runtime caching for navigation requests', () => {
|
||||
|
||||
Reference in New Issue
Block a user