Main Thread Checker: UI API called on a background thread: -[UIView setHidden:]
PID: 9947, TID: 1414260, Thread name: (none), Queue name: com.apple.root.default-qos.overcommit, QoS: 21
Backtrace:
4 doctor 0x0000000100d2e80f -[LoginController load:] + 3279
5 Foundation 0x00000001011ba8ac __NSThread__start__ + 1197
6 libsystem_pthread.dylib 0x0000000106ea16c1 _pthread_body + 340
7 libsystem_pthread.dylib 0x0000000106ea156d _pthread_body + 0
8 libsystem_pthread.dylib 0x0000000106ea0c5d thread_start + 13
2017-11-21 14:54:59.253674+0800 doctor[9947:1414260] [reports] Main Thread Checker: UI API called on a background thread: -[UIView setHidden:]
PID: 9947, TID: 1414260, Thread name: (none), Queue name: com.apple.root.default-qos.overcommit, QoS: 21
Backtrace:
4 doctor 0x0000000100d2e80f -[LoginController load:] + 3279
5 Foundation 0x00000001011ba8ac __NSThread__start__ + 1197
6 libsystem_pthread.dylib 0x0000000106ea16c1 _pthread_body + 340
7 libsystem_pthread.dylib 0x0000000106ea156d _pthread_body + 0
8 libsystem_pthread.dylib 0x0000000106ea0c5d thread_start + 13
2017-11-21 14:54:59.379571+0800 doctor[9947:1414260] This application is modifying the autolayout engine from a background thread after the engine was accessed from the main thread. This can lead to engine corruption and weird crashes.
Stack:(
0 Foundation 0x00000001013d5ec6 _AssertAutolayoutOnAllowedThreadsOnly + 77
1 Foundation 0x00000001011dfd7a -[NSISEngine withBehaviors:performModifications:] + 28
2 UIKit 0x000000010240d9fc __57-[UIView(AdditionalLayoutSupport) _switchToLayoutEngine:]_block_invoke + 604
3 UIKit 0x000000010240d778 -[UIView(AdditionalLayoutSupport) _switchToLayoutEngine:] + 223
4 UIKit 0x0000000101954125 __45-[UIView(Hierarchy) _postMovedFromSuperview:]_block_invoke + 112
5 UIKit 0x0000000101954033 -[UIView(Hierarchy) _postMovedFromSuperview:] + 828
6 UIKit 0x000000010196494d -[UIView(Internal) _addSubview:positioned:relativeTo:] + 1973
7 UIKit 0x0000000101ce3461 -[UILayoutContainerView addSubview:] + 75
8 UIKit 0x0000000101a76dee -[UINavigationController _unhideNavigationBarForEdge:] + 99
9 UIKit 0x0000000101a77098 -[UINavigationController _setNavigationBarHidden:edge:duration:] + 208
10 UIKit 0x0000000101a74b1e -[UINavigationController setNavigationBarHidden:animated:] + 141
11 doctor 0x0000000100d2e863 -[LoginController load:] + 3363
12 Foundation 0x00000001011ba8ac __NSThread__start__ + 1197
13 libsystem_pthread.dylib 0x0000000106ea16c1 _pthread_body + 340
14 libsystem_pthread.dylib 0x0000000106ea156d _pthread_body + 0
15 libsystem_pthread.dylib 0x0000000106ea0c5d thread_start + 13
)
besondersNach dem Upgrade auf iOS 11, mein App zerquetscht, es keine Antwort nach dem Login
This application is modifying the autolayout engine from a background
thread after the engine was accessed from the main thread. This can
lead to engine corruption and weird crashes.
dieser Tipp viele Male wiederholt, bis
2017-11-21 14:56:57.993852+0800 doctor[9947:1414234] Received XPC
error Connection interrupted for message type 3
kCFNetworkAgentXPCMessageTypePACQuery
2017-11-21 14:56:57.994722+0800 doctor[9947:1414234] Received XPC error
Connection invalid for message type 3
kCFNetworkAgentXPCMessageTypePACQuery
Dann App zermalmt hat, hat keine Antwort. Und es gibt keine anderen Fehlermeldungen in der Konsole. Jeder Weg, den Vernunftgrund zu kennen und zu lösen. Vielen Dank!
Es scheint, wie, die Sie aktualisieren oder eine Ansicht in Hintergrund-Thread zu verstecken. Können Sie überprüfen, ob dies der Fall ist? Wenn dies der Fall ist, versuchen Sie, diese Methode im Haupt-Thread aufzurufen. –
Mögliches Duplikat von [Diese Anwendung ändert die Auto-Layout-Engine von einem Hintergrundthread, was zu Motorschäden und merkwürdigen Abstürzen führen kann. (Https://stackoverflow.com/questions/31951704/this-application-is-modifying-the- autolayout-engine-from-a-background-thread-wh) –
Wenn Sie Ihren Code in xcode9 kompilieren, wird die Fortschrittszahl für den Fortschritt der Benutzeroberfläche des Hintergrundthread-UI-Updates angezeigt. Tippen Sie darauf und es öffnet sich der Code, der sich auf den Hintergrund-Thread bezieht. Sie stellen einige UI im Hintergrund-Thread versteckt. Wird der Haupt-Thread den Absturz beheben? – miOS