Skip to content

Commit d1c7775

Browse files
committed
fix(worker): fetch celestrak over the public internet
celestrak.org sits behind Cloudflare, so a Worker fetch() to it was routed internally ("orange-to-orange") instead of over the public internet. That internal path times out with HTTP 522, so every source failed and no group data reached KV — even though the cron now runs to completion. The same URLs fetch fine from any ordinary client. The global_fetch_strictly_public compatibility flag forces fetch() out to Cloudflare's public front door, matching a normal client. It is not enabled by default at any compatibility_date, so it must be set explicitly. Assisted-by: ClaudeCode:claude-opus-4-8
1 parent 9c7fa3c commit d1c7775

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

worker/wrangler.jsonc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,13 @@
33
"name": "satvis",
44
"main": "src/index.ts",
55
"compatibility_date": "2026-03-10",
6+
// celestrak.org is itself behind Cloudflare. Without this flag a Worker's
7+
// fetch() to another Cloudflare-proxied host is routed internally
8+
// ("orange-to-orange"), which times out with HTTP 522 — even though the same
9+
// URL fetches fine from the public internet. This flag forces fetch() out to
10+
// Cloudflare's public front door, matching a normal client. It is not on by
11+
// default at any compatibility_date, so it must be set explicitly.
12+
"compatibility_flags": ["global_fetch_strictly_public"],
613
"send_metrics": false,
714
"routes": [
815
{

0 commit comments

Comments
 (0)