From c1d39d8a39c9c504d3180fbb3772f68eb3363717 Mon Sep 17 00:00:00 2001 From: Jason Ernst Date: Thu, 19 Mar 2026 23:07:15 -0700 Subject: [PATCH 1/2] docs: add caching details to README Document Vercel cache TTLs, cache_seconds override, and cache-busting tip for after the daily Action updates the gist. Co-Authored-By: Claude Opus 4.6 (1M context) --- readme.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/readme.md b/readme.md index 9d72f5a..b6e4477 100644 --- a/readme.md +++ b/readme.md @@ -97,6 +97,19 @@ GitHub Action (daily) └── Writes results to public gist ``` +## Caching + +Vercel caches card responses to avoid hitting GitHub's API on every request: + +| Card | Default | Min | Max | +|------|---------|-----|-----| +| Stats / Overview / Streak / Combined | 24 hours | 12 hours | 48 hours | +| Top Languages | 24 hours | 12 hours | 48 hours | + +You can override the default with `&cache_seconds=N` in the URL, but it will be clamped to the min/max range. + +After the daily GitHub Action updates the gist, it can take up to 24 hours for the combined card to reflect new data due to Vercel's edge cache. Adding a cache-busting parameter (e.g. `&v=2`) will force a fresh render. + ## Debugging The GitHub Action logs progress per-repo during the daily run, making it easy to identify which repos are slow or hitting API errors. You can also use the debug endpoint: From a8ef3acaa948237668f2fe9815f906882c7ea525 Mon Sep 17 00:00:00 2001 From: Jason Ernst Date: Thu, 19 Mar 2026 23:13:00 -0700 Subject: [PATCH 2/2] fix: correct top languages cache TTL in README Top Languages uses 6d/2d/10d, not 24h/12h/48h. Co-Authored-By: Claude Opus 4.6 (1M context) --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index b6e4477..e0b9824 100644 --- a/readme.md +++ b/readme.md @@ -104,7 +104,7 @@ Vercel caches card responses to avoid hitting GitHub's API on every request: | Card | Default | Min | Max | |------|---------|-----|-----| | Stats / Overview / Streak / Combined | 24 hours | 12 hours | 48 hours | -| Top Languages | 24 hours | 12 hours | 48 hours | +| Top Languages | 6 days | 2 days | 10 days | You can override the default with `&cache_seconds=N` in the URL, but it will be clamped to the min/max range.