Stream: git-wasmtime

Topic: wasmtime / issue #855 Wasi Tutorial Error: Invalid digit ...


view this post on Zulip Wasmtime GitHub notifications bot (Jan 01 2023 at 10:05):

huangjj27 commented on issue #855:

I encounter the exactly same bug with the rust version code, with wasmtime 4.0.0 on windows 11:

  1. use the rust code from the tutorial
  2. make the function process to be pub, and #[no_mangle]
  3. compile the project with cargo wasi build
  4. echo hello world > test.txt
  5. run the command and its return error:
> wasmtime --dir=. target\wasm32-wasi\debug\demo.wasm --invoke process test.txt somewhere.txt
warning: using `--invoke` with a function that takes arguments is experimental and may break in the future
Error: failed to run main module `target\wasm32-wasi\debug\demo.wasm`

Caused by:
    invalid digit found in string

view this post on Zulip Wasmtime GitHub notifications bot (Jan 01 2023 at 10:13):

huangjj27 commented on issue #855:

and I checked out that what #858 has fixed is another bug, and its added a test for a digit param when invoking, but not for a string param, which is the bug I'm encountering now.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 02 2023 at 04:57):

huangjj27 edited a comment on issue #855:

and I checked out that what #858 has fixed is another bug, and it added a test for a digit param when invoking, but not for a string param, which is the bug I'm encountering now.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 02 2023 at 04:58):

huangjj27 edited a comment on issue #855:

I encounter the exactly same bug with the rust version code, with wasmtime 4.0.0 on windows 11:

  1. use the rust code from the tutorial
  2. make the function process to be pub, and #[no_mangle]
  3. compile the project with cargo wasi build
  4. echo hello world > test.txt
  5. run the command and it returns these error:
> wasmtime --dir=. target\wasm32-wasi\debug\demo.wasm --invoke process test.txt somewhere.txt
warning: using `--invoke` with a function that takes arguments is experimental and may break in the future
Error: failed to run main module `target\wasm32-wasi\debug\demo.wasm`

Caused by:
    invalid digit found in string

view this post on Zulip Wasmtime GitHub notifications bot (Jan 02 2023 at 23:29):

huangjj27 commented on issue #855:

I find out another problem with the same bug on stackoverflow, just linking :-}


Last updated: Oct 23 2024 at 20:03 UTC