Skip to content

fix: report automatic rollbacks to the server on the next launch#4

Merged
fonkamloic merged 3 commits into
ios-codepush-p3-checkpointfrom
fix/report-native-rollbacks
Jun 12, 2026
Merged

fix: report automatic rollbacks to the server on the next launch#4
fonkamloic merged 3 commits into
ios-codepush-p3-checkpointfrom
fix/report-native-rollbacks

Conversation

@fonkamloic

@fonkamloic fonkamloic commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

What

Automatic crash-loop rollbacks run before any Dart code, so the server (and the publisher dashboard) never learned about them — devices could be crash-looping and rolling back with zero telemetry.

How

  • On the next launch after a rollback, init reads a marker file the rollback left in the patch directory and posts it to /api/v1/telemetry/client-error as kind: auto_rollback (reason, patch version, boot count, timestamp).
  • The marker is deleted only after the server confirms receipt (2xx), so offline devices retry on a later launch. An unreadable marker is discarded.
  • Best-effort throughout: telemetry can never crash the app.

Pairs with an engine-side change that records the marker. Targets the checkpoint branch since it builds on the rc-series init flow.

Notes

  • dart format + dart analyze clean (the 9 pre-existing avoid_print infos on this branch are untouched).

Crash-loop rollbacks happen before any Dart code runs, so they were
invisible to server telemetry. The rollback now leaves a marker in the
patch directory; on the next launch the SDK posts it to the client-error
telemetry endpoint and clears it once the server confirms receipt
(offline devices retry on a later launch).
@fonkamloic fonkamloic merged commit 964324b into ios-codepush-p3-checkpoint Jun 12, 2026
1 of 3 checks passed
@fonkamloic fonkamloic deleted the fix/report-native-rollbacks branch June 12, 2026 05:08
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.

1 participant