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 : running wasmer aot file #5006

Closed
Franky45 opened this issue Aug 12, 2024 · 2 comments
Closed

error : running wasmer aot file #5006

Franky45 opened this issue Aug 12, 2024 · 2 comments
Assignees

Comments

@Franky45
Copy link

Franky45 commented Aug 12, 2024

image (6)

Describe the bug

```sh

wasmer -vV:
wasmer 4.3.1 (d5df452 2024-05-23)
binary: wasmer-cli
commit-hash: d5df452
commit-date: 2024-05-23
host: x86_64-unknown-linux-gnu
compiler: singlepass,cranelift,llvm

rustc -vV:
rustc 1.80.1 (3f5fd8dd4 2024-08-06)

binary: rustc

commit-hash: 3f5fd8dd41153bc5fdca9427e9e05be2c767ba23

commit-date: 2024-08-06

host: x86_64-unknown-linux-gnu

release: 1.80.1

LLVM version: 18.1.7

 
 
### Steps to reproduce
<!--
Include steps that will help us recreate the issue.
 
to compile wasmer to aot 
$ wasmer compile hi.wasm -o hi.wasmc
 
To run :
 
 
 
If applicable, add a link to a test case (as a zip file or link to a repository we can clone).
-->
 
### Expected behavior
<!-- A clear and concise description of what you expected to happen. -->
 
### Actual behavior
 
<!--
A clear and concise description of what actually happened.
 
If applicable, add screenshots to help explain your problem.
-->
 
### Additional context
<!-- Add any other context about the problem here. -->

in this format upload ypur bug
 
 
for the bug report! -->
 
### Describe the bug
 
<!--
After compiling wamser to aot (i.e, wasmc), when running the .wasmc  i am getting error 
 
 attach sccrenshot
 
Copy and paste the result of executing the following in your shell, so we can know the version of wasmer, Rust (if available) and architecture of your environment.
-->```sh
wasmer -vV: 
wasmer 4.3.1 (d5df452 2024-05-23)
binary: wasmer-cli
commit-hash: d5df452d22110593f12fcc0e152a0435344b6590
commit-date: 2024-05-23
host: x86_64-unknown-linux-gnu
compiler: singlepass,cranelift,llvm

rustc -vV:
rustc 1.80.1 (3f5fd8dd4 2024-08-06)

binary: rustc

commit-hash: 3f5fd8dd41153bc5fdca9427e9e05be2c767ba23

commit-date: 2024-08-06

host: x86_64-unknown-linux-gnu

release: 1.80.1

LLVM version: 18.1.7

Steps to reproduce

Expected behavior

Should execute the .wasmc file

Actual behavior

error: module hash is not present in the artifact

@xdoardo xdoardo changed the title error : running wamer aot file error : running wasmer aot file Aug 12, 2024
@zhangchaoza
Copy link

I had the same problem. I checked the code and I guess that the hash option was not set to engine in fact, it was just set to the clone of the engine. So, the module is missing its hash.

let mut engine = store.engine().clone();
let hash_algorithm = self.hash_algorithm.unwrap_or_default().into();
engine.set_hash_algorithm(Some(hash_algorithm));

@maminrayej
Copy link
Contributor

maminrayej commented Aug 29, 2024

Closing as the fix for this is merged (#5039) and will be available in the next release of Wasmer.

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

4 participants