DEPRECATED-mapbox-ios-sdk
DEPRECATED-mapbox-ios-sdk copied to clipboard
Add support for error handling
Right now the SDK does not have any support for userland error handlers. It's not possible to catch tile loading errors, api errors or runtime errors with MapBox.
The main delegate RMMapViewDelegate.h only contains user geolocation failure.
Please consider adding reasonable error handling support in next version. From our tests we've concluded that MapBox might fail in some cases due to memory issues, connection problems etc. We'd like to be able to handle that, i.e. reporting problems to the user or silently logging them (i.e. via Crashlytics) for further debugging.
Would something as simple as (a) delegate callback(s) for error situations be reasonable?
Yes, it usually does. I'd expect it to emit error code (and have list of consts for each possible code) along with detailed message on what went wrong.
Cool, I have long considered this mostly wrapped up with https://github.com/mapbox/mapbox-ios-sdk/issues/236 which we punted on, but there is no reason that we can't have a more MBXMapKit-like approach here so that every error situation is reported. Will look into this soon.