Skip to content
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

error initializing module: invalid import "a.a" #2402

Open
TongMeng-AI opened this issue Mar 18, 2024 · 1 comment
Open

error initializing module: invalid import "a.a" #2402

TongMeng-AI opened this issue Mar 18, 2024 · 1 comment

Comments

@TongMeng-AI
Copy link

No description provided.

@sbc100
Copy link
Member

sbc100 commented Mar 18, 2024

It looks like you are perhaps trying to run a wasm module generated by emscripten with optimizations enabled.

emsripten will minify the names of the import/export between JS and Wasm, assuming that only the generated JS file will ever be loading the wasm file.

If you want to try to load the wasm module yourself without the generated JS then you would want build directly to wasm via -o .wasm (or using -sSTANDALONE_WASM). However, running and emscripten-generated wasm module in wabt is unlikely to work since emscripten-generated modules tend to have a other imports that wabt doesn't provide.

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

No branches or pull requests

2 participants