Skip to content

Fixed Rust sample code for getting event data #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

iChristwin
Copy link

The previous sample code had some syntax errors and also when used in w3bstream as a wasm, results in a error message alloc is nil... wasm trap: wasm 'unreachable' instruction executed.
image

After digging around a bit I found the SDK repo by @DLHTX 👉 https://github.com/machinefi/w3bstream-compile-rust. I was able to use the SDk to successfully execute ws_get_data.

This fix is directly derived from the SDK source code and it works just fine

The previous sample code had some syntax errors and also when used in w3bstream as a `wasm`, results in a error message `alloc is nil`... `wasm trap: wasm 'unreachable' instruction executed`. After digging around a bit I found the SDK repo by @DLHTX 👉 https://github.com/machinefi/w3bstream-compile-rust. I was able to use the SDk to successfully execute `ws_get_data`. 

This fix is directly derived from the SDK source code and it works just fine
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant