Skip to content

Fix new tab url intercept for aboutblank #772

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

miguelg719
Copy link
Collaborator

why

New tabs opened by popups/link redirects could contain invalid urls

what changed

Avoid tab redirect on main page with an invalid url

test plan

Copy link

changeset-bot bot commented May 22, 2025

🦋 Changeset detected

Latest commit: ca4b2d3

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@miguelg719 miguelg719 marked this pull request as ready for review May 22, 2025 19:56
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR improves browser launch performance and fixes URL handling for new tabs by modifying browser configuration and navigation logic.

  • Added URL validation in lib/handlers/handlerUtils/actHandlerUtils.ts to prevent navigation to 'about:blank' URLs from new tabs
  • Removed performance-impacting Chromium flags (--enable-webgl, --use-gl=swiftshader, etc.) from browser launch config in lib/index.ts
  • Added check in handlePossiblePageNavigation to validate new tab URLs before navigation
  • Maintained existing logging and error handling patterns for consistency

2 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link
Member

@kamath kamath left a comment

Choose a reason for hiding this comment

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

think you might've accidentally brought over old changes

@seanmcguire12 seanmcguire12 self-requested a review May 22, 2025 20:04
@miguelg719 miguelg719 force-pushed the miguel/stg-446-fix-new-tab-url-intercept-for-aboutblank branch from 07509ad to ca4b2d3 Compare May 22, 2025 20:08
@miguelg719 miguelg719 merged commit 64d331d into main May 22, 2025
14 checks passed
@github-actions github-actions bot mentioned this pull request May 22, 2025
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.

3 participants