Document that display-based capture is unavailable on headless - #538
Draft
courtney918 wants to merge 1 commit into
Draft
Document that display-based capture is unavailable on headless#538courtney918 wants to merge 1 commit into
courtney918 wants to merge 1 commit into
Conversation
Live view and replays are already documented as headless limitations, but the screenshot telemetry category and computer-controls screenshots share the same display dependency without saying so. Name the common cause on the headless page, warn on the screenshot category row, and point at the framework-level screenshot call that does work without a display. Also make replay opt-in explicit, so "headful supports replays" isn't read as "headful records automatically."
Contributor
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Workflows to automatically generate PRs for you. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Live view and replays are already documented as unavailable on headless. Two other features share the exact same display dependency and don't say so anywhere:
screenshottelemetry category, described as "Periodic screenshots of the session" with no mode caveatBoth can be enabled on a headless session and accepted, but neither can capture the page — there's no display to capture. Someone debugging a headless session reaches for the screenshot category precisely because it looks like the thing that would help, gets nothing back, and has no way to find out why.
This names the common cause once on the headless page, warns on the category row, and points at the framework-level screenshot call that does work headless (Playwright's
page.screenshot()renders in the page, so it needs no display).Separately:
introduction/create.mdxdescribes headful as supporting "live view, replays, and better stealth," which reads as though headful records automatically. It doesn't — recording is an explicitreplays.start()/replays.stop()pair. Someone who switches to headful expecting a recording gets none and reasonably concludes headful didn't solve their problem. Made the opt-in explicit there and on the replays page.Changes
browsers/headless.mdxbrowsers/telemetry/categories.mdxscreenshotrow headful-only; added a Warning explaining why and what to use insteadbrowsers/replays.mdxintroduction/create.mdxNotes
Docs-only, no code changes. The wording deliberately says the category "can't capture the page" and "won't give you usable frames" rather than claiming it emits nothing — the capture path is display-based either way, but I didn't verify whether it errors out or emits an empty frame, and the docs shouldn't assert more than that.