Uncaught SyntaxError: Failed to construct ‘RTCPeerConnection‘:

目录

解决方法:


报错:

Uncaught SyntaxError: Failed to construct 'RTCPeerConnection': ICE server parsing failed: Invalid hostname format at PeerConnectionController.createPeerConnection (PeerConnectionController.js:40:1) at new PeerConnectionController (PeerConnectionController.js:30:1) at WebRtcPlayerController.startSession (WebRtcPlayerController.js:625:1) at WebRtcPlayerController.handleOnConfigMessage (WebRtcPlayerController.js:695:1) at PixelStreamingEventListener._callback (WebRtcPlayerController.js:75:50) at PixelStreamingEventListener.handleEvent (EventEmitter.js:12:1) at SignallingProtocol.emit (EventEmitter.js:235:1) at WebSocketTransport.onMessage (SignallingProtocol.js:49:1) at WebSocketTransport.handleOnMessage (WebSocketTransport.js:99:1) at WebSocket.<anonymous> (WebSocketTransport.js:38:1) createPeerConnection @ PeerConnectionController.js:40 PeerConnectionController @ PeerConnectionController.js:30 startSession @ WebRtcPlayerController.js:625 handleOnConfigMessage @ WebRtcPlayerController.js:695 (匿名) @ WebRtcPlayerController.js:75 handleEvent @ EventEmitter.js:12 emit @ EventEmitter.js:235 (匿名) @ SignallingProtocol.js:49 handleOnMessage @ WebSocketTransport.js:99 (匿名) @ WebSocketTransport.js:38 WebRtcPlayerController.js:158 Uncaught TypeError: Cannot read properties of undefined (reading 'peerConnection') at SettingOption.onChange (WebRtcPlayerController.js:158:1) at set value (SettingBase.js:45:1) at set selected (SettingOption.js:62:1) at Config.setOptionSettingValue (Config.js:429:1) at WebRtcPlayerController.handleStreamerListMessage (WebRtcPlayerController.js:745:1) at PixelStreamingEventListener._callback (WebRtcPlayerController.js:77:56) at PixelStreamingEventListener.handleEvent (EventEmitter.js:12:1) at SignallingProtocol.emit (EventEmitter.js:235:1) at WebSocketTransport.onMessage (SignallingProtocol.js:49:1) at WebSocketTransport.handleOnMessage (WebSocketTransport.js:99:1)

解决方法:

SignallingWebServer/platform_scripts/cmd/common.bat

bash 复制代码
:SetupTurnStun
IF "%TURN_SERVER%"=="" (
    set TURN_SERVER=%PUBLIC_IP%:19303
    set TURN_USER=PixelStreamingUser
    set TURN_PASS=AnotherTURNintheroad
)
IF "%STUN_SERVER%"=="" (
    set STUN_SERVER=stun.l.google.com:19302
)

改为:

bash 复制代码
:SetupTurnStun
IF "%TURN_SERVER%"=="" (
    set TURN_SERVER=stun.l.google.com:19302
    set TURN_USER=PixelStreamingUser
    set TURN_PASS=AnotherTURNintheroad
)
IF "%STUN_SERVER%"=="" (
    set STUN_SERVER=stun.l.google.com:19302
)
相关推荐
risenav6 分钟前
低头蓄力,抬头起跳:《萤虫跳跳》的 Rokid AIUI 开发实战
前端
ZhengEnCi22 分钟前
如何看待 Fable 5.2 用纯代码生成 1.4MB 视觉作品:光追、水面、倒影、火光的程序化生成原理
前端
再吃一根胡萝卜1 小时前
DSH 插件的 Host 与 Client:为什么「只加载了 Host」,以及要不要自己写 Client 加载器
前端
parade岁月1 小时前
AI 写的前端代码为什么总像 5 年前的?Chrome 官方出手了
前端
新*1 小时前
从一段 WebSocket 代码聊开:bytes 不是 zlib、binaryType 决定一切,15MB 大消息的零拷贝优化
javascript·python·websocket·性能优化·blob·zlib·arraybuffer
tryCbest2 小时前
Vue系列——第 15 篇:内置组件全家桶——Transition、Teleport、Suspense、KeepAlive
前端·vue.js
易师傅2 小时前
技术面试已死?AI 时代,真正拉开程序员差距的是什么?
前端·后端·程序员
jay神2 小时前
基于深度学习的交通流量预测系统(Web 版)
前端·人工智能·深度学习·yolo·计算机毕业设计
OpsEye2 小时前
别再挨个充会员了:多模型编码,最麻烦的从来不是选模型
javascript·ai编程
AiMan3 小时前
别再把秘塔会话逐个点开:这可把秘塔多个会话一次导出?AI导出鸭
前端·后端·面试