obs-websocket icon indicating copy to clipboard operation
obs-websocket copied to clipboard

Crashing OBS on Exit, and general hanging of OBS Studio.

Open Grid21 opened this issue 5 years ago • 26 comments

Issue type: Crash

Bug Report.

Description

OBS websocket has been straight up crashing when I go to exit the program. And overall it's been causing the program to hang quite a lot. Crash 2020-12-30 00-05-06.txt

Steps to reproduce and other useful info

The simple step was opening OBS, then Closing OBS Studio, and then BAM, it crashes.

Technical information

Windows 10 Pro 64-bit

  • OBS Studio version: 26.1
  • obs-websocket version: 4.8.0
Development Environment

Grid21 avatar Dec 30 '20 06:12 Grid21

I'm having the same issue. Especially in combination with Companion: https://github.com/bitfocus/companion/issues/1362

Fplusplus avatar Jan 07 '21 11:01 Fplusplus

I am also experiencing regular but unexplained crashes/hangs of OBS when using the plugin with the same environment as the original poster. It's not happening repeatedly when following the same steps and results in OBS 'not responding'. I have one scene and a number of sources (images, browser, text) that I manipulate via an Angular 11 app with obs-websockets-js. Any help on this would be gratefully received.

sitereportuk avatar Jan 13 '21 08:01 sitereportuk

Well, I hope at some point the Developer does something to fix these issues because I depend on this plugin for the things I do for my stream. Does anyone know if the developer is still working on this? Or do I need to find an alternate plugin?

Grid21 avatar Jan 26 '21 00:01 Grid21

The crashes sadly still exist in V4.9

Crash 2021-02-11 16-44-31.txt

negue avatar Feb 11 '21 15:02 negue

The crashes sadly still exist in V4.9

Crash 2021-02-11 16-44-31.txt

I had OBS Crash just last night when closing OBS. Crash 2021-02-11 02-18-50.txt 2021-02-10 19-58-53.txt

Grid21 avatar Feb 11 '21 20:02 Grid21

Same here. I run a quite extensive amount of integration tests for https://github.com/dnaka91/obws and bombard obs-websocket with a lot of requests in the process.

Every time when closing OBS it crashes with the same stacktrace as others have already added.

dnaka91 avatar Feb 14 '21 08:02 dnaka91

Same here. I run a quite extensive amount of integration tests for https://github.com/dnaka91/obws and bombard obs-websocket with a lot of requests in the process.

Every time when closing OBS it crashes with the same stacktrace as others have already added.

I installed the new update, and OBS Still hung itself when exiting the program. I am also wondering if it's somehow affecting my Elgato Camlink and C930e because when I go to either bootup or adjust the properties, OBS will straight up lock and white screen on me,

Grid21 avatar Feb 14 '21 22:02 Grid21

Hi. I'm not sure if it's related, but I have crashes in OBS after some command from obs-cli (list-sceneitems, switch-scene) not every time but after some requests, even after the first. O.S. Fedora 33 obs-websocket 4.9.0 compiled from scratch

After closing connection from client (crashing or not) [obs-websocket] server(response): send failed: invalid state

thanks

domfe avatar Feb 17 '21 10:02 domfe

Hi.

It happens to me under these circumstances:

  1. get scene list from obs
  2. check from an array which scenes aren't yet created
  3. create scenes not existant yet (these scenes are basic ones with just one distinct background image source)
  4. I can manually check that the scenes are successfully created
  5. After closing OBS I get the the crash warning: "Woops, OBS has crashed!"

The crash log crash-obs-2021-03-03-19-20.txt

I'm using:

  • Windows 10
  • 4.9 plugin version on OBS
  • js npm package

casanovarodrigo avatar Mar 03 '21 22:03 casanovarodrigo

@casanovarodrigo And you can reliably cause this crash, yes?

tt2468 avatar Mar 03 '21 23:03 tt2468

I've built a test version of obs-websocket to attempt to fix one crash and debug another: https://dev.azure.com/Palakis/obs-websocket/_build/results?buildId=1699&view=artifacts&pathAsName=false&type=publishedArtifacts

@casanovarodrigo @negue This should fix the crash that you are experiencing. Please test and report back with logs whether it worked or not.

@Grid21 This version will not fix your crash (yet), but it logs an integer which I need in order to further diagnose why the crash is happening. Install this and cause a crash, then look at the log for a message like Websocket connection closed. Code is %d. I need that code. It should theoretically be the last log message.

tt2468 avatar Mar 04 '21 00:03 tt2468

@casanovarodrigo And you can reliably cause this crash, yes?

Yes. If I don't make any socket calls like that to the OBS app it wont crash after exiting it. Every time I do the calls I get the crash.

@casanovarodrigo @negue This should fix the crash that you are experiencing. Please test and report back with logs whether it worked or not.

I don't have the knowledge and environment to compile by the github branch. I'm using the dist build in objsproject If there's a reasonable way to understand and build it I'll try to help and report back. I did read the BUILDING.md. The "OBS Studio development environment" step seems very difficult though.

casanovarodrigo avatar Mar 04 '21 06:03 casanovarodrigo

@casanovarodrigo What I linked to is an installer download. Click the build_windows row.

tt2468 avatar Mar 04 '21 06:03 tt2468

@casanovarodrigo What I linked to is an installer download. Click the build_windows row.

Oh I've totally missed that button on the right.

The crash is still happening after installing this version you linked.

crash-obs-2021-03-04_16-53-24.txt

casanovarodrigo avatar Mar 04 '21 19:03 casanovarodrigo

@casanovarodrigo Hmmm, I don't see obs-websocket at all in the callstack here. I think that this latest crash is not our doing.

tt2468 avatar Mar 04 '21 20:03 tt2468

@casanovarodrigo Hmmm, I don't see obs-websocket at all in the callstack here. I think that this latest crash is not our doing.

I don't know what else could be. If I dont make any obs-websocket call I don't get the crash. I've reinstalled obs (with maintain settings option enabled) and obs-websocket and still the same thing. (did also install the hot-fix you've sent)

This one I've uploaded previously indeed doesn't show any obs-websocket mention. I just did one and in contrast with the second to last crash I've sent that showed a lot of mentions, this one shows only one:

00007FF9118A0000-00007FF911992000 C:\Program Files\obs-studio\obs-plugins\64bit\obs-websocket.dll

obs-crash_2021-03-04, 173108.txt

casanovarodrigo avatar Mar 04 '21 20:03 casanovarodrigo

Installed the Plugin via the Installer first => it crashed on closing again, then I thought the Installer might didn't work so I copied the files manually as well.

Same crash (also same stacktrace)

Crash 2021-03-04 21-43-36.txt

negue avatar Mar 04 '21 20:03 negue

@negue The version isn't supposed to fix your crash, only log some debug information. I need the obs log from that crash.

@casanovarodrigo Post your crash log in #development in the obs Discord and ping me there when you do. We'll need some input from obs devs.

tt2468 avatar Mar 04 '21 20:03 tt2468

@negue The version isn't supposed to fix your crash, only log some debug information. I need the obs log from that crash.

Oh, yeah no worries if it didn't fix on the first try, you just mentioned that

This should fix the crash that you are experiencing.

should and weird issues sometimes doesn't work together I get that 😁

fingers crossed this log helps🤞

2021-03-04 2022-07-45.txt

negue avatar Mar 05 '21 00:03 negue

@negue So I should have looked at your two logs closer, because your original crash dump shows what should have been fixed, but your crash dump from earlier today is the second issue which I was debugging. How fun, two crash issues right?

Anyway, I pushed a presumed fix for the crashes that have this stacktrace:

qt5widgets.dll!0x7ffc9457b8df
qt5widgets.dll!0x7ffc94565b2b
websocket.dll!Utils::SysTrayNotify+0x7a
websocket.dll!WSServer::notifyDisconnection+0xec
websocket.dll!WSServer::onClose+0x107

Here is the download link for everyone: removed because it had some issues. will post again with correct url

@Grid21 @casanovarodrigo @dnaka91 @DachsbauTV

Please test this latest version and report back with your obs logs along with any crash dumps if they happen (they shouldn't, fingers crossed)

tt2468 avatar Mar 05 '21 01:03 tt2468