Foundation.MonoTouchException: Objective-C exception thrown. Name: NSInternalInconsistencyException Reason: Invalid update: invalid number of rows in section 0. The number of rows contained in an existing section after the update (1) must be equal to the number of rows contained in that section before the update (1), plus or minus the number of rows inserted or deleted from that section (0 inserted, 1 deleted) and plus or minus the number of rows moved into or out of that section (0 moved in, 0 moved out).
Native stack trace:
0 CoreFoundation 0x000000010f4cf12b __exceptionPreprocess + 171
1 libobjc.A.dylib 0x0000000110338f41 objc_exception_throw + 48
2 CoreFoundation 0x000000010f4d42f2 +[NSException raise:format:arguments:] + 98
3 Foundation 0x000000010cd6ad69 -[NSAssertionHandler handleFailureInMethod:object:file:lineNumber:description:] + 193
4 UIKit 0x0000000109e5e209 -[UITableView _endCellAnimationsWithContext:] + 19416
5 UIKit 0x0000000109e79075 -[UITableView endUpdates] + 75
6 MyPasswords.iOS 0x00000001098739b9 xamarin_dyn_objc_msgSend + 217
7 ??? 0x0000000127bb38c2 0x0 + 4961548482
at ObjCRuntime.Runtime.ThrowNSException (System.IntPtr ns_exception) [0x00000] in /Users/builder/data/lanes/5665/6857dfcc/source/xamarin-macios/src/ObjCRuntime/Runtime.cs:362
at ObjCRuntime.Runtime.throw_ns_exception (System.IntPtr exc) [0x00000] in /Users/builder/data/lanes/5665/6857dfcc/source/xamarin-macios/runtime/Delegates.generated.cs:130
at at (wrapper native-to-managed) ObjCRuntime.Runtime:throw_ns_exception (intptr)
at at (wrapper managed-to-native) ObjCRuntime.Messaging:void_objc_msgSend (intptr,intptr)
at UIKit.UITableView.EndUpdates () [0x00008] in /Users/builder/data/lanes/5665/6857dfcc/source/xamarin-macios/src/build/ios/native/UIKit/UITableView.g.cs:294
at Xamarin.Forms.Platform.iOS.ListViewRenderer.UpdateItems (System.Collections.Specialized.NotifyCollectionChangedEventArgs e, System.Int32 section, System.Boolean resetWhenGrouped) [0x0015c] in <13d193f5a21b4e309afc67e0a5508db5>:0
at Xamarin.Forms.Platform.iOS.ListViewRenderer.OnCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x00000] in <13d193f5a21b4e309afc67e0a5508db5>:0
at Xamarin.Forms.Internals.TemplatedItemsList2[TView,TItem].OnCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x0000a] in D:\agent\_work\1\s\Xamarin.Forms.Core\TemplatedItemsList.cs:771
at Xamarin.Forms.Internals.TemplatedItemsList2[TView,TItem].OnProxyCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e, System.Boolean fixWindows) [0x0001a] in D:agent_work1sXamarin.Forms.CoreTemplatedItemsList.cs:981
at Xamarin.Forms.Internals.TemplatedItemsList2[TView,TItem].OnProxyCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x00000] in D:\agent\_work\1\s\Xamarin.Forms.Core\TemplatedItemsList.cs:968
at Xamarin.Forms.ListProxy.OnCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x0000a] in D:\agent\_work\1\s\Xamarin.Forms.Core\ListProxy.cs:233
at Xamarin.Forms.ListProxy+<>c__DisplayClass33_0.<OnCollectionChanged>b__0 () [0x00018] in D:\agent\_work\1\s\Xamarin.Forms.Core\ListProxy.cs:206
at Xamarin.Forms.ListProxy.OnCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x000a0] in D:\agent\_work\1\s\Xamarin.Forms.Core\ListProxy.cs:225
at Xamarin.Forms.ListProxy+WeakNotifyProxy.OnCollectionChanged (System.Object sender, System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x00031] in D:\agent\_work\1\s\Xamarin.Forms.Core\ListProxy.cs:394
at System.Collections.ObjectModel.ObservableCollection1[T].OnCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedEventArgs e) [0x0000f] in /Library/Frameworks/Xamarin.iOS.framework/Versions/11.6.1.2/src/mono/mcs/class/referencesource/System/compmod/system/collections/objectmodel/observablecollection.cs:288
at System.Collections.ObjectModel.ObservableCollection1[T].OnCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedAction action, System.Object item, System.Int32 index) [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/11.6.1.2/src/mono/mcs/class/referencesource/System/compmod/system/collections/objectmodel/observablecollection.cs:351
at System.Collections.ObjectModel.ObservableCollection1[T].RemoveItem (System.Int32 index) [0x0002b] in /Library/Frameworks/Xamarin.iOS.framework/Versions/11.6.1.2/src/mono/mcs/class/referencesource/System/compmod/system/collections/objectmodel/observablecollection.cs:205
at System.Collections.ObjectModel.Collection`1[T].Remove (T item) [0x00027] in /Library/Frameworks/Xamarin.iOS.framework/Versions/11.6.1.2/src/mono/mcs/class/referencesource/mscorlib/system/collections/objectmodel/collection.cs:113
at MyPasswords.ViewModels.EntryViewModel+
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw () [0x0000c] in /Library/Frameworks/Xamarin.iOS.framework/Versions/11.6.1.2/src/mono/mcs/class/referencesource/mscorlib/system/runtime/exceptionservices/exceptionservicescommon.cs:152
at System.Runtime.CompilerServices.AsyncMethodBuilderCore+<>c.
at UIKit.UIKitSynchronizationContext+
at Foundation.NSAsyncActionDispatcher.Apply () [0x00000] in /Users/builder/data/lanes/5665/6857dfcc/source/xamarin-macios/src/Foundation/NSAction.cs:163
at at (wrapper managed-to-native) UIKit.UIApplication:UIApplicationMain (int,string[],intptr,intptr)
at UIKit.UIApplication.Main (System.String[] args, System.IntPtr principal, System.IntPtr delegate) [0x00005] in /Users/builder/data/lanes/5665/6857dfcc/source/xamarin-macios/src/UIKit/UIApplication.cs:79
at UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x00038] in /Users/builder/data/lanes/5665/6857dfcc/source/xamarin-macios/src/UIKit/UIApplication.cs:63
at MyPasswords.iOS.Application.Main (System.String[] args) [0x00001] in /Users/XXX/Projects/MyPasswords/iOS/Main.cs:12
I have A tabbed page and I have the same view in both of them with different data binding source (AllData and Favorites)
I do two tests and one fails:
1)
This one CRUSHES
2)
This one works and I don't understand why. I have saved the two objects in App and I use the App class to update the objects.
To update the Favorites listview
The app crushes
Did you miss the reproduction link?
how could a provide a reproduction link? What should this link opens?
@grammatn can you create/attach a project that demonstrates the exception you are having?
@PureWeen sorry but I don't have the time to do this. I could send you in private a part of it. Can we do this?
Send your reproduction to [email protected]
Full disclosure, full app reproductions are much lower in the priority queue however due to the increased effort in debugging.
@grammatn I don't think we've received your reproduction code yet. When you send it, please be sure to notify us in this ticket. Thanks!
Sorry, I forgot it. Now I sent the code. Thank you for the reminder.
This looks to be the same issue as #1342. There's a workaround on that thread. This is probably related to #1927.
The dependencies from the new xamarin forms versions seems now to cause a lot of issues as I cannot update the xamarin forms because of this bug and therefore I cannot update also the other packages. Do you have any news regarding this one?
What error with the dependencies are you getting specifically? Try deleting all your obj/bin directories before updating to see if that fixes those issues
I am not getting any error.. I have issues which caused because I cannot use the newest Xamarin.Forms version and some Plugins don't support such an old version as this that I am using.
I Have the same issue.
I Have a MasterDetail App.
In the Detail i have A TabbedPage with two Tabs
A View To Search and List of Previous Searches.
When i Start the app (it starts with the Search Tab Open) everything works fine.
When i navigate to another view and then back to that tabbed search page, change the observable collection (binded to the previousList) WITHOUT navigating to it before. the app Crashes with the error shown on top.
Tested on Xamarin.Forms 2.5.0.28055 and VS 15.6.4 btw
@Mr-Pearce do you have a small reproduction project you can share, assuming you are still experience this issue?
@grammatn can you confirm that you are also still experiencing this issue?
Thanks!
Hello,
sorry but I changed the code in order to be able to continue the work. I
couldn't wait ages .
Regards
Nikolaos Grammatikopoulos
Am Do., 14. Juni 2018 um 03:06 Uhr schrieb Samantha Houts <
[email protected]>:
@Mr-Pearce https://github.com/Mr-Pearce do you have a small
reproduction project you can share, assuming you are still experience this
issue?@grammatn https://github.com/grammatn can you confirm that you are also
still experiencing this issue?Thanks!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/xamarin/Xamarin.Forms/issues/1542#issuecomment-397134925,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AVjE72uIv_YAeP7KcYvFDKsZ4vrX0fVNks5t8bcCgaJpZM4RYZLa
.
can someone help me i have this same problem.Thanks