This repository was archived by the owner on Sep 11, 2024. It is now read-only.
Fix calls incorrectly showing as "Connecting" #10204
Closed
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.
Fixes PSC-204
The issue as I saw it lay in the
setState
insideLegacyCallEventGrouper
. ThesetState
method is used in two places, it's called directly insetCall
and also as a listener, attached tothis.call
.The issue was that normally, when closing down a call, the
this.call
listener would fire last, (after allsetCall
calls). When this happens, we get the incorrect state displayed. Sometimes, the listener would fire in amongst all of the (about 20) calls tosetState
fromsetCall
when trying to close a call. This would result in the expected behaviour.I've tried to make the fix as small as possible by allowing the
this.call
listener to directly set the state of theLegacyCallEventGrouper
given that this seemed like the source of truth to me. Applying this change made the text behave as expected in testing (video attached).Nb left hand side of the screen is nightly (ie demonstrates the problem), right hand side is element web, with the changes applied
Video 1 - comparing missed calls
https://user-images.githubusercontent.com/56027671/220369272-1e5d2d26-a383-4b9e-9a76-ab0d91830d72.mov
Video 2 - comparing successful calls
https://user-images.githubusercontent.com/56027671/220369671-3fc5c336-abdb-42c5-8cb2-6256b1da3952.mov
Checklist
Here's what your changelog entry will look like:
🐛 Bug Fixes