tauri-sys icon indicating copy to clipboard operation
tauri-sys copied to clipboard

Dependency on `wasm-bindgen` feature `serde_json` can cause circular dependency

Open bicarlsen opened this issue 1 year ago • 2 comments

Currently the crate depends on wasm-bindgen = { version = "0.2.89", features = ["serde_json"] } which can cause a circular dependency as described in aHash and getrandom, and discussed further in wasm-bindgen.

I removed this feature dependency and played with the crate a bit, and everything still seems to work.

Reproduction

I ran into this issue when trying to incorporate SurrealDB into my Tauri app.

Including both surrealdb and tauri-sys caused the issue.

Patched branch

https://github.com/bicarlsen/tauri-sys/tree/fix/wasm_bindgen_serde

bicarlsen avatar Mar 26 '24 13:03 bicarlsen

I ran into the same situation and can confirm that your patched branch works for me too. It would be awesome to get this integrated.

emirror-de avatar Apr 02 '24 08:04 emirror-de

I also ran into the same issue when I enable the feature serde-serialize of wasm-bindgen.

Removed the feature also works for me.

Alex222222222222 avatar Apr 09 '24 09:04 Alex222222222222

This should be resolved with PR #56, please raise another issue if you continue to run into problems.

bicarlsen avatar Jul 13 '24 20:07 bicarlsen