Open Closed

Blazor - 'System.Runtime.CompilerServices.SuppressIldasmAttribute.SuppressIldasmAttribute()' in assembly #662


User avatar
1
alper created
Support Team Director

I got the following error while publishing the Blazor project:

System.Runtime.CompilerServices.SuppressIldasmAttribute.SuppressIldasmAttribute()


4 Answer(s)
  • User Avatar
    0
    alper created
    Support Team Director

    Add the following line to your Blazor.csproj

    <PublishTrimmed>false</PublishTrimmed>
    

  • User Avatar
    0
    alper created
    Support Team Director

    @david.hurtado gets error when publishing his Blazor app. Reported here https://support.abp.io/QA/Questions/626/Bugs--Issues-v4X#answer-483f87d2-bff9-c59b-c696-39f95f90af2e

    @david can you create a new empty Blazor app and add <PublishTrimmed>false</PublishTrimmed> then publish it to your server? we will understand if the issue is in your code or in the app-template, then we'll solve the problem.

  • User Avatar
    0
    david.hurtado created

    @alper Thanks for your help and suggets. I gonna probe that option.

    I wan to make aditional comment We had been make a publish with ABP 3.3.1 on comunity version. And we don't get this errors. For Commercial ABP 4.0.0 with dot net 5, the numbers of files has incremented sifnificative, and is on this version when staring this errors.

  • User Avatar
    0
    alper created
    Support Team Director

    I guess you'll also get this in the community version. The reason is probably "Tree Shaking" is not workng as expected in Blazor. And there are reflection usages in the ABP framework. Due to the use of reflection, it just cannot make a stable tree shaking. https://github.com/dotnet/aspnetcore/issues/28546

    Until Microsoft fixes this, we can disable tree-shaking temporarily.

Made with ❤️ on ABP v9.1.0-preview. Updated on November 11, 2024, 11:11