bitfocus / companion-module-obs-studio

OBS Studio Module for Companion
MIT License
41 stars 28 forks source link

OBS connection drops when editing OBS scenes #259

Closed prehprehpreh closed 2 months ago

prehprehpreh commented 4 months ago

OBS connection drops when editing OBS scenes

Steps to reproduce the behavior:

  1. Have companion connected
  2. Work on your scene, edit anything

Temporary fix is to disable/enable OBS connection

I wanted to setup a trigger in companion to do that but couldn't figure it out

Version Information:

Does anyone else have this issue?

bryce-seifert commented 4 months ago

Can you please try the Companion beta, v3.3.0.

In the past two weeks there's been module performance improvements implemented, especially for very large scene collections.

bryce-seifert commented 3 months ago

@prehprehpreh Are you still experience the issue on the latest beta?

prehprehpreh commented 3 months ago

Running v3.3.0+6838-main-afedcb19 I still experience this. I'm gonna update to the latest beta though now. In companion I was seeing that it still thought it was connected but it wasn't responding to my commands. Will try the latest beta and follow up!

On Mon, Mar 25, 2024 at 8:12 PM bryce @.***> wrote:

@prehprehpreh https://github.com/prehprehpreh Are you still experience the issue on the latest beta?

— Reply to this email directly, view it on GitHub https://github.com/bitfocus/companion-module-obs-studio/issues/259#issuecomment-2019139848, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALCUCPSZJNSN7LCV5TQEVOTY2C4OVAVCNFSM6AAAAABEHR24G2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAMJZGEZTSOBUHA . You are receiving this because you were mentioned.Message ID: @.***>

mou22y2 commented 3 months ago

I have the exact same problem. Companion drops connection to OBS when I am editing scenes. Companion Version: 3.2.2+6688-stable-7417d2a0 I have to toggle connection to OBS websocket ON/OFF.

bryce-seifert commented 3 months ago

@mou22y2 Are there any errors in the log? Or does it still show connected? Can you also try opening the OBS log (the > icon next to the module name), editing a scene, and seeing if there are any errors?

mou22y2 commented 2 months ago

@mou22y2 Are there any errors in the log? Or does it still show connected? Can you also try opening the OBS log (the > icon next to the module name), editing a scene, and seeing if there are any errors?

Hi @bryce-seifert

Sorry for the late reply. April has been hectic. Thanks for trying to help. I have been able to repeat the problem. Here are a snippet from the moment when it happens from OBS log:

11:48:07.725: [obs-websocket] [WebSocketServer::onClose] WebSocket client [::ffff:127.0.0.1]:62451 has disconnected with code 1006 and reason: En befintlig anslutning tvingades att st䮧a av fj䲲v䲤datorn. 11:48:19.392: User added source 'Image - crash test ' (image_source) to scene 'Studio - INTERVJU utan kamera' 11:48:43.124: User switched Program to scene 'Studio - INTERVJU utan kamera' 11:49:08.817: [obs-websocket] [WebSocketServer::onOpen] New WebSocket client has connected from [::ffff:127.0.0.1]:62557 11:49:12.173: User switched Program to scene 'Studio' 11:49:15.278: User switched Program to scene 'Paus' 11:49:15.808: User switched to scene 'Studio' 11:49:18.684: User switched Program to scene 'Studio - INTERVJU' 11:49:19.212: User switched to scene 'Paus' 11:49:20.687: User switched Program to scene 'Studio - INTERVJU utan kamera' 11:49:21.233: User switched to scene 'Studio - INTERVJU' 11:49:23.780: ==== Shutting down ================================================== 11:49:23.850: [obs-websocket] [WebSocketServer::onClose] WebSocket client [::ffff:127.0.0.1]:62557 has disconnected with code 1000 and reason: 11:49:23.861: WASAPI: Device 'Voicemeeter Out B2 (VB-Audio Voicemeeter VAIO)' Terminated 11:49:23.867: WASAPI: Device 'Voicemeeter Out B3 (VB-Audio Voicemeeter VAIO)' Terminated 11:49:24.157: [obs-ndi] +ndi_source_destroy('NDI™ Source'...) 11:49:24.222: [obs-ndi] -ndi_source_thread('OBS-NDI 'NDI™ Source''...) 11:49:24.222: [obs-ndi] -ndi_source_destroy('NDI™ Source'...) 11:49:24.385: All scene data cleared 11:49:24.385: ------------------------------------------------ 11:49:24.385: [obs-ndi] preview_output_deinit() 11:49:24.385: [obs-ndi] +ndi_output_destroy('OBS Preview'...) 11:49:24.385: [obs-ndi] -ndi_output_destroy('OBS Preview'...) 11:49:24.440: Tried to call obs_frontend_remove_event_callback with no callbacks! 11:49:24.440: Tried to call obs_frontend_remove_save_callback with no callbacks! 11:49:24.559: [obs-websocket] [obs_module_unload] Shutting down... 11:49:24.560: [obs-websocket] [WebSocketServer::ServerRunner] IO thread exited. 11:49:24.565: [obs-websocket] [WebSocketServer::Stop] Server stopped successfully 11:49:24.565: Tried to call obs_frontend_remove_event_callback with no callbacks! 11:49:24.565: [obs-websocket] [obs_module_unload] Finished shutting down. 11:49:24.567: [obs-ndi] +obs_module_unload() 11:49:24.630: [obs-ndi] obs_module_unload: goodbye ! 11:49:24.630: [obs-ndi] -obs_module_unload() 11:49:24.675: [Scripting] Total detached callbacks: 0 11:49:24.675: Freeing OBS context data 11:49:24.722: == Profiler Results ============================= 11:49:24.722: run_program_init: 3826.76 ms 11:49:24.722: ┣OBSApp::AppInit: 30.995 ms 11:49:24.722: ┃ ┗OBSApp::InitLocale: 7.647 ms 11:49:24.722: ┗OBSApp::OBSInit: 3769.98 ms 11:49:24.722: ┣obs_startup: 3.579 ms 11:49:24.722: ┗OBSBasic::OBSInit: 3457.28 ms 11:49:24.722: ┣OBSBasic::InitBasicConfig: 0.782 ms 11:49:24.722: ┣OBSBasic::ResetAudio: 0.121 ms 11:49:24.722: ┣OBSBasic::ResetVideo: 662.813 ms 11:49:24.722: ┃ ┗obs_init_graphics: 661.379 ms 11:49:24.722: ┃ ┗shader compilation: 524.018 ms 11:49:24.722: ┣OBSBasic::InitOBSCallbacks: 0.007 ms 11:49:24.722: ┣OBSBasic::InitHotkeys: 0.02 ms 11:49:24.722: ┣obs_load_all_modules2: 567.087 ms 11:49:24.722: ┃ ┣obs_init_module(aja-output-ui.dll): 0.142 ms 11:49:24.722: ┃ ┣obs_init_module(aja.dll): 0.09 ms 11:49:24.722: ┃ ┣obs_init_module(coreaudio-encoder.dll): 1.204 ms 11:49:24.722: ┃ ┣obs_init_module(decklink-captions.dll): 0 ms 11:49:24.722: ┃ ┣obs_init_module(decklink-output-ui.dll): 0 ms 11:49:24.722: ┃ ┣obs_init_module(decklink.dll): 0.733 ms 11:49:24.722: ┃ ┣obs_init_module(frontend-tools.dll): 4.709 ms 11:49:24.722: ┃ ┣obs_init_module(image-source.dll): 0.007 ms 11:49:24.722: ┃ ┣obs_init_module(obs-browser.dll): 0.404 ms 11:49:24.722: ┃ ┣obs_init_module(obs-ffmpeg.dll): 145.018 ms 11:49:24.722: ┃ ┃ ┗nvenc_check: 0.708 ms 11:49:24.722: ┃ ┣obs_init_module(obs-filters.dll): 1.485 ms 11:49:24.722: ┃ ┣obs_init_module(obs-ndi.dll): 172.7 ms 11:49:24.722: ┃ ┣obs_init_module(obs-outputs.dll): 0.01 ms 11:49:24.722: ┃ ┣obs_init_module(obs-qsv11.dll): 26.731 ms 11:49:24.722: ┃ ┣obs_init_module(obs-soundboard.dll): 0.021 ms 11:49:24.722: ┃ ┣obs_init_module(obs-text.dll): 0.216 ms 11:49:24.722: ┃ ┣obs_init_module(obs-transitions.dll): 0.007 ms 11:49:24.722: ┃ ┣obs_init_module(obs-vst.dll): 0.015 ms 11:49:24.722: ┃ ┣obs_init_module(obs-webrtc.dll): 0.007 ms 11:49:24.722: ┃ ┣obs_init_module(obs-websocket.dll): 6.106 ms 11:49:24.722: ┃ ┣obs_init_module(obs-x264.dll): 0.001 ms 11:49:24.722: ┃ ┣obs_init_module(rtmp-services.dll): 4.691 ms 11:49:24.722: ┃ ┣obs_init_module(text-freetype2.dll): 0.056 ms 11:49:24.722: ┃ ┣obs_init_module(vlc-video.dll): 1.46 ms 11:49:24.722: ┃ ┣obs_init_module(win-capture.dll): 13.368 ms 11:49:24.722: ┃ ┣obs_init_module(win-dshow.dll): 1.984 ms 11:49:24.722: ┃ ┣obs_init_module(win-wasapi.dll): 9.431 ms 11:49:24.722: ┃ ┗reset_win32_symbol_paths: 0.258 ms 11:49:24.722: ┣OBSBasic::InitService: 9.785 ms 11:49:24.722: ┣OBSBasic::ResetOutputs: 0.284 ms 11:49:24.722: ┣OBSBasic::CreateHotkeys: 0.029 ms 11:49:24.722: ┣OBSBasic::InitPrimitives: 0.081 ms 11:49:24.722: ┗OBSBasic::Load: 1878.98 ms 11:49:24.722: obs_hotkey_thread(25 ms): min=0.002 ms, median=0.004 ms, max=2.165 ms, 99th percentile=0.146 ms, 100% below 25 ms 11:49:24.722: audio_thread(Audio): min=0.012 ms, median=0.174 ms, max=11.304 ms, 99th percentile=2.003 ms 11:49:24.722: obs_graphics_thread(16.6667 ms): min=0.064 ms, median=1.747 ms, max=3035.24 ms, 99th percentile=4.592 ms, 99.9706% below 16.667 ms 11:49:24.722: ┣tick_sources: min=0.001 ms, median=0.056 ms, max=3014.68 ms, 99th percentile=0.996 ms 11:49:24.722: ┣output_frame: min=0.058 ms, median=0.794 ms, max=16.925 ms, 99th percentile=3.772 ms 11:49:24.722: ┃ ┗gs_context(video->graphics): min=0.058 ms, median=0.793 ms, max=16.921 ms, 99th percentile=3.772 ms 11:49:24.722: ┃ ┣render_video: min=0.002 ms, median=0.584 ms, max=12.558 ms, 99th percentile=3.522 ms 11:49:24.722: ┃ ┃ ┗render_main_texture: min=0.001 ms, median=0.583 ms, max=12.554 ms, 99th percentile=3.519 ms 11:49:24.722: ┃ ┗gs_flush: min=0.051 ms, median=0.174 ms, max=4.456 ms, 99th percentile=0.384 ms 11:49:24.722: ┗render_displays: min=0 ms, median=0.432 ms, max=3.612 ms, 99th percentile=1.16 ms 11:49:24.722: ================================================= 11:49:24.722: == Profiler Time Between Calls ================== 11:49:24.722: obs_hotkey_thread(25 ms): min=24.864 ms, median=25.485 ms, max=27.103 ms, 52.0625% within ±2% of 25 ms (0% lower, 47.9375% higher) 11:49:24.722: obs_graphics_thread(16.6667 ms): min=5.129 ms, median=16.667 ms, max=3035.25 ms, 99.9119% within ±2% of 16.667 ms (0.0440593% lower, 0.0440593% higher) 11:49:24.722: ================================================= 11:49:24.954: Number of memory leaks: 0

Here are the error from Companion log: 24.05.06 11:47:16 Instance/Wrapper/obs: Failed to connect to OBS. Please ensure OBS is open and reachable via your network 24.05.06 11:48:49 Instance/Wrapper/obs: Error executing action: Call timed out

mou22y2 commented 2 months ago

@mou22y2 Are there any errors in the log? Or does it still show connected? Can you also try opening the OBS log (the > icon next to the module name), editing a scene, and seeing if there are any errors?

Hi again. I did try to download Beta 3.3.0+6957 and it works. So I guess it is solved. Should I wait for the stable version or is Beta versions normaly quite stable.

bryce-seifert commented 2 months ago

Great! The current beta is about to ship as the next stable release within a week or so, so it should be stable. That said, if you run into issues please let me know