Our Xamarin.Varieties iOS utility is experiencing crashes with a selected exception: Deadly Exception: NSInternalInconsistencyException
Modifications to the structure engine should not be carried out from a background thread after it has been accessed from the principle thread. The crashes happen when customers try to scroll the timepicker. Notably, this situation has emerged after customers up to date their iOS units to variations 17.1.1 and 17.1.2.
Regardless of my efforts, I have not been capable of replicate the issue on my bodily gadget or simulator. Nearly all of affected customers are situated within the USA. We depend on Firebase Crashlytics to log these incidents. The connected screenshots are sourced from Crashlytics.
Steps Taken:
I’ve reviewed the threading in my code and ensured that UI updates are achieved on the principle thread.
I’ve tried utilizing Gadget.BeginInvokeOnMainThread, however the situation persists.
{
Gadget.BeginInvokeOnMainThread(() =>
{
DateTime TodayDate = DateTime.Now;
var dateSelect = calender.SelectedDate;
// DateTime MyDateTime = new DateTime(2000, 1, 1).Add(dtPicker.Time);
DateTime MyDateTime = new DateTime(dateSelect.Yr, dateSelect.Month, dateSelect.Day).Add(dtPicker.Time);
if (TodayDate > MyDateTime)
{
string FormatedTime = string.Format("{0: hh:mm tt}", MyDateTime);
ObservationTime.Textual content = FormatedTime + " ";
}
else
{
DisplayAlert(GlobalVariables.FoodAllergyFix, "DateTime can't be greater than present DateTime.", "OK");
dtPicker.Time = TodayDate.TimeOfDay;
string FormatedTime = string.Format("{0: hh:mm tt}", TodayDate);
ObservationTime.Textual content = FormatedTime + " ";
}
});
}```
Has anybody else encountered the same drawback with Xamarin.Varieties and iOS 17.1.1/17.1.2? Any insights into resolving this situation or ideas for additional troubleshooting could be significantly appreciated.
Thanks!