This is a library, written in Rust, for serialization & deserialization of data structures used in Cardano's Haskell implementation of Alonzo along with useful utility functions.
Other
230
stars
124
forks
source link
`BigNumFinalization.unregister is not a function` when running CSL built with `WASM_BINDGEN_WEAKREF` #647
So I built CSL 11.5.0 with WASM_BINDGEN_WEAKREF=1 (or so I hope).
I strayed from the official docs since with nvm use it would have made me install node 12.18.1, which is causing some issues on Mac M1 - hoped I can get a pass on this, since it seems to build fine on node 16 as well.
Then I copy and link the built pkg locally.
Most things seem to work fine, however I'm running into this issue:
TypeError BigNumFinalization.unregister is not a function
error stack:
• cardano_serialization_lib.js:2688 __destroy_into_raw
node_modules/@emurgo/cardano-serialization-lib-nodejs/cardano_serialization_lib.js:2688:24
• cardano_serialization_lib.js:12159 set_asset
node_modules/@emurgo/cardano-serialization-lib-nodejs/cardano_serialization_lib.js:12159:22
• task_queues:96 processTicksAndRejections
node:internal/process/task_queues:96:5
Hi @elkorn ! It's better to check wasm bingen, because we generate all js side code by wasm bingen. You can try to upgrade or downgrade the version probably current one has a bug
Hi! I read https://github.com/Emurgo/cardano-serialization-lib/issues/542 and would like to avoid having to call
.free
on everything if possible.So I built CSL 11.5.0 with
WASM_BINDGEN_WEAKREF=1
(or so I hope). I strayed from the official docs since withnvm use
it would have made me install node 12.18.1, which is causing some issues on Mac M1 - hoped I can get a pass on this, since it seems to build fine on node 16 as well.This is the process I followed:
Then I copy and link the built pkg locally. Most things seem to work fine, however I'm running into this issue:
The "offending" code:
FWIW, my app runs on node 16 as well.
Any advice on this? And am I building the package right?