Session Join Function Hangs Indefinitely - No Error or Success

Description

During a video call connection attempt, the zoomClient.join() function gets stuck and hangs indefinitely. The function neither successfully joins the session nor throws an error. This results in:

  • First user’s application only loading the first user’s own video
  • Second user’s application only loading the second user’s own video
  • Other video panes showing “Loading…” indefinitely
  • No errors shown in the application logs

The function appears to be waiting indefinitely for a response from the Zoom service, leaving the application in a partially connected state where local video streams work but peer video streams never load.

Session ID: 9aZfak+eRTWWbKhFOqAdDg==

Browser Console Error

No errors are shown in the logs. The application simply hangs at the zoomClient.join() call without completing or throwing an error.

Which Web Video SDK version?

2.1.10

Video SDK Code Snippets

The code snippets that are causing the error / issue so we can reproduce:

Desktop Application (Electron):

const videoCallSetUp = async (signature: string, session: string, agentName: string) => {
  try {
    window.api.saveLog({
      message: `videoCallSetUp :: setting up videocall`,
      level: LogLevel.INFO,
      meta: { agentName, session }
    });
    
    if (!signature || !session) {
      throw new Error('Signature or session is missing');
    }

    // create and initialize zoom client
    zoomClient = ZoomVideo.createClient();
    
    await zoomClient?.init('en-US', 'CDN', {
      stayAwake: true
    });

    // Join session - THIS CALL HANGS HERE
    await zoomClient?.join(session, signature, `${agentName}`);
    
    // This code never executes when the hang occurs
    const mediaStream = zoomClient?.getMediaStream();
    stream = mediaStream;
    const usersInRoom = zoomClient.getAllUser();
    return usersInRoom;
  } catch (error) {
    // Error handler never fires when hang occurs
    await window.api.saveLog({
      message: 'error occurred: videoCallSetup: ',
      level: LogLevel.ERROR,
      meta: { session, agentName, sessionId: zoomClient?.getSessionInfo()?.sessionId },
      stackTrace: error
    });
    console.error('error occurred: videoCallSetup', error);
  }
};

Web Application:

const videoCallSetUp = async (data: { signature: string; session: string }, imgURL: string) => {
  try {
    zoomClient = ZoomVideo.createClient();
    
    await zoomClient?.init('en-US', 'CDN', {
      stayAwake: true,
      enforceVirtualBackground: true
    });

    // Join session - THIS CALL HANGS HERE
    await zoomClient?.join(
      data.session,
      data.signature,
      `User Display Name`
    );
    
    // This code never executes when the hang occurs
    const mediaStream = zoomClient?.getMediaStream();
    stream = mediaStream;
    
    if (zoomClient) {
      zoomClient.on('peer-video-state-change', peerVideoLister);
      zoomClient.on('user-updated', onUserUpdated);
      zoomClient.on('user-removed', onUserRemoved);
    }

    await mediaStream?.startAudio();
    await mediaStream?.startVideo({
      hd: true,
      videoElement,
      virtualBackground: { imageUrl: imgURL }
    });
  } catch (error) {
    // Error handler never fires when hang occurs
    console.error('error occurred', error);
  }
};

To Reproduce

Steps to reproduce the behavior:

  1. Initialize the Zoom Video SDK client
  2. Call zoomClient.init() with ‘en-US’, ‘CDN’, and configuration options
  3. Call zoomClient.join() with valid session and signature
  4. The join() promise never resolves or rejects
  5. Local video streams start successfully
  6. Peer video streams never load (show “Loading…” indefinitely)
  7. No error is thrown, no timeout occurs

Note: This issue occurs intermittently.

Troubleshooting Routes

The troubleshooting attempt types you’ve already exhausted:

  1. Verified session and signature are valid (other calls work successfully)
  2. Checked network connectivity (no network errors)
  3. Verified that zoomClient.init() completes successfully
  4. Confirmed the issue is not a timeout issue (no timeout error thrown)
  5. Verified that the promise never resolves or rejects
  6. Checked application logs - no errors logged during the hang period

Device:

Desktop Application:

  • Device: Windows Desktop Application
  • OS: Windows 10
  • Browser: Electron (Chromium-based)
  • Browser Version: Electron 38.2.2

Web Application:

  • Device: Desktop/Laptop
  • OS: Windows 10 / macOS
  • Browser: Chrome
  • Browser Version: Latest

Additional context

  • The function hangs indefinitely without throwing an error or timing out
  • This creates a poor user experience as the application appears to be loading but never completes
  • The issue occurs after successful calls, indicating it’s not a configuration issue
  • We are using Zoom Video SDK version 2.1.10
  • We need a timeout mechanism or error handling for this scenario, but the SDK should handle this gracefully
  • Logs show the function was stuck from (21:10:28 UTC) until call was cancelled
1 Like

Hey @meet-jeavio

Thanks for your feedback.

9aZfak+eRTWWbKhFOqAdDg==

Based on the code review and log analysis, there may be some implementation issues:

  1. After calling mediaStream?.startVideo, you did not call attachVideo to render your own video. Listening to the peer-video-state-change event will not trigger for the current user starting their own video. We suggest the following:

    • After startVideo() resolves, call attachVideo to render the video; Video SDK - web - Core features
    • Or listen to the user-updated event and check the bVideoOn property. If it is true, render this user’s video; otherwise, stop rendering.
  2. The peer-video-state-change event does not reflect the video status of users who were already in the session before you joined. This event only triggers when a user’s video state changes. We suggest the following:

    • After joining the session, call zoomClient.getAllUser() to obtain the list of users already in the session. Iterate through the list, and if a user’s bVideoOn is true, call attachVideo to render their video. Video SDK - web - Core features

Thanks
Vic