Skip to content

fix: recover firmware releases when API proxy stalls#2100

Merged
garthvh merged 1 commit into
meshtastic:mainfrom
RCGV1:codex/fix-firmware-release-recovery
Jul 17, 2026
Merged

fix: recover firmware releases when API proxy stalls#2100
garthvh merged 1 commit into
meshtastic:mainfrom
RCGV1:codex/fix-firmware-release-recovery

Conversation

@RCGV1

@RCGV1 RCGV1 commented Jul 16, 2026

Copy link
Copy Markdown
Member

Problem

The shipped firmware refresh path only requests https://api.meshtastic.org/github/firmware/list with a 5-second timeout. Its error is discarded by the startup task, and an error path leaves the firmware-loading state set to true. A first install therefore has no release catalog and stays on the updating state.

Live check on 2026-07-16:

  • The Meshtastic firmware-list endpoint timed out after 10.004 seconds without receiving any bytes (HTTP 000).
  • GitHub's meshtastic/firmware releases endpoint returned HTTP 200 in 0.462 seconds (44,596 bytes).

This isolates the failure to the firmware-list proxy route rather than a general iOS/network outage.

Changes

  • Keep the Meshtastic API response as the primary source.
  • Fall back to GitHub's release API when that request or decode fails.
  • Map published GitHub releases into the existing Stable and Alpha catalogs; drafts are excluded.
  • Clear the loading state on every success or failure path, preserving the existing stored catalog if both sources fail.
  • Add regression coverage for GitHub mapping and the existing Meshtastic API format.

Validation

  • Focused simulator test: 2 passed, 0 failed on iPhone 17 Pro (iOS 26.5).
  • Project lint phase completed with 0 serious violations.
  • git diff --check passed.

The local pre-commit SwiftLint hook could not load sourcekitd in this shell; the Xcode simulator build's lint phase and focused tests completed successfully.

@coderabbitai

coderabbitai Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Caution

Review failed

An error occurred during the review process. Please try again later.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@garthvh
garthvh merged commit 708d3d9 into meshtastic:main Jul 17, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants