You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are having the problem that sometimes the hubconnection ends up stuck in a "Disconnecting" state when stopped while retrying. In our case this happens if the app is left in the background and Android seems to pause it. When it gets resumed the app tries to reconnect but we also do a stop at the same time.
2025-02-19 21:11:19.441977: Failed to start the connection: The connection was stopped during negotiation.
2025-02-19 21:11:19.444335: Reconnect attempt failed because of error 'The connection was stopped during negotiation.'.
2025-02-19 21:11:19.444650: Connection left the reconnecting state during reconnect attempt. Done reconnecting.
2025-02-19 21:11:19.444950: HttpConnection.transport is undefined in HttpConnection.stop() because start() failed.
2025-02-19 21:11:19.445173: HttpConnection.stopConnection(Unknown) called while in state ConnectionState.Disconnected.
2025-02-19 21:11:19.445377: Call to HttpConnection.stopConnection(null) was ignored because the connection is already in the disconnected state.
After further investigating it seems to be that the httpconnection is in disconnected state and here:
Hello,
We are having the problem that sometimes the hubconnection ends up stuck in a "Disconnecting" state when stopped while retrying. In our case this happens if the app is left in the background and Android seems to pause it. When it gets resumed the app tries to reconnect but we also do a stop at the same time.
After further investigating it seems to be that the httpconnection is in disconnected state and here:
signalr_client/lib/http_connection.dart
Lines 622 to 626 in 535865e
It just returns without completing the _stopPromiseCompleter that was created beforehand.
After moving:
signalr_client/lib/http_connection.dart
Line 638 in 535865e
Also into the if statement above it works fine but I'm not sure if that is the correct solution.
The text was updated successfully, but these errors were encountered: