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
Updating prompt handling during user script to be consistent #1248
Updating prompt handling during user script to be consistent #1248
Conversation
Section 18 of the spec states that, "When a user prompt appears, it is the task of the subsequent command to handle it." The algorithm for "Executing a function body" (Section 15.2) violates this statement, insisting that the user prompt handler be invoked during the current command, rather than by the subsequent command. Instead, we should immediately abort the execute[Async]Script command, and let the subsequent command handle the user prompt, if any.
webdriver-spec.html
Outdated
@@ -1,4 +1,4 @@ | |||
<!doctype html> | |||
<!doctype html> |
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.
I can’t tell from the raw patch what has actually changed here.
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.
It’s probably the UTF-8 byte marker from the editor I was using, since it’s at the very beginning of the file. I can fix that up if need be, I suppose.
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.
Yeah, we don’t want a BOM there.
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.
Removed in subsequent commit.
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.
This seems OK with me.
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.
Test required.
Test PR located at web-platform-tests/wpt#10401 |
Spec change and tests look good to me, but it would be good if someone from another vendor and an editor would look at this before continue. |
NOTE This PR is intended to spark discussion. It touches on at least two issues already filed against the spec (#1153 and #1135), and should be considered, since user prompt handlers was largely removed from the Level 1 specification.
Section 18 of the spec states that, "When a user prompt appears, it is
the task of the subsequent command to handle it." The algorithm for
"Executing a function body" (Section 15.2) violates this statement,
insisting that the user prompt handler be invoked during the current
command, rather than by the subsequent command. Instead, we should
immediately abort the execute[Async]Script command, and let the subsequent
command handle the user prompt, if any.
Preview | Diff