C#: tests in CI are disabled
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 42/100
调研方向
从 CI 配置开始,使用所引用的 wasi-sdk 版本重现 tests/runtime/rust/dylibs/runner.rs 和 tests/runtime/variants/test.cs 中的失败。比较 SDK 29、32 和 34 之间的链接器错误,然后验证可以重新启用 C# 测试,并且受影响的 runtime 和 variants 测试能够成功完成。
由索引模型根据 Issue 内容生成。
描述
In https://github.com/bytecodealliance/wit-bindgen/pull/1699 I'm disabling testing with C# due to failures building tests.
An example failure with wasi-sdk-29 is here:
---- tests/runtime/rust/dylibs/runner.rs ----
component: runner
path: tests/runtime/rust/dylibs/runner.rs
error: failed to compile component "tests/runtime/rust/dylibs/runner.rs"
Caused by:
command execution failed
command: BINDINGS="/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/dylibs/runner-rust/bindings/runner.rs" CARGO_MANIFEST_DIR="tests/runtime/rust/dylibs" "rustc" "--edition=2021" "--target" "wasm32-wasip2" "-Dwarnings" "-Cdebuginfo=1" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/deps" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/quote-53a208424db1e1d7" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/serde_core-0ecc340f22280655" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/proc-macro2-6955ed29c3acce69" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/anyhow-ce8ecf614e24fd86" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/zmij-5e4b739506ce1fa0" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/serde_json-2bddfa072642257e" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/serde-8c4981138e2ed61c" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/prettyplease-3bdb7e6f3ad61c08" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/deps" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/wit-bindgen-rust-ea4e7d82dea7c074" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/wit-bindgen-rust-macro-b2978fab7bdd55a9" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/debug/build/wit-bindgen-a11e78330ba53fc2" "-Ldependency=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug" "-Lnative=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/build/wit-bindgen-41a5941b58e7a593/out" "--extern=wit_bindgen=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/libwit_bindgen.rlib" "--extern=wit_bindgen=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/deps/libwit_bindgen-83c4ea851fcc31f6.rmeta" "--extern=futures=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/libfutures.rlib" "--extern=futures=/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/deps/libfutures-b27c7f5ef205c54f.rmeta" "tests/runtime/rust/dylibs/runner.rs" "-o" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/dylibs/runner-rust.core.wasm" "-Clink-arg=-shared" "-Clink-self-contained=n" "-Clinker=/opt/hostedtoolcache/wasi-sdk-29.0-x86_64-linux/bin/clang" "-L" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/dylibs/runner-rust" "--crate-type=cdylib" "-Clink-arg=-Wl,--skip-wit-component"
status: exit status: 1
stderr:
error: linking with `/opt/hostedtoolcache/wasi-sdk-29.0-x86_64-linux/bin/clang` failed: exit status: 1
|
= note: "/opt/hostedtoolcache/wasi-sdk-29.0-x86_64-linux/bin/clang" "-Wl,--no-export-dynamic" "-Wl,--export" "-Wl,run" "-Wl,--export" "-Wl,cabi_realloc" "-Wl,-z" "-Wl,stack-size=1048576" "-Wl,--stack-first" "-Wl,--no-demangle" "<2 object files omitted>" "-ldylib_dep" "<sysroot>/lib/rustlib/wasm32-wasip2/lib/libpanic_abort-*.rlib" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/libwit_bindgen.rlib" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/deps/{libfutures-b27c7f5ef205c54f,libfutures_executor-922299a107bb047a,libfutures_util-9dc6196014b01a3f,libmemchr-42aea3167221f1c8,libfutures_io-8f5dbb637f9af8fd,libslab-e7bcb3e3d56d11ea,libfutures_channel-e0220edc4c5fb7be,libpin_project_lite-6a517c497ca1cc61,libfutures_sink-47a2cb5e9ef840c0,libfutures_task-df6ab379a1a807af,libfutures_core-f82a2f8330c0d626,libbitflags-860f6eb07a090227}.rlib" "<sysroot>/lib/rustlib/wasm32-wasip2/lib/{libstd-*,libwasip2-*,libwit_bindgen-*,libcfg_if-*,librustc_demangle-*,libstd_detect-*,libhashbrown-*,librustc_std_workspace_alloc-*,libminiz_oxide-*,libadler2-*,libunwind-*,liblibc-*}.rlib" "-lc" "<sysroot>/lib/rustlib/wasm32-wasip2/lib/{librustc_std_workspace_core-*,liballoc-*,libcore-*,libcompiler_builtins-*}.rlib" "--target=wasm32-wasip2" "-L" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/rust/wit-bindgen/target/wasm32-wasip2/debug/build/wit-bindgen-41a5941b58e7a593/out" "-L" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/dylibs/runner-rust" "-o" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/dylibs/runner-rust.core.wasm" "-Wl,--gc-sections" "-static" "-shared" "-nodefaultlibs" "-shared" "-Wl,--skip-wit-component"
= note: some arguments are omitted. use `--verbose` to show all linker arguments
= note: wasm-ld: warning: creating shared libraries, with -shared, is not yet stable
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace.
error: failed to invoke LLD: signal: 11 (SIGSEGV) (core dumped)
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: aborting due to 1 previous error
failures:
tests/runtime/rust/dylibs/runner.rs
an example failure with wasi-sdk-32 is here
---- tests/runtime/variants/test.cs ----
component: test
path: tests/runtime/variants/test.cs
error: failed to compile component "tests/runtime/variants/test.cs"
Caused by:
command execution failed
command: cd "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings" && "/usr/share/dotnet/dotnet" "publish" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj" "-r" "wasi-wasm" "-c" "Debug" "/p:PlatformTarget=AnyCPU" "/p:MSBuildEnableWorkloadResolver=false" "--self-contained" "/p:UseAppHost=false" "-o" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/csharp-testcase"
status: exit status: 1
stdout:
Determining projects to restore...
Restored /home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj (in 1.28 sec).
TestWorld -> /home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/bin/Debug/net10.0/wasi-wasm/csharp-testcase.dll
/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/.packages/microsoft.dotnet.ilcompiler.llvm/10.0.0-rc.1.26357.1/build/Microsoft.NETCore.Native.Wasm.targets(48,5): warning : Wasi SDK version 33.0+m is being used. This differs from the expected 29.0 and might result in build or runtime failures. [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
Generating native code
LLVM compilation to IR finished in 6.14 seconds
LLVM generation of bitcode finished in 0.62 seconds
LLVM generation of debug info finished in 0.11 seconds
Object writing finished in 0.64 seconds, allocated 36.63 MB
wasm-ld : error : --global-base cannot be less than stack size when --stack-first is used [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
EXEC : error : failed to invoke LLD: exit status: 1 [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
clang : error : linker command failed with exit code 1 (use -v to see invocation) [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/.packages/microsoft.dotnet.ilcompiler.llvm/10.0.0-rc.1.26357.1/build/Microsoft.NETCore.Native.targets(616,5): error MSB3073: The command ""/opt/hostedtoolcache/wasi-sdk-33.0-x86_64-linux/bin/clang" @obj/Debug/net10.0/wasi-wasm/native/link.rsp " exited with code 1. [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
and example failure with wasi-sdk-34 is here
---- tests/runtime/variants/test.cs ----
component: test
path: tests/runtime/variants/test.cs
error: failed to compile component "tests/runtime/variants/test.cs"
Caused by:
command execution failed
command: cd "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings" && "/usr/share/dotnet/dotnet" "publish" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj" "-r" "wasi-wasm" "-c" "Debug" "/p:PlatformTarget=AnyCPU" "/p:MSBuildEnableWorkloadResolver=false" "--self-contained" "/p:UseAppHost=false" "-o" "/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/csharp-testcase"
status: exit status: 1
stdout:
Determining projects to restore...
Restored /home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj (in 1.28 sec).
TestWorld -> /home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/bin/Debug/net10.0/wasi-wasm/csharp-testcase.dll
/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/.packages/microsoft.dotnet.ilcompiler.llvm/10.0.0-rc.1.26357.1/build/Microsoft.NETCore.Native.Wasm.targets(48,5): warning : Wasi SDK version 33.0+m is being used. This differs from the expected 29.0 and might result in build or runtime failures. [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
Generating native code
LLVM compilation to IR finished in 6.14 seconds
LLVM generation of bitcode finished in 0.62 seconds
LLVM generation of debug info finished in 0.11 seconds
Object writing finished in 0.64 seconds, allocated 36.63 MB
wasm-ld : error : --global-base cannot be less than stack size when --stack-first is used [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
EXEC : error : failed to invoke LLD: exit status: 1 [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
clang : error : linker command failed with exit code 1 (use -v to see invocation) [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/.packages/microsoft.dotnet.ilcompiler.llvm/10.0.0-rc.1.26357.1/build/Microsoft.NETCore.Native.targets(616,5): error MSB3073: The command ""/opt/hostedtoolcache/wasi-sdk-33.0-x86_64-linux/bin/clang" @obj/Debug/net10.0/wasi-wasm/native/link.rsp " exited with code 1. [/home/runner/work/wit-bindgen/wit-bindgen/target/artifacts/variants/test-csharp/bindings/TestWorld.csproj]
cc @yowl
- 主要语言
- Rust
- 星标
- 1.5k
- 派生
- 306
- 平均合并
- 1 天 4 小时
- 30 天内合并 PR
- 21
环境准备
在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
bytecodealliance/wit-bindgen 的其他 Issue
-
gen-rust
难度 4/5 3-5 天 新手友好度 25/100
bytecodealliance/wit-bindgen#1791 ·
维护者通常 1 天内回复
-
gen-rust
难度 4/5 3-5 天 新手友好度 22/100
bytecodealliance/wit-bindgen#1790 ·
维护者通常 1 天内回复
-
gen-rust
难度 3/5 半天 新手友好度 55/100
bytecodealliance/wit-bindgen#1787 ·
维护者通常 1 天内回复
-
gen-c#
难度 4/5 3-5 天 新手友好度 22/100
bytecodealliance/wit-bindgen#1759 ·
维护者通常 1 天内回复
-
Async exports never free the block of indirect parameters可能已有人在做 @Aditya1404Sal 于 37 天前认领。 未关闭async
难度 4/5 3-5 天 新手友好度 30/100
bytecodealliance/wit-bindgen#1757 ·
维护者通常 1 天内回复
查看 bytecodealliance/wit-bindgen 的全部 Issue
相似的 Issue
-
lane:collections todo:ticket
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 3 天内回复
-
bugfix
难度 2/5 1-3 小时 新手友好度 72/100
storytold/designcraft#3662 ·
维护者通常 1 天内回复
-
documentation
难度 1/5 1-3 小时 新手友好度 88/100
维护者通常 1 天内回复
-
good first issue tooling
难度 2/5 1-3 小时 新手友好度 78/100
Nixitov/Riptide-Native#521 ·
维护者通常 1 天内回复