adoconnection / RazorEngineCore

.NET6 Razor Template Engine
MIT License
585 stars 88 forks source link

Removed explicit loading of netstandard on Linux/OSX only #25

Closed daghb closed 4 years ago

daghb commented 4 years ago

Caused runtime failure on Linux (and most propably OSX)

System.IO.FileNotFoundException: Could not load file or assembly 'netstandard, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.

File name: 'netstandard, Culture=neutral, PublicKeyToken=null'
   at System.Reflection.RuntimeAssembly.nLoad(AssemblyName fileName, String codeBase, RuntimeAssembly assemblyContext, StackCrawlMark& stackMark, Boolean throwOnFileNotFound, AssemblyLoadContext assemblyLoadContext)
   at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
   at System.Reflection.Assembly.Load(AssemblyName assemblyRef, StackCrawlMark& stackMark, AssemblyLoadContext assemblyLoadContext)
   at System.Reflection.Assembly.Load(AssemblyName assemblyRef)
   at RazorEngineCore.RazorEngineCompilationOptions..ctor()
   at RazorEngineCore.RazorEngineCompilationOptionsBuilder..ctor(RazorEngineCompilationOptions options)
   at RazorEngineCore.RazorEngine.Compile(String content, Action`1 builderAction)
   at RazorEngineCore.RazorEngine.<>c__DisplayClass3_0.<CompileAsync>b__0()
   at System.Threading.Tasks.Task`1.InnerInvoke()
   at System.Threading.Tasks.Task.<>c.<.cctor>b__274_0(Object obj)
   at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location where exception was thrown ---
   at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
--- End of stack trace from previous location where exception was thrown ---
adoconnection commented 4 years ago

Done, ill do some linux tests and release new version asap