Closed dazinator closed 4 years ago
I'm still seing this linker error when attempting to use flexgrid in a preview 4 project:
C:\Users\DarrellTunnell.nuget\packages\microsoft.aspnetcore.blazor.build\3.1.0-preview4.19579.2\targets\Blazor.MonoRuntime.targets(204,5): error : Unhandled exception. Mono.Linker.MarkException: Error processing method: 'System.Threading.Tasks.Task Microsoft.AspNetCore.Http.Authentication.AuthenticationManager::AuthenticateAsync(Microsoft.AspNetCore.Http.Features.Authentication.AuthenticateContext)' in assembly: 'Microsoft.AspNetCore.Http.Abstractions.dll' [C:\Users\DarrellTunnell\source\repos\Foo\src\Foo\Foo.csproj] C:\Users\DarrellTunnell.nuget\packages\microsoft.aspnetcore.blazor.build\3.1.0-preview4.19579.2\targets\Blazor.MonoRuntime.targets(204,5): error : ILLink failed with exited code -532462766. [C:\Users\DarrellTunnell\source\repos\Foo\src\Foo\Foo.csproj]
It seems Microsoft.AspNetCore.Http.Abstractions.dll
doesn't play nice with the linker.
UPDATE: resolved.
~The only way I managed to fix the linker issue is by adding this to the linker xml:~
<assembly fullname="Microsoft.AspNetCore.Http.Extensions">
<type fullname="Microsoft.AspNetCore.Http.Authentication*" />
</assembly>
~This is a bit nasty. I'm only interested in using the grid in my blazor wasm (client side) project, so being forced to take dependencies on server side scenario stuff (Microsoft.AspNetCore.Http.Extensions has a lot of server side applicable stuff in it) isn't ideal, unless we can have the linker strip out all the uneeded stuff. So my workaround of getting the linker to ignore stuff is probably not ideal!~
Ignore this, was a different issue. This PR works fine.
Ready for review.
Thanks a lot!
Just to be wary, I am still seeing issues when using this in my own project, and I can't work out why.
i am seeing this linker error again:
"C:\Users\DarrellTunnell\source\repos\HubCore\src\Hub.Client\Hub.Client.csproj" (default target) (1:7) -> (_LinkBlazorApplication target) -> C:\Users\DarrellTunnell.nuget\packages\microsoft.aspnetcore.blazor.build\3.1.0-preview4.19579.2\targets\Blazor.MonoRuntime.targets(204,5): error : Unhandled exception. Mono.Linker.MarkException: Error processing method: 'System.Threading.Tasks.Task Microsoft.AspNetCore.Http.Authentication.AuthenticationManager::AuthenticateAsync(Microsoft.AspNetCore.Http.Features.Authentication.AuthenticateContext)' in assembly: 'Microsoft.AspNetCore.Http.Abstractions.dll' [C:\Users\DarrellTunnell\source\repos\HubCore\src\Hub.Client\Hub.Client.csproj] C:\Users\DarrellTunnell.nuget\packages\microsoft.aspnetcore.blazor.build\3.1.0-preview4.19579.2\targets\Blazor.MonoRuntime.targets(204,5): error : ILLink failed with exited code -532462766. [C:\Users\DarrellTunnell\source\repos\HubCore\src\Hub.Client\Hub.Client.csproj]
The thing is, even after adding Microsoft.AspNetCore.Http.Abstractions
assembly to the linker it doesn't fix the error. The linker should be ignoring the problematic assembly entirely but it doesn't seem to have an effect. I don't seem to get this error when running the sample project in this repo though.
I see another error because in client side WebAssembly project css stlyes are not loaded properly. I just testing it.
I cannot find any article with breaking changes. Do you have some kind of this article please?
@Mewriick This is the only article I found: https://devblogs.microsoft.com/aspnet/asp-net-core-updates-in-net-core-3-1/
This might be relevent? https://github.com/aspnet/AspNetCore/issues/17596
@Mewriick Ok I have got to the bottom of the linker error. I had an additional dependency in my own application that was still compiled against preview 3. In this case the Linker seems to throw, and ignoring the assembly in the linker config does nothing. I've remedied that now, so this isn't a flexgrid issue.
@dazinator
Ok good, I have to solve this problem with assest and add some note into readme.
Closes #79