mirror of
https://github.com/vector-im/element-call.git
synced 2026-02-02 04:05:56 +00:00
Use the New MatrixRTCSession MembershipManager (#3015)
* provide option to use the New MembershipManager * fix cryptoApi import change * add error screen * bump js-sdk * rename to `setUnrecoverableError` and remove onLeave call because that will be handled by an effect. * this was doing nothing (it is a fragment back when there was no deprecated `rtcSession.room`) * rename to error * Update src/utils/errors.ts Co-authored-by: Hugh Nimmo-Smith <hughns@users.noreply.github.com> * Update src/utils/errors.ts Co-authored-by: Hugh Nimmo-Smith <hughns@users.noreply.github.com> * review * bump js-sdk * expose lk log level changing in `window` * bump js-sdk - always log "Missing own membership: force re-join" - also check insertions queue * change lk log level to warn * Bump js-sdk * Bump js-sdk * . * Bump js-sdk * show user count based on meberships not users. Signed-off-by: Timo K <toger5@hotmail.de> * bump js-sdk * rename setting name * remove unused import * js sdk bump * remove `window.setLKLogLevel` * bump js sdk with reverted incompatible change * bump js-sdk with one less merge --------- Signed-off-by: Timo K <toger5@hotmail.de> Co-authored-by: Hugh Nimmo-Smith <hughns@users.noreply.github.com> Co-authored-by: Hugh Nimmo-Smith <hughns@element.io>
This commit is contained in:
@@ -13,6 +13,7 @@ export enum ErrorCode {
|
||||
*/
|
||||
MISSING_MATRIX_RTC_FOCUS = "MISSING_MATRIX_RTC_FOCUS",
|
||||
CONNECTION_LOST_ERROR = "CONNECTION_LOST_ERROR",
|
||||
MEMBERSHIP_MANAGER_UNRECOVERABLE = "MEMBERSHIP_MANAGER_UNRECOVERABLE",
|
||||
UNKNOWN_ERROR = "UNKNOWN_ERROR",
|
||||
}
|
||||
|
||||
@@ -20,6 +21,7 @@ export enum ErrorCategory {
|
||||
/** Calling is not supported, server misconfigured (JWT service missing, no MSC support ...)*/
|
||||
CONFIGURATION_ISSUE = "CONFIGURATION_ISSUE",
|
||||
NETWORK_CONNECTIVITY = "NETWORK_CONNECTIVITY",
|
||||
RTC_SESSION_FAILURE = "RTC_SESSION_FAILURE",
|
||||
UNKNOWN = "UNKNOWN",
|
||||
// SYSTEM_FAILURE / FEDERATION_FAILURE ..
|
||||
}
|
||||
@@ -72,3 +74,9 @@ export class ConnectionLostError extends ElementCallError {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export class RTCSessionError extends ElementCallError {
|
||||
public constructor(code: ErrorCode, message: string) {
|
||||
super("RTCSession Error", code, ErrorCategory.RTC_SESSION_FAILURE, message);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -69,7 +69,7 @@ async function waitForSync(client: MatrixClient): Promise<void> {
|
||||
* otherwise rust crypto will throw since it is not ready to initialize a new session.
|
||||
* If another client is running make sure `.logout()` is called before executing this function.
|
||||
* @param clientOptions Object of options passed through to the client
|
||||
* @param restore If the rust crypto should be reset before the cient initialization or
|
||||
* @param restore If the rust crypto should be reset before the client initialization or
|
||||
* if the initialization should try to restore the crypto state from the indexDB.
|
||||
* @returns The MatrixClient instance
|
||||
*/
|
||||
@@ -160,7 +160,6 @@ export async function initClient(
|
||||
);
|
||||
}
|
||||
|
||||
client.setGlobalErrorOnUnknownDevices(false);
|
||||
// Once startClient is called, syncs are run asynchronously.
|
||||
// Also, sync completion is communicated only via events.
|
||||
// So, apply the event listener *before* starting the client.
|
||||
|
||||
Reference in New Issue
Block a user