I'm having problems initialising the HERE SDK for Flutter with the latest version of the Explore SDK and iOS 17 on a physical device, while on the simulator it works.
This is the initialisation method
void _initializeHERESDK(String hereApiKeySecret) async {
// Needs to be called before accessing SDKOptions to load necessary libraries.
SdkContext.init(IsolateOrigin.main);
// Set your credentials for the HERE SDK.
String accessKeyId = "<myAccessKey>";
SDKOptions sdkOptions = SDKOptions.withAccessKeySecret(accessKeyId, hereApiKeySecret);
try {
await SDKNativeEngine.makeSharedInstance(sdkOptions);
} on InstantiationException {
throw Exception("Failed to initialize the HERE SDK.");
}
}
The line that seems to break the app and reboot the phone is this one
await SDKNativeEngine.makeSharedInstance(sdkOptions);
I'm using Flutter 3.13.8 and the Explore edition 4.16.1.0 released on 23 Oct 2023.
I also tried to add just the initialisation method to the Flutter demo app and calling it when a button is pressed instead of calling it in the initState but it still rebooted the phone.
Turns out the problem was the Flutter version, reverting to 3.10.5 fixed the problem