Subchapter 144.18
troubleshooting/common-issues.mdMarkdown5 KBView on GitHub
examples/10 filesCauses:
tpc claimSolution:
# Regenerate JWT token
import jwt
import time
payload = {
"app_key": SDK_KEY,
"iat": int(time.time()) - 30,
"exp": int(time.time()) + 7200,
"tpc": "exact-session-name", # MUST match sessionName
"role_type": 1 # 0=participant, 1=host
}
token = jwt.encode(payload, SDK_SECRET, algorithm="HS256")Solution: Verify SDK_KEY and SDK_SECRET in JWT generation.
Solution:
session_context.sessionPassword = "password";Cause: PulseAudio not configured.
Solution: See PulseAudio Setup.
Solution: Use virtual audio:
session_context.virtualAudioSpeaker = new VirtualSpeaker();
session_context.virtualAudioMic = new VirtualMic();Solution: Use Raw Data Pipe. See Raw Data vs Canvas.
Cause: Not subscribing to user’s video pipe.
Solution:
void onUserVideoStatusChanged(..., IVideoSDKVector<IZoomVideoSDKUser*>* userList) override {
for (int i = 0; i < userList->GetCount(); i++) {
IZoomVideoSDKUser* user = userList->GetItem(i);
IZoomVideoSDKRawDataPipe* pipe = user->GetVideoPipe();
pipe->subscribe(ZoomVideoSDKResolution_720P, videoDelegate);
}
}Solution: See Qt Dependencies.
Solution: See Build Errors.
Solution: Use heap memory mode:
init_params.videoRawDataMemoryMode = ZoomVideoSDKRawDataMemoryModeHeap;sdk->initialize(initParams) returns error code 7 when:
"https://zoom.us" (with protocol). Plain "zoom.us" causes error 7.~/.config/zoomus.conf - Must exist with content:
[General]
system.audio.type=defaultThe SDK internally uses Qt/GLib for event dispatching. A while (running) { sleep(500ms); } loop does NOT work — onSessionJoin and all other delegate callbacks will never fire.
You MUST use a GLib main loop:
#include <glib.h>
static GMainLoop* loop = nullptr;
gboolean timeout_callback(gpointer data) {
return TRUE;
}
loop = g_main_loop_new(NULL, FALSE);
g_timeout_add(100, timeout_callback, loop);
g_main_loop_run(loop);
if (loop) g_main_loop_quit(loop);See Session Join Pattern for the complete working example.
ALL Zoom Video SDK API calls must be called from the GLib main thread. Calling SDK methods from a std::thread or any background thread returns ZoomVideoSDKErrors_Internal_Error (error code 2).
Use g_idle_add() to schedule SDK calls from background threads:
struct CallContext {
IZoomVideoSDK* sdk;
std::string data;
};
static gboolean executeOnMainThread(gpointer data) {
auto* ctx = static_cast<CallContext*>(data);
// Make SDK calls here — this runs on the GLib main thread
delete ctx;
return G_SOURCE_REMOVE;
}
// From a background thread:
auto* ctx = new CallContext{sdk_, someData};
g_idle_add(executeOnMainThread, ctx);g_idle_add() is thread-safe — it queues work onto the GLib main loop. See Command Channel for a real-world example.
tpc claim| Code | Name | Meaning |
|---|---|---|
| 0 | Success | Operation succeeded |
| 1001 | Auth_Error | Authentication failed |
| 1003 | Auth_Wrong_Token | Invalid JWT |
| 1004 | Auth_Expired_Token | JWT expired |
| 3001 | Session_Join_Failed | Failed to join |
| 3008 | Session_Need_Password | Password required |
| 3009 | Session_Password_Wrong | Wrong password |
| 7 | Invalid_Parameter | Wrong domain, missing PulseAudio, or missing zoomus.conf |
| 2 | Internal_Error | SDK method called from wrong thread (use g_idle_add) |