Skip to content

Correct specification of parallel operations#1431

Open
jugglinmike wants to merge 1 commit intow3c:masterfrom
bocoup:refactor-script-execution
Open

Correct specification of parallel operations#1431
jugglinmike wants to merge 1 commit intow3c:masterfrom
bocoup:refactor-script-execution

Conversation

@jugglinmike
Copy link
Copy Markdown
Contributor

@jugglinmike jugglinmike commented Jul 6, 2019

Prior to this patch, parallelism in the Execute Script and Execute Async
Script commands was expressed in terms of ECMAScript promises. This was
ambiguous because in HTML, Promises rely on an environment settings
object [1], and such an object is not generally available in the
WebDriver execution context.

Refactor the command algorithms to instead manage parallel execution
using the generic "queue" primitive from the Infra specification.
Refactor the "execute a function body" algorithm to use Promises, where
following the invocation of "prepare to run a script," an environment
settings object is available.

[1] https://html.spec.whatwg.org/#integration-with-the-javascript-job-queue


Preview | Diff


This change is Reviewable

Prior to this patch, parallelism in the Execute Script and Execute Async
Script commands was expressed in terms of ECMAScript promises. This was
ambiguous because in HTML, Promises rely on an environment settings
object [1], and such an object is not generally available in the
WebDriver execution context.

Refactor the command algorithms to instead manage parallel execution
using the generic "queue" primitive from the Infra specification.
Refactor the "execute a function body" algorithm to use Promises, where
following the invocation of "prepare to run a script," an environment
settings object is available.

[1] https://html.spec.whatwg.org/#integration-with-the-javascript-job-queue
@jugglinmike
Copy link
Copy Markdown
Contributor Author

We may want to hold off on this until there's consensus in gh-1436.

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.

1 participant