lucasmlp edited issue #10240:
Hi
I'm building Wasmtime C API
v0.38.1
so I can use the binaries inwasm-nginx-module@0.7.0
.
This is the error I'm getting while runningcargo build --release --manifest-path crates/c-api/Cargo.toml
:error[E0061]: this method takes 1 argument but 2 arguments were supplied [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:20:25 [ 86s] | [ 86s] 20 | return file.set_times( [ 86s] | ^^^^^^^^^ [ 86s] 21 | atime.map(SystemTimeSpec::into_std), [ 86s] 22 | mtime.map(SystemTimeSpec::into_std), [ 86s] | ----------------------------------- unexpected argument #2 of type `Option<fs_set_times::SystemTimeSpec>` [ 86s] | [ 86s] note: expected `FileTimes`, found `Option<SystemTimeSpec>` [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:21:17 [ 86s] | [ 86s] 21 | atime.map(SystemTimeSpec::into_std), [ 86s] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [ 86s] = note: expected struct `FileTimes` [ 86s] found enum `Option<fs_set_times::SystemTimeSpec>` [ 86s] note: method defined here [ 86s] --> /home/abuild/rpmbuild/BUILD/rustc-1.84.0-src/library/std/src/fs.rs:1019:12 [ 86s] help: remove the extra argument [ 86s] | [ 86s] 21 - atime.map(SystemTimeSpec::into_std), [ 86s] 21 + /* FileTimes */, [ 86s] | [ 86s] [ 86s] error[E0061]: this method takes 1 argument but 2 arguments were supplied [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:34:25 [ 86s] | [ 86s] 34 | return file.set_times( [ 86s] | ^^^^^^^^^ [ 86s] 35 | atime.map(SystemTimeSpec::into_std), [ 86s] 36 | mtime.map(SystemTimeSpec::into_std), [ 86s] | ----------------------------------- unexpected argument #2 of type `Option<fs_set_times::SystemTimeSpec>` [ 86s] | [ 86s] note: expected `FileTimes`, found `Option<SystemTimeSpec>` [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:35:17 [ 86s] | [ 86s] 35 | atime.map(SystemTimeSpec::into_std), [ 86s] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [ 86s] = note: expected struct `FileTimes` [ 86s] found enum `Option<fs_set_times::SystemTimeSpec>` [ 86s] note: method defined here [ 86s] --> /home/abuild/rpmbuild/BUILD/rustc-1.84.0-src/library/std/src/fs.rs:1019:12 [ 86s] help: remove the extra argument [ 86s] | [ 86s] 35 - atime.map(SystemTimeSpec::into_std), [ 86s] 35 + /* FileTimes */, [ 86s] | [ 86s] [ 86s] For more information about this error, try `rustc --explain E0061`. [ 86s] error: could not compile `cap-primitives` (lib) due to 2 previous errors
I'm using openSUSE Tumbleweed, Cargo 1.83, and Rust 1.83.
It seems like a version mismatch between Wasmtime dependencies and the Rust version, but I can't exactly say what the issue is here.
I used the same environment to build Wasmtimev29.0.1
, and it was built just fine.Can somebody say what the Cargo and Rust version used in Wasmtime
v0.38.1
is?
lucasmlp edited issue #10240:
Hi
I'm building Wasmtime C API
v0.38.1
so I can use the binaries inwasm-nginx-module@0.7.0
.
This is the error I'm getting while runningcargo build --release --manifest-path crates/c-api/Cargo.toml
:error[E0061]: this method takes 1 argument but 2 arguments were supplied [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:20:25 [ 86s] | [ 86s] 20 | return file.set_times( [ 86s] | ^^^^^^^^^ [ 86s] 21 | atime.map(SystemTimeSpec::into_std), [ 86s] 22 | mtime.map(SystemTimeSpec::into_std), [ 86s] | ----------------------------------- unexpected argument #2 of type `Option<fs_set_times::SystemTimeSpec>` [ 86s] | [ 86s] note: expected `FileTimes`, found `Option<SystemTimeSpec>` [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:21:17 [ 86s] | [ 86s] 21 | atime.map(SystemTimeSpec::into_std), [ 86s] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [ 86s] = note: expected struct `FileTimes` [ 86s] found enum `Option<fs_set_times::SystemTimeSpec>` [ 86s] note: method defined here [ 86s] --> /home/abuild/rpmbuild/BUILD/rustc-1.84.0-src/library/std/src/fs.rs:1019:12 [ 86s] help: remove the extra argument [ 86s] | [ 86s] 21 - atime.map(SystemTimeSpec::into_std), [ 86s] 21 + /* FileTimes */, [ 86s] | [ 86s] [ 86s] error[E0061]: this method takes 1 argument but 2 arguments were supplied [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:34:25 [ 86s] | [ 86s] 34 | return file.set_times( [ 86s] | ^^^^^^^^^ [ 86s] 35 | atime.map(SystemTimeSpec::into_std), [ 86s] 36 | mtime.map(SystemTimeSpec::into_std), [ 86s] | ----------------------------------- unexpected argument #2 of type `Option<fs_set_times::SystemTimeSpec>` [ 86s] | [ 86s] note: expected `FileTimes`, found `Option<SystemTimeSpec>` [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:35:17 [ 86s] | [ 86s] 35 | atime.map(SystemTimeSpec::into_std), [ 86s] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [ 86s] = note: expected struct `FileTimes` [ 86s] found enum `Option<fs_set_times::SystemTimeSpec>` [ 86s] note: method defined here [ 86s] --> /home/abuild/rpmbuild/BUILD/rustc-1.84.0-src/library/std/src/fs.rs:1019:12 [ 86s] help: remove the extra argument [ 86s] | [ 86s] 35 - atime.map(SystemTimeSpec::into_std), [ 86s] 35 + /* FileTimes */, [ 86s] | [ 86s] [ 86s] For more information about this error, try `rustc --explain E0061`. [ 86s] error: could not compile `cap-primitives` (lib) due to 2 previous errors
I'm using openSUSE Tumbleweed, Cargo
1.83
, and Rust1.83
.It seems like a version mismatch between Wasmtime dependencies and the Rust version, but I can't exactly say what the issue is here.
I used the same environment to build Wasmtimev29.0.1
, and it was built just fine.Can somebody say what the Cargo and Rust version used in Wasmtime
v0.38.1
is?
bjorn3 commented on issue #10240:
Looks like a
set_times
method got introduced onFile
in 1.75.0. This likely shadowed the impl in cap-primitives. Wasmtime 0.38.1 got released after rustc 1.61. If you want to use this ancient Wasmtime version, you may want to try with rustc 1.61.
alexcrichton closed issue #10240:
Hi
I'm building Wasmtime C API
v0.38.1
so I can use the binaries inwasm-nginx-module@0.7.0
.
This is the error I'm getting while runningcargo build --release --manifest-path crates/c-api/Cargo.toml
:error[E0061]: this method takes 1 argument but 2 arguments were supplied [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:20:25 [ 86s] | [ 86s] 20 | return file.set_times( [ 86s] | ^^^^^^^^^ [ 86s] 21 | atime.map(SystemTimeSpec::into_std), [ 86s] 22 | mtime.map(SystemTimeSpec::into_std), [ 86s] | ----------------------------------- unexpected argument #2 of type `Option<fs_set_times::SystemTimeSpec>` [ 86s] | [ 86s] note: expected `FileTimes`, found `Option<SystemTimeSpec>` [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:21:17 [ 86s] | [ 86s] 21 | atime.map(SystemTimeSpec::into_std), [ 86s] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [ 86s] = note: expected struct `FileTimes` [ 86s] found enum `Option<fs_set_times::SystemTimeSpec>` [ 86s] note: method defined here [ 86s] --> /home/abuild/rpmbuild/BUILD/rustc-1.84.0-src/library/std/src/fs.rs:1019:12 [ 86s] help: remove the extra argument [ 86s] | [ 86s] 21 - atime.map(SystemTimeSpec::into_std), [ 86s] 21 + /* FileTimes */, [ 86s] | [ 86s] [ 86s] error[E0061]: this method takes 1 argument but 2 arguments were supplied [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:34:25 [ 86s] | [ 86s] 34 | return file.set_times( [ 86s] | ^^^^^^^^^ [ 86s] 35 | atime.map(SystemTimeSpec::into_std), [ 86s] 36 | mtime.map(SystemTimeSpec::into_std), [ 86s] | ----------------------------------- unexpected argument #2 of type `Option<fs_set_times::SystemTimeSpec>` [ 86s] | [ 86s] note: expected `FileTimes`, found `Option<SystemTimeSpec>` [ 86s] --> /home/abuild/rpmbuild/BUILD/wasmtime/vendor/cap-primitives-0.24.3/src/rustix/linux/fs/set_times_impl.rs:35:17 [ 86s] | [ 86s] 35 | atime.map(SystemTimeSpec::into_std), [ 86s] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [ 86s] = note: expected struct `FileTimes` [ 86s] found enum `Option<fs_set_times::SystemTimeSpec>` [ 86s] note: method defined here [ 86s] --> /home/abuild/rpmbuild/BUILD/rustc-1.84.0-src/library/std/src/fs.rs:1019:12 [ 86s] help: remove the extra argument [ 86s] | [ 86s] 35 - atime.map(SystemTimeSpec::into_std), [ 86s] 35 + /* FileTimes */, [ 86s] | [ 86s] [ 86s] For more information about this error, try `rustc --explain E0061`. [ 86s] error: could not compile `cap-primitives` (lib) due to 2 previous errors
I'm using openSUSE Tumbleweed, Cargo
1.83
, and Rust1.83
.It seems like a version mismatch between Wasmtime dependencies and the Rust version, but I can't exactly say what the issue is here.
I used the same environment to build Wasmtimev29.0.1
, and it was built just fine.Can somebody say what the Cargo and Rust version used in Wasmtime
v0.38.1
is?
alexcrichton commented on issue #10240:
As @bjorn3 mentioned this is an unsupported version of Wasmtime, so there aren't dedicated resources for providing assistance to this and it's a best-effort basis of volunteers. @bjorn3's diagnosis seems accurate though in that you'll probably need to wrangle rustc versions and/or change versions of dependencies to align with what was used at the time.
Given though that this isn't an issue with a supported version of Wasmtime I'm going to close this. You can feel free to follow-up here though if aligning versions helps.
lucasmlp commented on issue #10240:
Hi @bjorn3
Thanks for the reply. We decided to go another way around this.
Last updated: Feb 28 2025 at 02:27 UTC