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
)
相关推荐
一点一木9 小时前
深度体验TRAE SOLO移动端7天:作为独立开发者,我把工作流揣进了兜里
前端·人工智能·trae
天外飞雨道沧桑10 小时前
TypeScript 中 omit 和 record 用法
前端·javascript·typescript
Lee川10 小时前
mini-cursor 揭秘:从 Tool 定义到 Agent 循环的完整实现
前端·人工智能·后端
canonical_entropy11 小时前
从 Spec-Driven Development 到 Attractor-Guided Engineering
前端·aigc·ai编程
研☆香11 小时前
聊聊前端页面的三种长度单位
前端
给钱,谢谢!12 小时前
React + PixiJS 实现果园成长页:从状态机到浇水动画
前端·react.js·前端框架
暗冰ཏོ13 小时前
VUE面试题大全
前端·javascript·vue.js·面试
次元工程师!13 小时前
LangFlow开发(三)—Bundles组件架构设计(3W+字详细讲解)
java·前端·python·低代码·langflow
Bug-制造者14 小时前
现代Web应用全栈开发:从架构设计到部署落地实战
前端
青春喂了后端14 小时前
IntelliGit 前端状态层重构:把一个全局 Store 拆成清晰的状态边界
前端·重构·状态模式