我正在将 Suave
应用程序部署到 Azure Web 应用
。应用程序失败并出现以下错误(可在 eventlog.xml
中找到)。
<Event>
<System>
<Provider Name=".NET Runtime"/>
<EventID>1026</EventID>
<Level>0</Level>
<Task>0</Task>
<Keywords>Keywords</Keywords>
<TimeCreated SystemTime="2016-12-13T22:59:39Z"/>
<EventRecordID>-2049111390</EventRecordID>
<Channel>Application</Channel>
<Computer></Computer>
<Security/>
</System>
<EventData>
<Data>
Application: App.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.IO.FileLoadException
Exception Info: System.IO.FileLoadException
at System.ModuleHandle.ResolveType(System.Reflection.RuntimeModule, Int32, IntPtr*, Int32, IntPtr*, Int32, System.Runtime.CompilerServices.ObjectHandleOnStack)
at System.ModuleHandle.ResolveTypeHandleInternal(System.Reflection.RuntimeModule, Int32, System.RuntimeTypeHandle[], System.RuntimeTypeHandle[])
at System.Reflection.RuntimeModule.ResolveType(Int32, System.Type[], System.Type[])
at System.Reflection.CustomAttribute.FilterCustomAttributeRecord(System.Reflection.CustomAttributeRecord, System.Reflection.MetadataImport, System.Reflection.Assembly ByRef, System.Reflection.RuntimeModule, System.Reflection.MetadataToken, System.RuntimeType, Boolean, System.Object[], System.Collections.IList, System.RuntimeType ByRef, System.IRuntimeMethodInfo ByRef, Boolean ByRef, Boolean ByRef)
at System.Reflection.CustomAttribute.GetCustomAttributes(System.Reflection.RuntimeModule, Int32, Int32, System.RuntimeType, Boolean, System.Collections.IList, Boolean)
at System.Reflection.CustomAttribute.GetCustomAttributes(System.Reflection.RuntimeAssembly, System.RuntimeType)
at System.Reflection.RuntimeAssembly.GetCustomAttributes(System.Type, Boolean)
at System.Attribute.GetCustomAttributes(System.Reflection.Assembly, System.Type, Boolean)
at System.AppDomain.GetTargetFrameworkName()
</Data>
</EventData>
</Event>
如何确定丢失的确切文件或导致此问题的原因,以便修复它?
谢谢。
最佳答案
原来是FSharp.Core
nuget包。从 FSharp.Core.3.1.2.5
升级到 FSharp.Core.4.0.0.1
解决了这个问题。我认为应用程序正在搜索 FSharp 4.4.0.0
并且此错误是因为它找到了旧版本。
关于azure - 缩小 Azure 上 FileLoadException 错误的范围,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41132457/