Skip to content

Warn when a previous elevated session blocks browser sources - #6370

Open
summeroff wants to merge 1 commit into
stagingfrom
fix/elevated-stale-server-dialog
Open

summeroff wants to merge 1 commit into
stagingfrom
fix/elevated-stale-server-dialog

Conversation

@summeroff

@summeroff summeroff commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Problem: An elevated leftover obs64 can't be stopped by a non-elevated Desktop, so browser sources are silently unavailable. A forced shutdown also made crash-handler show a misleading crash dialog.

Change: At startup, if the natives report an unkillable stale server, show a one-time warning (close the previous session or run as administrator); startup continues. forceShutdown now tells crash-handler the exit is intended.

Effect: Users see why browser sources are missing; no false crash dialog on forced shutdown.

Needs osn and crash-handler version bumps (via the bump script); until then both calls are no-ops. Related: crash-handler streamlabs/crash-handler#139, osn streamlabs/obs-studio-node#1830.

Tests: tsc --noEmit 0 errors; eslint/prettier clean; app-shutdown unit tests 10/10.
Not verified: Desktop not launched; dialog not seen on screen (needs new natives).

🤖 Generated with Claude Code

A leftover elevated obs64 cannot be stopped by a non-elevated Desktop, so browser sources were silently unavailable. Show a one-time warning at startup instead. Also mark forced shutdowns as intended so crash-handler does not show a misleading crash dialog.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings November 3, 2026 00:12

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

On Windows, app.exit(0) can terminate the process before the asynchronous shutdown-intent message is delivered, leaving forced shutdown able to trigger a misleading crash dialog.

1 open issue
What changed in this PR

This PR adds a startup warning when a leftover elevated OBS process blocks browser sources and attempts to prevent misleading crash dialogs during forced shutdown. Both integrations require updated native dependencies.

Changes:

  • Display a localized warning while allowing startup to continue.
  • Call the optional crash-handler shutdown-intent API before exiting.
  • Guard new API calls for compatibility with older dependencies.
File Description
main.js Adds shutdown-intent notification to forced shutdown.
app/​i18n/​en-US/​app.json Adds English text for the startup warning.
app/​app.ts Detects an unkillable stale server and displays the warning.

Review effort: Balanced

Comment thread main.js
Comment on lines +371 to +372
if (typeof crashHandler.markShutdownIntent === 'function') {
crashHandler.markShutdownIntent(process.pid);
@bundlemon

bundlemon Bot commented Nov 3, 2026

Copy link
Copy Markdown

BundleMon

Files added (4)
Status Path Size Limits
✅ renderer.(hash).js
+10.77MB -
✅ vendors~renderer.(hash).js
+4.65MB -
✅ updater.js
+115.29KB -
✅ guest-api.js
+40.23KB -

Total files change +15.58MB

Final result: ✅

View report in BundleMon website ➡️


Current branch size history

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants