Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this PR does
Persists the WHOOP family established by GATT service discovery alongside the bonded device address, instead of persisting the family still selected in the UI picker.
Scan fallback and easy-connect can establish a different family from the requested picker value. Saving those two different sources as one pair made a WHOOP 4.0 address look like a 5/MG address (or vice versa), and the incorrect pair was then fed back into direct reconnects.
The new read-only BLE accessor returns no model until the current connection has published its discovered family. Its volatile read order matches the existing battery-source guard, so a default or previous connection value is never treated as current evidence.
No BLE command, frame, handshake order, or connection transition changes.
Type of change
How it was tested
EstablishedWhoopModelTest: both unestablished family values return no model, while established WHOOP 4 and WHOOP 5 map to their matching picker models.bonded = truetransition: each occurs after service discovery establishes the family../gradlew assembleFullDebug./gradlew testFullDebugUnitTest— 6,121 tests, zero failures (six existing skips)python3 Tools/doc_comment_lint.pypython3 docs/protocol-examples/validate_examples.pypython3 Tools/i18n_audit.py --ci upstream/mainNot tested on physical hardware. This changes only the model written to preferences after an existing bond transition; it does not change bytes sent, GATT sequencing, scanning, or reconnect behavior on the active link.
Checklist
android/StrandDesigntokens (N/A — no UI changes)docs/CONTRIBUTING.mdStrand.xcodeproj/) or any secrets/keystoresRelated issues
Closes #2068