[Webkit-unassigned] [Bug 282983] New: REGRESSION(286456 at main) [WebDriver] WebAutomationSessionProxy::evaluateJavaScriptFunction should always be called
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Tue Nov 12 05:23:03 PST 2024
https://bugs.webkit.org/show_bug.cgi?id=282983
Bug ID: 282983
Summary: REGRESSION(286456 at main) [WebDriver]
WebAutomationSessionProxy::evaluateJavaScriptFunction
should always be called
Product: WebKit
Version: WebKit Nightly Build
Hardware: Unspecified
OS: Unspecified
Status: NEW
Severity: Normal
Priority: P2
Component: WebDriver
Assignee: webkit-unassigned at lists.webkit.org
Reporter: lmoura at igalia.com
CC: bburg at apple.com
286456 at main made Messages::WebAutomationSessionProxy::EvaluateJavaScriptFunction use sendWithAsyncReply, but stored the completionHandler only if expectsImplicitCallbackArgument is true.
This results in the sendWithAsyncReply completionHandler never being called if expectsImplicitCallbackArgument is false. For example, when using EvaluateJavaScriptFunction to get the page title.
IIUC, the expectsImplicitCallbackArgument parameter is related to the actual JS function being evaluated having an implicit callback parameter to be called with the result of the evaluation. Something like a promise's "resolve" function, as handled by Source/WebKit/WebProcess/Automation/WebAutomationSessionProxy.js in fact. In this case, expectsImplicitCallbackArgument is not related to the IPC reply itself, which handles the communication inside the browser.
The previous code also guarded the "callbackID" only if expectsImplicitCallbackArgument was true, but did not block as it called a given callbackID unconditionally on WebAutomationSessionProxy::didEvaluateJavaScriptFunction.
Tentative patch incoming.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20241112/534dfc27/attachment.htm>
More information about the webkit-unassigned
mailing list