opencode-statboard 2.10.26 → 2.10.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/server.js +2 -6
package/package.json
CHANGED
package/server.js
CHANGED
|
@@ -1584,6 +1584,7 @@ async function startServer() {
|
|
|
1584
1584
|
|
|
1585
1585
|
(async () => {
|
|
1586
1586
|
try {
|
|
1587
|
+
await startServer();
|
|
1587
1588
|
// Serve the persisted bundle + tool counts IMMEDIATELY. Nothing on this
|
|
1588
1589
|
// path touches the live DB, so the first request answers in milliseconds
|
|
1589
1590
|
// instead of waiting out a 3-29s scan.
|
|
@@ -1616,17 +1617,12 @@ async function startServer() {
|
|
|
1616
1617
|
if (r && r.stats && r.stats.ok) reportCache[String(d)] = r;
|
|
1617
1618
|
} catch (_) {}
|
|
1618
1619
|
}
|
|
1619
|
-
for (const d of [7, 30, 90]) {
|
|
1620
|
+
for (const d of [1, 7, 30, 90]) {
|
|
1620
1621
|
try {
|
|
1621
1622
|
const t = await generateTrend(d);
|
|
1622
1623
|
if (t) trendCache[String(d)] = t;
|
|
1623
1624
|
} catch (_) {}
|
|
1624
1625
|
}
|
|
1625
|
-
// Open the port only once there is real data to paint. Listening first made
|
|
1626
|
-
// the browser paint an empty "updating" shell and then swap in numbers,
|
|
1627
|
-
// which is exactly what a 16s LCP looks like. With a cache present this is
|
|
1628
|
-
// ~1s after launch; on a cold machine the wait is the scan itself.
|
|
1629
|
-
await startServer();
|
|
1630
1626
|
setInterval(refresh, REFRESH_MS);
|
|
1631
1627
|
setInterval(refreshModels, 60000);
|
|
1632
1628
|
setInterval(refreshAttrBundle, 60000);
|