Skip to content

onboarding: prevent user from skipping login - #6181

Open
wesrupert wants to merge 2 commits into
masterfrom
feat/wr/onboarding/dev
Open

wesrupert wants to merge 2 commits into
masterfrom
feat/wr/onboarding/dev

Conversation

@wesrupert

Copy link
Copy Markdown
Contributor
  • Prevent user from skipping login during onboarding
  • Add some additional checks to AI pages when a user is not signed in

Copilot AI lite review requested due to automatic review settings September 14, 2026 20:32
@wesrupert wesrupert added enhancement P1 high priority to merge from Asana labels Sep 14, 2026

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

Critical and moderate issues remain in onboarding test flows and Vision/AI authentication lifecycle.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

This PR prevents skipping login during onboarding and adds signed-out protections for Streamlabs AI.

Changes:

  • Updates onboarding flow, translations, tests, and helpers.
  • Gates AI settings and landing-page controls by authentication.
  • Prevents or manages Vision startup based on login state.
File summaries
File Summary
test/regular/onboarding.ts Critical (3 votes): Anonymous flow remains on Login while the test proceeds to hardware setup.
test/regular/obs-importer.ts Updates onboarding selectors.
test/helpers/modules/onboarding.ts Critical (3 votes): skipOnboarding cannot skip the logged-out Login step, causing default suites to fail.
app/services/vision/index.ts Moderate (2 votes): Vision may not retry startup after login. Critical (2 votes): Vision remains active after logout.
app/services/onboarding/onboarding-v2.ts Moderate (1 vote): Recording mode can still show Continue on the logged-out login step.
app/i18n/en-US/onboarding.json Adds onboarding translation updates.
app/i18n/en-US/ai.json Adds AI authentication messaging.
app/components-react/windows/settings/AISettings.tsx Gates AI settings for signed-out users.
app/components-react/pages/AILanding.tsx Moderate (2 votes): The page may not rerender when authentication changes, leaving stale AI controls and guards.
app/components-react/modals/onboarding/Splash.tsx Simplifies the onboarding entry point.
Review details

Suppressed comments (2)

app/services/onboarding/onboarding-v2.ts:156

  • isSkippable only controls the Skip link. RecordingLogin is not in NO_BUTTON_STEPS (app/components-react/modals/onboarding/Onboarding.tsx:15), so when recording mode is enabled and the user is logged out the footer still renders Continue; takeStep() can then advance past login (and complete if OBS is absent). Hide Continue for RecordingLogin or require authentication before advancing.
          isSkippable: modifiers.loggedIn,

app/services/vision/index.ts:229

  • This early return does not reconcile Vision with auth transitions. Because the enabled state is persisted, a logged-out startup with AI enabled returns here and never retries after a later login; conversely, logging out while Vision is running does not call stop(), so the process/EventSource can continue for a signed-out user. Tie startup/shutdown to the UserService login/logout lifecycle (or reset the persisted enabled state) so the login requirement holds in both directions.
      if (!this.userService.isLoggedIn) {
        this.log('Vision is not supported for logged-out users.');
        return;
      }
  • Files reviewed: 10/10 changed files
  • Comments generated: 5
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +226 to +229
if (!this.userService.isLoggedIn) {
this.log('Vision is not supported for logged-out users.');
return;
}
if (onboardingAppeared) {
await clickWhenDisplayed('a=Log In', { timeout: 5000 });
await clickWhenDisplayed('button=Skip', { timeout: 5000 });
await clickWhenDisplayed('button=Get Started', { timeout: 5000 });

// Complete login
if (login) {
if (newUser || login) {
const visionActions = VisionService.actions;
const visionState = useRealmObject(VisionService.state);

const isLoggedIn = UserService.views.isLoggedIn;
Comment on lines +226 to +229
if (!this.userService.isLoggedIn) {
this.log('Vision is not supported for logged-out users.');
return;
}
@bundlemon

bundlemon Bot commented Sep 14, 2026

Copy link
Copy Markdown

BundleMon

Files updated (1)
Status Path Size Limits
renderer.(hash).js
10.54MB (-553B -0.01%) -
Unchanged files (3)
Status Path Size Limits
vendors~renderer.(hash).js
4.67MB -
updater.js
115.29KB -
guest-api.js
40.23KB -

Total files change -553B 0%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

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

Labels

enhancement on hold P1 high priority to merge from Asana

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants