It appears that the spec is missing a step for the Take Screenshot command to handle user prompts after ensuring there is a browsing context and before taking the screenshot (between steps 1 and 2). There are WPT tests that rely on user prompts being handled (https://wpt.fyi/results/webdriver/tests/take_screenshot/user_prompts.py), so it seems like an accidental omission.
It appears Chrome, Edge, and Firefox already handle these prompts and Safari is the only browser not doing so anyways (we also have another bug preventing us from handling prompts in any test, but we don't even attempt to handle prompts for the take screenshot command currently).
Should the spec be updated, or am I missing something here? If there are no objections I can submit a PR to add the step.
https://w3c.github.io/webdriver/#take-screenshot
It appears that the spec is missing a step for the Take Screenshot command to handle user prompts after ensuring there is a browsing context and before taking the screenshot (between steps 1 and 2). There are WPT tests that rely on user prompts being handled (https://wpt.fyi/results/webdriver/tests/take_screenshot/user_prompts.py), so it seems like an accidental omission.
It appears Chrome, Edge, and Firefox already handle these prompts and Safari is the only browser not doing so anyways (we also have another bug preventing us from handling prompts in any test, but we don't even attempt to handle prompts for the take screenshot command currently).
Should the spec be updated, or am I missing something here? If there are no objections I can submit a PR to add the step.