Repository navigation
Commit 3d2fa5f
authored
fix(pages): bypass CDN cache in content comparison via GitHub API (#348)
GitHub Pages' Fastly CDN caches responses with max-age=600 and ignores
all client cache-bypass headers (Cache-Control: no-cache, Pragma: no-cache,
?t= query-string variations). Three consecutive master CI runs failed at
the "Verify live site serves the newest post" step because content_matches()
was polling the live CDN URL and consistently saw stale content for the
full 15-minute timeout window.
Switch content_matches() to fetch from the gh-pages branch via the GitHub
Contents API, which bypasses the CDN entirely. The feed-URL check in
get_live_links() still uses the live CDN URL so Pages build failures
(original 2026-11-07 incident) are still detected: if Pages fails to
publish, the feed URL stays absent from the live feed.
20/20 tests pass.
Git-Session-Id: 209e30bc-894b-41c8-a569-ec375cabdd6e1 parent 7d76081 commit 3d2fa5f
2 files changed
Lines changed: 29 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
10 | | - | |
11 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
12 | 20 | | |
13 | 21 | | |
14 | 22 | | |
| |||
133 | 141 | | |
134 | 142 | | |
135 | 143 | | |
136 | | - | |
137 | 144 | | |
138 | 145 | | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
139 | 149 | | |
140 | | - | |
141 | | - | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
142 | 158 | | |
| 159 | + | |
143 | 160 | | |
144 | 161 | | |
145 | | - | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
146 | 166 | | |
147 | 167 | | |
148 | 168 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
203 | 203 | | |
204 | 204 | | |
205 | 205 | | |
206 | | - | |
| 206 | + | |
| 207 | + | |
0 commit comments