[Webkit-unassigned] [Bug 179263] New: WebAssembly: sending module to iframe fails

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Nov 3 12:39:31 PDT 2017


https://bugs.webkit.org/show_bug.cgi?id=179263

            Bug ID: 179263
           Summary: WebAssembly: sending module to iframe fails
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebAssembly
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: jfbastien at apple.com
                CC: fpizlo at apple.com, jfbastien at apple.com,
                    keith_miller at apple.com, mark.lam at apple.com,
                    msaboff at apple.com, rmorisset at apple.com,
                    sbarati at apple.com

There's a WPT test here: https://github.com/w3c/web-platform-tests/blob/master/wasm/wasm_local_iframe_test.html


Which does the following:

<!DOCTYPE html>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="resources/load_wasm.js"></script>
<iframe src="resources/frame.html" id="iframe"></iframe>
<script>
  promise_test(async function() {
    var mod = await createWasmModule();
    assert_true(mod instanceof WebAssembly.Module);
    var ans = await new Promise((resolve, reject) => {
      var iframe = document.getElementById("iframe").contentWindow;
      iframe.postMessage(mod, '*');
      window.addEventListener("message", (reply) => resolve(reply.data), false);
    });
    assert_equals(ans, 43);
  }, "send wasm module to iframe");
</script>


wpt.fyi says that we fail with:

Failure message: promise_test: Unhandled rejection with value: object "DataCloneError (DOM Exception 25): The object can not be cloned."



It seems like we should succeed? We can definitely postMessage to a Worker. I don't understand iframe enough to know why this fails, we should investigate.

-- 
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/20171103/0890c8e2/attachment-0001.html>


More information about the webkit-unassigned mailing list