Skip to content

Flutter: error "cannot find definition for import wasi_snapshot_preview1" #59

@jvinai

Description

@jvinai

Hi!

Im making a flutter app that will use a wasm file that uses wasi1 and when i try to use wasm_run_flutter i get this error:

[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: FrbAnyhowException(cannot find definition for import wasi_snapshot_preview1::sched_yield with type Func(FuncType { params: [], results: [I32] }))

It seems it doesnt have wasi1 defintion included.
The code i use is your example code and i load the wasm binary instead of your inline base64 wasm code.
https://github.com/juancastillo0/wasm_run/blob/main/packages/wasm_run_flutter/example/lib/main.dart

Thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions