Skip to content

skills: recover a blocked popup without replacing the current page - #384

Open
ankitranjan7 wants to merge 1 commit into
mainfrom
skills/popup-newpage-recovery
Open

skills: recover a blocked popup without replacing the current page#384
ankitranjan7 wants to merge 1 commit into
mainfrom
skills/popup-newpage-recovery

Conversation

@ankitranjan7

Copy link
Copy Markdown
Contributor

Description

Closes #383.

When a click should open another tab and no popup appears, agents currently recover with page.goto on the bound page. That replaces the opener (iframes, form state, original URL) and is not a new tab.

This is general skill guidance:

  • Arm waitForEvent('popup') with a short timeout before the click.
  • If a page appears, read it.
  • If none appears, context.newPage() — never page.goto on the opener.
  • Do not burn the whole browser run timeout waiting for a popup that will not fire.

Published skill text names no eval fixture, site, or demo URL. Author-only learnings stay in skill-src and are stripped by LitPrompt.

Type of Change

  • 🐛 Bug fix
  • ✨ New feature
  • 🌐 New site adapter
  • 📝 Documentation
  • ♻️ Refactor
  • 🔧 CI / build / tooling

Checklist

  • I ran the checks relevant to this PR
  • I updated tests or docs if needed
  • I included output or screenshots when useful
  • If I edited skill-src/, I ran make build and committed skills/

Screenshots / Output

make build: ok: built 21 file(s)
make check: ok: 21 file(s) checked
make verify: ok: published files are in sync
npx vitest run --project unit src/skills.test.ts: 16 passed

When window.open is swallowed, do not page.goto on the opener.
Cap waitForEvent('popup') and open a tracked tab with context.newPage().

Closes #383
@github-actions

Copy link
Copy Markdown
Contributor

🟠 Maintainer review suggested — low confidence

The automated review could not reach a fully supported conclusion.

Limitations

  • The automated review returned an invalid structured result.

This review is advisory and does not block merging.

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.

skills(browser): recover a blocked popup without replacing the current page

1 participant