Support aot?
YahuiWong opened this issue · 6 comments
YahuiWong commented
I publish my dotnet 8 project by aot mode ,
After that the soft can`t working . and print the err msg
log4net:ERROR Exception while reading ConfigurationSettings. Check your .config file is well formed XML.
System.Configuration.ConfigurationErrorsException: Configuration system failed to initialize
---> System.MissingMethodException: No parameterless constructor defined for type 'System.Configuration.ClientConfigurationHost'.
at System.ActivatorImplementation.CreateInstance(Type, Boolean) + 0x119
at System.Configuration.Internal.ConfigSystem.System.Configuration.Internal.IConfigSystem.Init(Type, Object[]) + 0x43
at System.Configuration.ClientConfigurationSystem..ctor() + 0x47
at System.Configuration.ConfigurationManager.EnsureConfigurationSystem() + 0x56
--- End of inner exception stack trace ---
at System.Configuration.ConfigurationManager.PrepareConfigSystem() + 0x35
at System.Configuration.ConfigurationManager.GetSection(String) + 0x18
at System.Configuration.ConfigurationManager.get_AppSettings() + 0x11
at log4net.Util.SystemInfo.GetAppSetting(String) + 0x21
FreeAndNil commented
@YahuiWong please See #142
YahuiWong commented
@YahuiWong please See #142
@FreeAndNil
I do not know,Is #142 have a solution?
FreeAndNil commented
@YahuiWong yes, see my comments and #143
FreeAndNil commented
@YahuiWong please reopen when you have feedback
YahuiWong commented
I have no idea about how to solve it.
Is that I reference log4net need use dll files not nuget?
@FreeAndNil
FreeAndNil commented
I have no idea about how to solve it.
Is that I reference log4net need use dll files not nuget?
@FreeAndNil
@YahuiWong yes, you need to build the dll from the sources in the refrenced branch or use these binaries:
netstandard2.0.zip