We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cluster/Sources/Cluster.swift
Line 335 in 3c70568
The line of code above triggers UI update via KVO on background thread and it leads to a crash because of precondition.
NSInternalInconsistencyException Modifications to the layout engine must not be performed from a background thread after it has been accessed from the main thread. 0 CoreFoundation __exceptionPreprocess + 220 1 libobjc.A.dylib objc_exception_throw + 56 2 Foundation -[NSISEngine tryToOptimizeReturningMutuallyExclusiveConstraints] + 0 3 Foundation -[NSISEngine withBehaviors:performModifications:] + 32 4 UIKitCore -[UIView(Hierarchy) _postMovedFromSuperview:] + 776 5 UIKitCore -[UIView(Internal) _addSubview:positioned:relativeTo:] + 1600 6 MapKit -[MKAnnotationContainerView addAnnotationView:allowAnimation:] + 1444 7 MapKit -[MKMapView addAnnotationRepresentation:allowAnimation:] + 588 8 MapKit -[MKAnnotationManager _addRepresentationForAnnotation:] + 668 9 MapKit -[MKAnnotationManager updateVisibleAnnotations] + 1008 10 MapKit -[MKAnnotationManager observeValueForKeyPath:ofObject:change:context:] + 996 11 Foundation NSKeyValueNotifyObserver + 288 12 Foundation NSKeyValueDidChange.llvm.18207776532572868477 + 332 13 Foundation NSKeyValueDidChangeWithPerThreadPendingNotifications.llvm.18207776532572868477 + 148 14 Foundation NSKVOForwardInvocation + 336 15 CoreFoundation ___forwarding___ + 676 16 CoreFoundation _CF_forwarding_prep_0 + 92 17 My App closure #3 in ClusterManager.distributeAnnotations(tree:mapRect:) + 824 (Cluster.swift)
The text was updated successfully, but these errors were encountered:
I don't see any preconditions in the framework that could cause this. This is probably a MapKit exception.
Sorry, something went wrong.
Em, yes, exactly. And it forces us to set coordinate of an annotation on the main thread.
I'm seeing this crash in our app as well. Any workarounds?
DispatchQueue.main.async { self.clusterManager.reload(self.mapView) }
No branches or pull requests
Cluster/Sources/Cluster.swift
Line 335 in 3c70568
The line of code above triggers UI update via KVO on background thread and it leads to a crash because of precondition.
The text was updated successfully, but these errors were encountered: