Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: 276241243511562a30091c9cfb1170c9e87642d0 https://github.com/WebKit/WebKit/commit/276241243511562a30091c9cfb1170c9e87642d0 Author: Youenn Fablet <youe...@gmail.com> Date: 2023-09-01 (Fri, 01 Sep 2023)
Changed paths: M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/script-src-wildcard/sharedworker-import.http-expected.txt M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/script-src-wildcard/sharedworker-import.https-expected.txt M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/worker-src-wildcard/sharedworker-import.http-expected.txt M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/worker-src-wildcard/sharedworker-import.https-expected.txt M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/script-src-wildcard/sharedworker-import.http-expected.txt M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/script-src-wildcard/sharedworker-import.https-expected.txt M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/worker-src-wildcard/sharedworker-import.http-expected.txt M LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/worker-src-wildcard/sharedworker-import.https-expected.txt M LayoutTests/imported/w3c/web-platform-tests/wasm/webapi/esm-integration/worker.tentative-expected.txt M LayoutTests/imported/w3c/web-platform-tests/wasm/webapi/esm-integration/worker.tentative.html M LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-import-blob-url.any-expected.txt M LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-import-blob-url.any.worker-expected.txt M LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-parse-error-failure-expected.txt M LayoutTests/imported/w3c/web-platform-tests/workers/modules/shared-worker-import-blob-url.window-expected.txt M LayoutTests/imported/w3c/web-platform-tests/workers/modules/shared-worker-parse-error-failure-expected.txt M Source/WebCore/workers/Worker.cpp M Source/WebCore/workers/Worker.h M Source/WebCore/workers/WorkerGlobalScope.cpp M Source/WebCore/workers/WorkerGlobalScope.h M Source/WebCore/workers/WorkerMessagingProxy.cpp M Source/WebCore/workers/WorkerMessagingProxy.h M Source/WebCore/workers/WorkerReportingProxy.h M Source/WebCore/workers/WorkerThread.cpp M Source/WebCore/workers/service/context/ServiceWorkerThread.cpp M Source/WebCore/workers/shared/SharedWorkerObjectConnection.cpp M Source/WebCore/workers/shared/SharedWorkerObjectConnection.h M Source/WebCore/workers/shared/context/SharedWorkerContextManager.h M Source/WebCore/workers/shared/context/SharedWorkerThreadProxy.cpp M Source/WebCore/workers/shared/context/SharedWorkerThreadProxy.h M Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServer.cpp M Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServer.h M Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerConnection.cpp M Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerConnection.h M Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.cpp M Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.h M Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.messages.in M Source/WebKit/WebProcess/Storage/WebSharedWorkerContextManagerConnection.cpp M Source/WebKit/WebProcess/Storage/WebSharedWorkerContextManagerConnection.h M Source/WebKit/WebProcess/Storage/WebSharedWorkerObjectConnection.messages.in Log Message: ----------- Worker/SharedWorker should fire Event instead of ErrorEvent in case of parsing error https://bugs.webkit.org/show_bug.cgi?id=260900 rdar://problem/114694487 Reviewed by Chris Dumez. In case of parsing error, there is no exception information, so we should not fire an ErrorEvent but an Error as per spec. In WorkerThread, we are now separating the code path. In DedicatedWorker, we are using a specific code path so as to continue adding a message log. In SharedWorker case, we reuse the current code path and use a boolean to tell whether to use ErrorEvent or Error. We update mported/w3c/web-platform-tests/wasm/webapi/esm-integration/worker.tentative.html to not make it timeout and instead fail. This aligns the behavior for this test with Chrome and Firefox. * LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/script-src-wildcard/sharedworker-import.http-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/script-src-wildcard/sharedworker-import.https-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/worker-src-wildcard/sharedworker-import.http-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.http-rp/worker-src-wildcard/sharedworker-import.https-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/script-src-wildcard/sharedworker-import.http-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/script-src-wildcard/sharedworker-import.https-expected.txt: * LayoutTests/imported/w3c/web-platfor* LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/worker-src-wildcard/sharedworker-import.http-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/content-security-policy/gen/top.meta/worker-src-wildcard/sharedworker-import.https-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/wasm/webapi/esm-integration/worker.tentative-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/wasm/webapi/esm-integration/worker.tentative.html: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-import-blob-url.any-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-import-blob-url.any.worker-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-import-referrer-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-import.any-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-import.any.worker-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/dedicated-worker-parse-error-failure-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/shared-worker-import-blob-url.window-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/shared-worker-import.window-expected.txt: * LayoutTests/imported/w3c/web-platform-tests/workers/modules/shared-worker-parse-error-failure-expected.txt: * Source/WebCore/workers/Worker.cpp: (WebCore::Worker::reportError): * Source/WebCore/workers/Worker.h: * Source/WebCore/workers/WorkerGlobalScope.cpp: (WebCore::WorkerGlobalScope::reportErrorToWorkerObject): * Source/WebCore/workers/WorkerGlobalScope.h: * Source/WebCore/workers/WorkerMessagingProxy.cpp: (WebCore::WorkerMessagingProxy::reportErrorToWorkerObject): * Source/WebCore/workers/WorkerMessagingProxy.h: * Source/WebCore/workers/WorkerReportingProxy.h: * Source/WebCore/workers/WorkerThread.cpp: (WebCore::WorkerThread::evaluateScriptIfNecessary): * Source/WebCore/workers/service/context/ServiceWorkerThread.cpp: * Source/WebCore/workers/shared/SharedWorkerObjectConnection.cpp: (WebCore::SharedWorkerObjectConnection::postErrorToWorkerObject): (WebCore::SharedWorkerObjectConnection::postExceptionToWorkerObject): Deleted. * Source/WebCore/workers/shared/SharedWorkerObjectConnection.h: * Source/WebCore/workers/shared/context/SharedWorkerContextManager.h: * Source/WebCore/workers/shared/context/SharedWorkerThreadProxy.cpp: (WebCore::SharedWorkerThreadProxy::postExceptionToWorkerObject): (WebCore::SharedWorkerThreadProxy::reportErrorToWorkerObject): * Source/WebCore/workers/shared/context/SharedWorkerThreadProxy.h: * Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServer.cpp: (WebKit::WebSharedWorkerServer::postErrorToWorkerObject): (WebKit::WebSharedWorkerServer::postExceptionToWorkerObject): Deleted. * Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServer.h: * Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerConnection.cpp: (WebKit::WebSharedWorkerServerConnection::postErrorToWorkerObject): (WebKit::WebSharedWorkerServerConnection::postExceptionToWorkerObject): Deleted. * Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerConnection.h: * Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.cpp: (WebKit::WebSharedWorkerServerToContextConnection::postErrorToWorkerObject): (WebKit::WebSharedWorkerServerToContextConnection::postExceptionToWorkerObject): Deleted. * Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.h: * Source/WebKit/NetworkProcess/SharedWorker/WebSharedWorkerServerToContextConnection.messages.in: * Source/WebKit/WebProcess/Storage/WebSharedWorkerContextManagerConnection.cpp: (WebKit::WebSharedWorkerContextManagerConnection::postErrorToWorkerObject): (WebKit::WebSharedWorkerContextManagerConnection::postExceptionToWorkerObject): Deleted. * Source/WebKit/WebProcess/Storage/WebSharedWorkerContextManagerConnection.h: * Source/WebKit/WebProcess/Storage/WebSharedWorkerObjectConnection.messages.in: Canonical link: https://commits.webkit.org/267546@main _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes