Repository navigation
fix(drawer): start connections over while reducing resume and reroute - #224
Merged
Merged
Conversation
Port of iOS #298 (996c6987). Reroute, Try Again and returning to the foreground now reset the server pools and forget the cached address in the reducer, before the turn's reads start, instead of inside the new event stream's effect, where a read could start on the old pool first. A resync while not streaming no longer resets anything. eventStream loses its forgettingAddress/resetting parameters. Verified: scripts/check.sh on the Android VM (BUILD SUCCESSFUL); the new ServerLinkResetTriggerTests case fails without the change and passes with it; on the emulator, resuming after 22 s in the background logs the reset before the session reads, and reconnecting from the banner works.
Review follow-up. The test calls withDependencies and reduce directly instead of building a throwaway TestStore, and checks that Try Again and returning to the foreground skip the reset while not streaming. Verified: the test fails on origin/dev's HomeConnectionFeature and passes with the change; scripts/check.sh on the Android VM.
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.
Ports iOS #298 (996c6987). When the network changes, when Try Again is tapped, and when the app comes back to the foreground, it now resets the server pools and forgets the cached address while the action is reduced, so the turn's reads start on fresh pools. Before, the reset ran inside the new event stream's effect, so Home's snapshot or an open screen's resume reads could start on the old pool first. A resync while not streaming still skips the reset.
Not visible, so no media. Verified with
scripts/check.shand a test inServerLinkResetTriggerTeststhat fails without the change.