Closed boddumanohar closed 1 year ago
please convert it into number before call it.
The fix doesn't seems solve the isse completely. whenever there is a panic in wasm, the web-apps breatks.
it fixed input panicking issue. but don't catch generic panicking issue in code.
when ever there is an panic within wasm functions, for example:
https://github.com/0chain/gosdk/blob/fc71195dd1e876de6d9d375005aea8a98e8972ae/wasmsdk/allocation.go#L52-L53
In this wasm function,
datashards
is expected to be int. But if you passdataShards
as string, then gowasm crashes and returns an errorTo fix this, the go wasm instance should be able to recover from panic during its execution.