Core runtime crashes when opening geodatabase file

3636
13
Jump to solution
05-07-2014 11:46 AM
JamesRichards1
Occasional Contributor
I created a geodatabase file in ArcMap using the Share As - Runtime Content menu option. After sideloading the geodatabse to a sample app, the app is crashing when attempting to open the file with the code:

NSString *gdbPath = [self gdbDocumentsPath]; NSError *error = nil; self.geodatabase = [[AGSGDBGeodatabase alloc] initWithPath:gdbPath error:&error]; if (error) {     NSLog(@"error loading geodatabase: %@", [error localizedDescription]); }


The crash is logged to the XCode Console as:

libc++abi.dylib: terminating with uncaught exception of type Esri_runtimecore::Geodatabase::geodatabase_error: std::exception


A few notes:

  • The mxd passed validation (i.e. - Analyze) prior to sharing the runtime content and no warnings or errors were given

  • I would expect an NSError to be passed back from the initWithPath:error: method, but instead the app never gets beyond this line - It just crashes

  • The console log message gives no clue as to what the problem might be

  • I also tried publishing the mxd to a Feature Service, and creating the geodatabase replica via ArcGIS Server and got the same result

By repeatedly removing layers from my mxd and recreating the geodatabase I have narrowed the problem down to some specific layers. I can provide a runtime geodatabase with one of these layers if you need it to reproduce the error.

Cheers,
James
0 Kudos
1 Solution

Accepted Solutions
SuganyaBaskaran1
Esri Contributor
James,
The issue might be with 'FACILITYDIAGRAM' field in the feature class. This field is declared as 32 bit int, where as many of its subtypes have the default value of float. It might have happened if you typed 0.0 instead of 0 in one of the previous versions of the destop.

Can you try reassigning the default values in ArcCatalog and try creating the runtime package again?

Hope this helps!

View solution in original post

0 Kudos
13 Replies
SuganyaBaskaran1
Esri Contributor
Can you provide these details?
1) Are you including the geodatabase in your app bundle or in documents folder?
2) Are you testing with simulator or device? If device, can you try with simulator and tell what happens?

Yes, do share the geodatabase
0 Kudos
JamesRichards1
Occasional Contributor
Hi,

1. I am including the geodatabase in the app bundle and copying it to the documents folder on startup.

2. I was testing in the simulator. I tried on a device and the app does not crash. Instead an NSError is returned and the following is logged to the XCode Console:

error loading geodatabase: The operation couldn�??t be completed. (com.esri.arcgis.runtime.error error 19.)


Is there documentation for the error codes that might be returned such as "error 19"?

I will send you a PM with a link to the geodatabase file.

Thanks for your help!

Cheers,
James
0 Kudos
JamesRichards1
Occasional Contributor
I tried to send you a private message with a link to download the geodatabase file but you have private messaging disabled. Can you provide an alternate way for me to get the file to you? I cannot post the data publicly.

Thanks,
James
0 Kudos
SuganyaBaskaran1
Esri Contributor
Please try now.
0 Kudos
JamesRichards1
Occasional Contributor
Message sent.

Thanks,
James
0 Kudos
MichaelDavis3
Occasional Contributor III
Also experiencing this issue with a geodatabase created using the desktop workflow.

Geodatabase contains one polygon layer
0 Kudos
MichaelDavis3
Occasional Contributor III
Just updated to 12.2.3 and the error changed.  New error is:

2014-05-09 13:58:48.747 AGDC-CSurvey[92497:60b] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'This AGSFeatureTable is backed by a non-spatial table. A spatial table is required to be rendered in a layer.'
0 Kudos
SuganyaBaskaran1
Esri Contributor
James,
The issue might be with 'FACILITYDIAGRAM' field in the feature class. This field is declared as 32 bit int, where as many of its subtypes have the default value of float. It might have happened if you typed 0.0 instead of 0 in one of the previous versions of the destop.

Can you try reassigning the default values in ArcCatalog and try creating the runtime package again?

Hope this helps!
0 Kudos
SuganyaBaskaran1
Esri Contributor
Also experiencing this issue with a geodatabase created using the desktop workflow.

Geodatabase contains one polygon layer


Micheal,
This seems to be a different issue. This error is returned if you try to add a non-spatial table to a AGSFeatureTableLayer. Can you confirm this in your data?

If the issue still exists, can you share your data?
0 Kudos