-
Notifications
You must be signed in to change notification settings - Fork 98
Made frameId optional #266
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No issues found across 6 files
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 issue found across 1 file (changes from recent commits).
Prompt for AI agents (all issues)
Check if these issues are valid — if so, understand the root cause of each and fix them.
<file name="examples/byob_example.py">
<violation number="1" location="examples/byob_example.py:37">
P1: This example doesn't achieve the stated BYOB (Bring Your Own Browser) goal. The `AsyncStagehand` client uses the default `server="remote"` mode, creating a browser session on Browserbase that is completely independent from the local Playwright browser. These two browsers never share the same page - they're just navigating to the same URLs independently.
To actually demonstrate BYOB, consider using `server="local"` mode, or clarify the example's purpose to show how to coordinate between two separate browser sessions.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
| browserbase_project_id=os.environ.get("BROWSERBASE_PROJECT_ID"), | ||
| model_api_key=os.environ.get("MODEL_API_KEY"), | ||
| ) as client, async_playwright() as playwright: | ||
| browser = await playwright.chromium.launch(headless=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
P1: This example doesn't achieve the stated BYOB (Bring Your Own Browser) goal. The AsyncStagehand client uses the default server="remote" mode, creating a browser session on Browserbase that is completely independent from the local Playwright browser. These two browsers never share the same page - they're just navigating to the same URLs independently.
To actually demonstrate BYOB, consider using server="local" mode, or clarify the example's purpose to show how to coordinate between two separate browser sessions.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At examples/byob_example.py, line 37:
<comment>This example doesn't achieve the stated BYOB (Bring Your Own Browser) goal. The `AsyncStagehand` client uses the default `server="remote"` mode, creating a browser session on Browserbase that is completely independent from the local Playwright browser. These two browsers never share the same page - they're just navigating to the same URLs independently.
To actually demonstrate BYOB, consider using `server="local"` mode, or clarify the example's purpose to show how to coordinate between two separate browser sessions.</comment>
<file context>
@@ -0,0 +1,74 @@
+ browserbase_project_id=os.environ.get("BROWSERBASE_PROJECT_ID"),
+ model_api_key=os.environ.get("MODEL_API_KEY"),
+ ) as client, async_playwright() as playwright:
+ browser = await playwright.chromium.launch(headless=True)
+ page = await browser.new_page()
+ session = await client.sessions.create(model_name="openai/gpt-5-nano")
</file context>
why
Better DX if frameId doesn't need to be passed in.
what changed
test plan
Summary by cubic
Make frameId optional on session actions. If not provided, the client sends an empty string and the server uses the default main frame.
Written for commit fc15135. Summary will update on new commits.