-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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][AOT] AOT Compilation failed for method 'void System.IO.Strategies.Net5CompatFileStreamStrategy:Dispose (bool)'. #50609
Comments
I couldn't figure out the best area label to add to this issue. If you have write-permissions please help me learn by adding exactly one area label. |
And it's caused by a filter.... Line 175 in 5b4d984
|
Tagging subscribers to this area: @carlossanlop Issue DetailsDescriptionWhen running an application with WebAssembly Full AOT, the following exception happens at runtime:
Not sure to produce a repro for this one, as there's no stack trace because of AOT. Will try to get one from the newer js-based exception tracing. edit: Unfortunately, adding :
does not raise this type of exceptions in a way that can be shown in browser logs. ConfigurationRegression?Not sure. Other information
|
Tagging subscribers to 'arch-wasm': @lewing Issue DetailsDescriptionWhen running an application with WebAssembly Full AOT, the following exception happens at runtime:
Not sure to produce a repro for this one, as there's no stack trace because of AOT. Will try to get one from the newer js-based exception tracing. edit: Unfortunately, adding :
does not raise this type of exceptions in a way that can be shown in browser logs. ConfigurationRegression?Not sure. Other information
|
@HavenDV which |
Yes, this is for FullAOT. Other settings: <Project Sdk="Microsoft.NET.Sdk.Web">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net5.0</TargetFramework>
<RootNamespace>Dedoose</RootNamespace>
<ApplicationIcon>icon.ico</ApplicationIcon>
<NoWarn>($NoWarn);NU1701;CS8669;Uno0001</NoWarn>
</PropertyGroup>
<PropertyGroup Label="WASM">
<WasmHead>true</WasmHead>
<WasmShellEnableLongPathSupport>false</WasmShellEnableLongPathSupport>
<DefineConstants>$(DefineConstants);__WASM__</DefineConstants>
<MonoRuntimeDebuggerEnabled Condition=" '$(Configuration)' == 'Debug' ">true</MonoRuntimeDebuggerEnabled>
<WasmShellILLinkerEnabled>false</WasmShellILLinkerEnabled>
<WasmShellMonoRuntimeExecutionMode Condition=" '$(Configuration)' == 'Release' ">FullAOT</WasmShellMonoRuntimeExecutionMode>
</PropertyGroup>
<ItemGroup>
<LinkerDescriptor Include="LinkerConfig.xml" />
<Content Include="..\..\shared\Dedoose.Apps.Uno.Shared\Assets\*.png" Link="Assets\%(FileName)%(Extension)" />
<Content Include="LinkerConfig.xml" />
<EmbeddedResource Include="WasmCSS\Fonts.css" />
<EmbeddedResource Include="WasmScripts\AppManifest.js" />
<UpToDateCheckInput Include="..\..\shared\Dedoose.Apps.Uno.Shared\**\*.xaml" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Microsoft.Windows.Compatibility" Version="5.0.0" />
<PackageReference Include="ReactiveUI.Uno" Version="13.3.2" />
<PackageReference Include="Uno.Microsoft.Toolkit.Uwp.UI.Controls.Core" Version="7.1.0-build.2.g0e224f133a" />
<PackageReference Include="Uno.Microsoft.Toolkit.Uwp.UI.Controls.DataGrid" Version="7.1.0-build.2.g0e224f133a" />
<PackageReference Include="Uno.Microsoft.Toolkit.Uwp.UI.Controls.Layout" Version="7.1.0-build.2.g0e224f133a" />
<PackageReference Include="Uno.Microsoft.Xaml.Behaviors.Uwp.Managed" Version="2.0.3-uno.95" />
<PackageReference Include="Uno.UI.WebAssembly" Version="3.8.0-dev.241" />
<PackageReference Include="Uno.Wasm.Bootstrap" Version="2.1.0" />
<PackageReference Include="Uno.Wasm.Bootstrap.DevServer" Version="2.1.0" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\libs\Dedoose.Apps.Core\Dedoose.Apps.Core.csproj" />
</ItemGroup>
<Import Project="..\..\shared\Dedoose.Apps.Shared\Dedoose.Apps.Shared.projitems" Label="Shared" />
<Import Project="..\..\shared\Dedoose.Apps.Uno.Shared\Dedoose.Apps.Uno.Shared.projitems" Label="Shared" />
</Project> |
As of today, until exception filtering is supported, the Also, disabling the linker is not a good idea when building with AOT enabled, as it will generate excessive amounts of code that will not be used by the app. |
Yes I understand this. But, before I take the time to create the LinkerConfig, I wanted to make sure everything works without it.
|
I order to troubleshoot the mismatch error, you'll need to add the following property: <PropertyGroup>
<WasmShellEnableEmccProfiling>true</WasmShellEnableEmccProfiling>
</PropertyGroup> This will show the full stack trace of the error, so it can be analyzed. As for the |
Looks like an issue with ReactiveUI, since Linq.Expressions are heavily used there
Trying to use <MonoRuntimeMixedModeExcludedAssembly Include="ReactiveUI" /> |
Next errors: Trying to use <MonoRuntimeMixedModeExcludedAssembly Include="System.Reactive" />
<MonoRuntimeMixedModeExcludedAssembly Include="System.Reactive.Linq" /> P.S. Yes, it works with <MonoRuntimeMixedModeExcludedAssembly Include="ReactiveUI" />
<MonoRuntimeMixedModeExcludedAssembly Include="System.Reactive" />
<MonoRuntimeMixedModeExcludedAssembly Include="DynamicData" /> |
Landed here by the following readme: https://github.com/unoplatform/Uno.Wasm.Bootstrap#full-aot-mode This has been removed [?] |
@andreakarasho The issue is actually wider than that, as for now, the runtime needs the use of the interpreter for parts of Exception Handling. That dependency has been drastically reduced in net7, but it is still needed (@vargaz may be able to confirm). That being said, current AOT mode which compiles everything it can is pretty close to FullAOT, so the performance is not as impacted as it once was in net6. |
This is probably fixed now. All methods with filters are now AOTed. |
Are the exception handlers/finally fully AOTed as well ? I though there were still some small interpreted portions. |
The finally code will be AOTed, and run using AOT in the non-exception case, and using the interpreter in the exception case. |
Description
When running an application with WebAssembly Full AOT, the following exception happens at runtime:
Not sure to produce a repro for this one, as there's no stack trace because of AOT. Will try to get one from the newer js-based exception tracing.
edit: Unfortunately, adding :
does not raise this type of exceptions in a way that can be shown in browser logs.
Configuration
2784aad
Regression?
Not sure.
Other information
The text was updated successfully, but these errors were encountered: