See https://bugs.webkit.org/show_bug.cgi?id=237046#c5
Created attachment 452896 [details] Patch
Comment on attachment 452896 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=452896&action=review > Source/WebCore/page/DOMWindow.h:273 > + void printConsoleMessage(const String&, MessageLevel) const; > void printErrorMessage(const String&) const; > + void printWarningMessage(const String&) const; Can these all be private? Is there any caller using them outside the class?
Created attachment 452937 [details] [fast-cq] Patch
Committed r290348 (247666@main): <https://commits.webkit.org/247666@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 452937 [details].
<rdar://problem/89336944>
Reverted r290348 for reason: Broke a test, slowing down EWS. Committed r290399 (247711@trunk): <https://commits.webkit.org/247711@trunk>
Robert reverted r290348 for me as I do not have committer status yet. https://bugs.webkit.org/show_bug.cgi?id=237116 Change seems to have broken "lastConsoleMessage" As it no longer sees the warning.
Turns out there is a debugging feature, Document::setConsoleMessageListener, used for regression tests, that only works with messages sent to the console client through the document. And there was a test depending on using this mechanism to see the console messages from startListeningForDeviceOrientationIfNecessary and startListeningForDeviceMotionIfNecessary. Outside of the tests, there was nothing wrong with this, but it broke the tests. Sadly this means that we have to replace Document::setConsoleMessageListener with a better testing mechanism or keep these messages flowing through the document. My fault for suggesting that we didn’t need to send the messages through the document. Turns out not to be true for this exotic test-only reason.
I’ll do this.