-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Wasm build hangs when using WasmEdge #85429
Comments
Tagging subscribers to 'arch-wasm': @lewing Issue DetailsDescriptionI have been kicking the tyres on dotnet wasm builds using the As I understand work in that area has moved away from dotnet/dotnet-wasi-sdk. If this issue has potentially been fixed am I able to test it in a preview or nightly build? I like to check in on this tracking issue but I'm not sure if any of this work is made available for us to use/test? If there isn't a known fix then I just wanted to flag this since docker now supports wasmedge but not wasmtime as far as I can tell. For example it would be nice to run this as see the expected output docker container run --rm --runtime=io.containerd.wasmedge.v1 --platform=wasi/wasm my-image:latest Reproduction Stepsusing System.Runtime.InteropServices;
using DateTime = System.DateTime;
namespace WasiConsole;
class Program
{
static void Main(string[] args)
{
Console.WriteLine($"Hello from {RuntimeInformation.OSArchitecture} at {DateTime.Now}");
}
} <Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net7.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Wasi.Sdk" Version="0.1.1" />
</ItemGroup>
</Project> Expected behavior& "C:\Program Files\Wasmtime\bin\wasmtime.exe" .\bin\Debug\net7.0\WasiConsole.wasm & "C:\Users\Scott\Downloads\WasmEdge-0.12.0-windows\bin\wasmedge.exe" .\bin\Debug\net7.0\WasiConsole.wasm Actual behavior& "C:\Program Files\Wasmtime\bin\wasmtime.exe" .\bin\Debug\net7.0\WasiConsole.wasm & "C:\Users\Scott\Downloads\WasmEdge-0.12.0-windows\bin\wasmedge.exe" .\bin\Debug\net7.0\WasiConsole.wasm Regression?No response Known WorkaroundsNo response Configuration.NET SDK 7.0.201 Other informationThis issue may be related but looks like it is more to do with networking rather than hanging
|
/cc @pavelsavara |
probably duplicate dotnet/dotnet-wasi-sdk#5 |
I had a go at running the same console app (renamed) on ubuntu and turns out both wasmtime and wasmedge work fine in that scenario. dotnet build -c Release
wasmtime ./bin/Release/net7.0/cs-hello.wasm
# Hello from Wasm at 04/30/2023 10:20:27
wasmedge ./bin/Release/net7.0/cs-hello.wasm
# Hello from Wasm at 04/30/2023 10:20:54 Since that is the case I do now wonder if its an issue with the wasmedge runtime itself, not .NET. Since this is all new evolving stuff I'm happy if you want to close this issue. If interested, I moved my experiment over to ubuntu and recorded some results here |
Description
I have been kicking the tyres on dotnet wasm builds using the
Wasi.Sdk
nuget package. I have a very simple console app that prints out theRuntimeInformation.OSArchitecture
as a test. When using wasmtime.exe this works fine but when using wasmedge.exe it seems to just hang.As I understand work in that area has moved away from dotnet/dotnet-wasi-sdk. If this issue has potentially been fixed am I able to test it in a preview or nightly build?
I like to check in on this tracking issue but I'm not sure if any of this work is made available for us to use/test?
If there isn't a known fix then I just wanted to flag this since docker now supports wasmedge but not wasmtime as far as I can tell. For example it would be nice to run this as see the expected output
Reproduction Steps
Expected behavior
& "C:\Program Files\Wasmtime\bin\wasmtime.exe" .\bin\Debug\net7.0\WasiConsole.wasm
Hello from Wasm at 04/26/2023 22:25:21
& "C:\Users\Scott\Downloads\WasmEdge-0.12.0-windows\bin\wasmedge.exe" .\bin\Debug\net7.0\WasiConsole.wasm
Hello from Wasm at 04/26/2023 22:25:21
Actual behavior
& "C:\Program Files\Wasmtime\bin\wasmtime.exe" .\bin\Debug\net7.0\WasiConsole.wasm
Hello from Wasm at 04/26/2023 22:25:21
& "C:\Users\Scott\Downloads\WasmEdge-0.12.0-windows\bin\wasmedge.exe" .\bin\Debug\net7.0\WasiConsole.wasm
(hangs)
Regression?
No response
Known Workarounds
No response
Configuration
.NET SDK 7.0.201
Windows 10
Other information
This issue may be related but looks like it is more to do with networking rather than hanging
The text was updated successfully, but these errors were encountered: