chinedufn / percy

Build frontend browser apps with Rust + WebAssembly. Supports server side rendering.
https://chinedufn.github.io/percy/
Apache License 2.0
2.27k stars 84 forks source link

The example app crashes #70

Closed michiel-de-muynck closed 5 years ago

michiel-de-muynck commented 5 years ago

How to reproduce:

  1. Go to https://percy-isomorphic.now.sh/?init=42
  2. Click on "Contributors"
  3. Click on "Isomorphic web app"
  4. Click on the "Click me!" button twice.

Result:

I get this error:

Uncaught RuntimeError: memory access out of bounds
    at <alloc::rc::Rc<T> as core::ops::drop::Drop>::drop::ha4cc7db8eac72ced (wasm-function[135]:32)
    at core::ptr::real_drop_in_place::h13b8aa8efd871d72 (wasm-function[120]:3)
    at <(dyn core::ops::function::FnMut(A) .> R + 'static) as wasm_bindgen::closure::WasmClosure>::describe::destroy::h1c9def9cc2c875ba (wasm-function[116]:10)
    at Function.cb (https://percy-isomorphic.now.sh/isomorphic_client.js:367:34)

This happens in both Chrome and Firefox.

chinedufn commented 5 years ago

Hmmmm thanks for the report and the instructions - I can reproduce it.

I'll should be able to take a look later this week and get this fixed.

Thanks!

chinedufn commented 5 years ago

Problem is with this unimplemented piece of the DomUpdater

https://github.com/chinedufn/percy/blob/3a8b10c35869e64e6dbd87141b6e3a2920dd0f12/crates/virtual-dom-rs/src/dom_updater.rs#L105-L106

Once that gets done this should work.

chinedufn commented 5 years ago

This should get fixed by #84

chinedufn commented 5 years ago

Released in virtual-dom-rs = "0.6.1"

chinedufn commented 5 years ago

Hmm no - this is still an issue .. Will need to investigate what's going on ..

chinedufn commented 5 years ago

Oh no it was fixed just wasn't re-deployed properly. Thanks!