GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(desktop): fix background tab spawning by Sg312 · Pull Request #6590 · simstudioai/sim

Conversation

@Sg312

@Sg312 Sg312 commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Summary

Fix background tab spawning

Type of Change

  • Bug fix

Testing

Manual

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

greptile-apps[bot] reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@Sg312
Update tab spawning
4033b71
@Sg312
Sg312 requested a review from a team as a code owner August 12, 2026 03:18
@vercel

vercel Bot commented Aug 12, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
docs Skipped Skipped Aug 12, 2026 3:24am

Request Review

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@greptile-apps

greptile-apps Bot commented Aug 12, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

The PR stops browser and terminal automation from spawning replacement background tabs after users select the active surface. It also preserves existing resource selection during background activity and adds concise running-command labels for terminal close confirmations.

  • Reuses the current browser automation tab and terminal shell after user interaction.
  • Keeps resource activity in the background when another resource is selected.
  • Adds and tests describeRunningCommand in the shared terminal protocol.

Confidence Score: 4/5

The browser-tab change should be fixed before merging because unguarded navigation operations can replace a tab after the user has claimed it.

User interaction still marks the active browser tab as claimed, but the changed session selectors return that tab directly and several navigation operations bypass the claim check already used by element actions.

Files Needing Attention: apps/desktop/src/main/browser-agent/session.ts; packages/terminal-protocol/src/index.test.ts

Important Files Changed

Filename Overview
apps/desktop/src/main/browser-agent/session.ts Removes background-tab forking, but leaves navigation operations able to mutate a user-claimed automation tab.
apps/desktop/src/main/terminal/index.ts Reuses the selected terminal for agent operations while retaining command-busy and close protections.
apps/sim/app/workspace/[workspaceId]/home/home.tsx Preserves an existing resource selection and records activity on other agent resources.
packages/terminal-protocol/src/index.ts Adds a bounded best-effort parser for displaying concise running-program names.
packages/terminal-protocol/src/index.test.ts Covers command-label parsing thoroughly but introduces a relative import contrary to repository policy.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  U[User interacts with active browser tab] --> C[Tab marked user-selected]
  C --> A[automationTabId remains on same tab]
  A --> T{Next browser tool}
  T -->|Click/type/scroll| G[User-claim guard rejects action]
  T -->|Navigate/open URL/back/forward| N[Navigation runs without claim guard]
  N --> F[User-visible page or history changes]
Loading

Reviews (1): Last reviewed commit: "Update tab spawning" | Re-trigger Greptile

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

greptile-apps[bot]
greptile-apps Bot reviewed Aug 12, 2026
View reviewed changes
Comment thread apps/desktop/src/main/browser-agent/session.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread packages/terminal-protocol/src/index.test.ts Resolved

Uh oh!

There was an error while loading. Please reload this page.

@Sg312
update import
048c1b1
@vercel
vercel Bot temporarily deployed to Preview August 12, 2026 03:24 Inactive
@Sg312
Sg312 merged commit 380aca2 into staging Aug 12, 2026
28 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@waleedlatif1
waleedlatif1 deleted the improvement-desktop-5 branch August 12, 2026 03:42
@waleedlatif1 waleedlatif1 mentioned this pull request Aug 12, 2026
v0.8.0: desktop app, workflow UI, v2 endpoints #6606
Merged

This branch was previously deployed

1 inactive deployment
Preview — 048c1b16 Deployed Aug 12, 2026 by vercel[bot]
View deployment
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@greptile-apps greptile-apps[bot] greptile-apps[bot] left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@Sg312
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.