bilaldursun1 / nettopologysuite

Automatically exported from code.google.com/p/nettopologysuite
0 stars 0 forks source link

GeoAPI.GeometryServiceProvider.GetLoadableTypes throws System.IO.FileNotFoundException #158

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Add some assemblies to you application that contain references that are 
missing.
2. Start up GeoAPI.

What is the expected output? What do you see instead?
The assemblies that have nothing to do with GeoAPI should not cause it to throw 
(and cease to function).  These assemblies may not be required by the 
application and the load is only a side-effect of the reflection process.  
GeoAPI should never (ever) throw when reflecting through unknown assemblies.

What version of the product are you using? On what operating system?
1.7.0.0 on windows 8 and windows XP

Please provide any additional information below.
I catch the file not found exception in the same way that TypeLoadException is 
caught.

Here is the original offending stack trace in my application:

mpossible de charger le fichier ou l'assembly 'DevExpress.XtraReports.v12.2, 
Version=12.2.10.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a' ou une de 
ses dépendances. Le fichier spécifié est introuvable. à 
System.Reflection.RuntimeAssembly.GetExportedTypes(RuntimeAssembly assembly, 
ObjectHandleOnStack retTypes)
à System.Reflection.RuntimeAssembly.GetExportedTypes()
à GeoAPI.GeometryServiceProvider.GetLoadableTypes(Assembly assembly)
à GeoAPI.GeometryServiceProvider.ReflectInstance()
à GeoAPI.GeometryServiceProvider.get_Instance()
à Vigis.Database.PostGisWrapper.ElementProvider.Xki6Y0JtWp(Byte[] , Projection 
, Projection )
à Vigis.Database.PostGisWrapper.ElementProvider.r5Y6Qo1Yxu(DataTable , 
Mnemonic , String , String , String , Int32 )
à 
Vigis.Database.PostGisWrapper.ElementProvider.FillAllManagedCadElements(DataTabl
e dt, Boolean managed)
à Vigis.Database.Table.lB3P5ufnH4PEg5l7WYgy(Object , Object , Boolean )
...

It is a System.IO.FileNotFoundException.

p.s. I also just catch exception, because I don't want GeoAPI crashing my app 
for no reason.

I have simply caught the file not 

Original issue reported on code.google.com by selling...@gmail.com on 18 Sep 2013 at 10:20

GoogleCodeExporter commented 9 years ago
thanks for the report.
fixed with commit 73089: 
http://geoapi.codeplex.com/SourceControl/changeset/73089

Original comment by diegogu...@gmail.com on 1 Oct 2013 at 3:39