Platform: Windows 10
.NET Version: 4.7.2
I'm unable to run the program either built from source or from the released executable.
Stack Trace (line wraps added for clarity):
2019-05-06 08:51:37,026 INFO ThermoRawFileParser.RawFileParser - Started parsing ./A0002275_1-Bin40_1-L243-1.raw
2019-05-06 08:51:37,145 ERROR ThermoRawFileParser.MainClass - An unexpected error occured:
2019-05-06 08:51:37,148 ERROR ThermoRawFileParser.MainClass - System.TypeInitializationException:
The type initializer for 'ThermoFisher.CommonCore.Data.Business.RawFileReaderFactory' threw an exception. --->
System.IO.FileLoadException: ThermoFisher.CommonCore.RawFileReader.dll is not found in C:\Users\jklein\Downloads\ThermoRawFileParser --->
System.IO.FileLoadException: Could not load file or assembly 'file:///C:\Users\jklein\Downloads\ThermoRawFileParser\ThermoFisher.CommonCore.RawFileReader.dll'
or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515) --->
System.NotSupportedException: An attempt was made to load an assembly from a network location which
would have caused the assembly to be sandboxed in previous versions of the .NET Framework.
This release of the .NET Framework does not enable CAS policy by default, so this load may be dangerous.
If this load is not intended to sandbox the assembly, please enable the loadFromRemoteSources switch.
See http://go.microsoft.com/fwlink/?LinkId=155569 for more information.
--- End of inner exception stack trace ---
at System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
at System.Reflection.RuntimeAssembly.InternalLoadFrom(String assemblyFile, Evidence securityEvidence, Byte[] hashValue, AssemblyHashAlgorithm hashAlgorithm, Boolean forIntrospection, Boolean suppressSecurityChecks, StackCrawlMark& stackMark)
at System.Reflection.Assembly.LoadFrom(String assemblyFile)
at ThermoFisher.CommonCore.Data.ObjectFactory`1.Initialize(Boolean throwExceptions)
--- End of inner exception stack trace ---
at ThermoFisher.CommonCore.Data.ObjectFactory`1.Initialize(Boolean throwExceptions)
at ThermoFisher.CommonCore.Data.Business.RawFileReaderFactory.CreateReader()
at ThermoFisher.CommonCore.Data.Business.RawFileReaderFactory..cctor()
--- End of inner exception stack trace ---
at ThermoFisher.CommonCore.Data.Business.RawFileReaderFactory.ReadFile(String fileName)
at ThermoRawFileParser.RawFileParser.Parse(ParseInput parseInput)
at ThermoRawFileParser.MainClass.Main(String[] args)
Based upon this stack trace, it looks like there is an unresolved dependency for the RawFileReader.dll, since it is present in the same directory as the executable in the release.
A possible solution is to add an XML configuration file with the contents
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<runtime>
<loadFromRemoteSources enabled="true" />
</runtime>
</configuration>
which will get picked up and added to the application config file during the build process. I'm not sure this is desirable though, since it means that the program cannot run "offline".
Platform: Windows 10
.NET Version: 4.7.2
I'm unable to run the program either built from source or from the released executable.
Stack Trace (line wraps added for clarity):
Based upon this stack trace, it looks like there is an unresolved dependency for the
RawFileReader.dll, since it is present in the same directory as the executable in the release.A possible solution is to add an XML configuration file with the contents
which will get picked up and added to the application config file during the build process. I'm not sure this is desirable though, since it means that the program cannot run "offline".