feat(updates): the release lists through git-cdn.magicbean.dev first, so the update check works while git.magicbean.dev is down #76
No reviewers
Labels
No labels
area/build
area/install
area/saves
area/tooling
area/ui
area/updates
ci: approved
good first issue
gpu/amd
gpu/intel
gpu/nvidia
help wanted
kind
bug
kind
chore
kind
docs
kind
feature
kind
performance
kind
question
platform/linux
platform/steam-deck
platform/windows
priority
critical
priority
high
priority
low
risk
high
risk
low
risk
medium
status
blocked
status
confirmed
status
duplicate
status
invalid
status
needs-info
status
wontfix
ci: approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
MagicBeanDev/LongshotLauncher!76
Loading…
Reference in a new issue
No description provided.
Delete branch "HumanBean/LongshotLauncher:feat/release-lists-cdn"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Status: feat · low risk · not run yet (no .NET on the author's PC; CI runs the checks) · the git-cdn Worker change is deployed (version 68ca28f2)
When git.magicbean.dev is down, the launcher can't check for updates, even though the release files themselves already come from git-cdn.magicbean.dev. That's because the release lists still come from git.magicbean.dev. Every launcher's check at start also lands on Forgejo. With this change the lists come through Cloudflare's edge too: a list there may be up to a minute old, and it is still served while git.magicbean.dev is down.
What changed
CdnFetchernow sends the API's release list (/api/v1/repos/<owner>/<repo>/releases, any page) and a release by its tag (.../releases/tags/<tag>) to git-cdn.magicbean.dev first. It falls back to git.magicbean.dev on the same failures as a download: no answer, 403, 404 or 5xx. The rest of the API stays on git.magicbean.dev.Core/CdnFetcher.cs:ListCdnOf(url)(which API links go to the CDN), andGetTextAsynctries the CDN first for them.LONGSHOT_LAUNCHER_NO_CDN=1turns it off as before.tests/launcher_core/CdnChecks.cs: which links count as a list (and which don't: a release by id, its assets,latest, other API paths, other hosts, http, another port, a link already on git-cdn). Also: a list from the CDN, each fallback status, a 400 not falling back, both failing (git.magicbean.dev's error is the one reported), and the CDN off. The fake fetcher'sGetTextAsynccan now fail.LONGSHOT_LAUNCHER_NO_CDNrow) and a comment inApp/LauncherService.cs.Server side (git-cdn's Worker, deployed 2026-11-14): for anonymous
GETs of those two paths, the Worker keeps Forgejo's answer at the edge.Measurements
Nothing to measure in the game: this changes where the update check's two small JSON requests go, not the build or the game. Checked on the deployed Worker:
X-Cache: MISSthenHITonhttps://git-cdn.magicbean.dev/api/v1/repos/MagicBeanDev/LongshotLauncher/releases?limit=50&page=1.Testing
test_launcher_core.pycompilesCore/and runsCdnChecks.HttpFetcherfollows the redirect, so the check works as today.LONGSHOT_LAUNCHER_NO_CDN=1checks against git.magicbean.dev only.MISSthenHIT, the tag lookup answers, other API paths and requests with a token still redirect to git.magicbean.dev, and a download still answers.Risks
SHA256SUMS.🤖 Generated with Claude Code
WIP: feat(updates): the release lists through git-cdn.magicbean.dev first, so the update check works while git.magicbean.dev is downto feat(updates): the release lists through git-cdn.magicbean.dev first, so the update check works while git.magicbean.dev is downThe git-cdn Worker is deployed. Release lists on git-cdn now answer from the edge:
MISSthenHIT. Other API paths and requests with a token still redirect to git.magicbean.dev, and downloads still work. Forgejo now has 5 s to answer before it counts as down. This PR still waits for CI and for a launcher built from it to run an update check.