-[NWConcrete_nw_endpoint port] incorrect endpoint type 3

Hey all, so I'm trying to use Multipeer Connectivity programmatically and have ran into an error that I can't seem to work out. For some more intuition as to what I'm trying to do with the app, see here. Note I've switched back to using strictly Multipeer.


I've read a ton of the resources on this forum and Google but there is no concrete solution. I've tried setting the encryption settings to optional, and have tested every combination of {WiFi, BT} possible. I found this post and have followed the steps Eskimo recommended in order to clearly present the issue. Unfortunately, it seems like in that case, the error wasn't having meaningful effect on the functionality whereas in my case it is.
In any case, here's the source code that reproduces the crash. I largely followed this tutorial along the way, although I did change the functionality to require as little user interaction as possible. The majority of the multipeer code is in hearsayMPC.swift; there are a couple of other functions below a comment in FeedScreen.swift that can be found using the string "MPCManagerDelegate Functionality".


The crash happens when I try to setup two MC Peers and connect them. One of them hosts a network and invites the other. The other accepts the invitation. I know both these things from conveniently placed print statements. Then, the error happens (note that the app doesn't hard crash, however the connection is never established and thus the message is never sent. Even if there is no message with the necessary conditions to be sent, the connection is not established (but it should establish a connection anyway, ideally) :

2019-05-08 21:24:28.586359-0700 hearsay[17516:4961050] [MC] System group container for systemgroup.com.apple.configurationprofiles path is /private/var/containers/Shared/SystemGroup/systemgroup.com.apple.configurationprofiles
2019-05-08 21:24:28.587704-0700 hearsay[17516:4961050] [MC] Reading from public effective user settings.
* broadcasting: false listening: true
* broadcasting: true  listening:false
* found peer! <MCPeerID: 0x2819a0330 DisplayName = hearsayUser>)
2019-05-08 21:24:39.347585-0700 hearsay[17516:4961083] [] -[NWConcrete_nw_endpoint port] incorrect endpoint type 3
2019-05-08 21:24:39.347951-0700 hearsay[17516:4961083] [] __nwlog_err_simulate_crash simulate crash failed "-[NWConcrete_nw_endpoint port] incorrect endpoint type 3"
2019-05-08 21:24:39.348972-0700 hearsay[17516:4961083] [] -[NWConcrete_nw_endpoint port] incorrect endpoint type 3, dumping backtrace:
        [arm64] libnetcore-1229.250.15
    0   libnetwork.dylib                    0x0000000230f751a8 __nw_create_backtrace_string + 116
    1   libnetwork.dylib                    0x0000000230ecd6b8 <redacted> + 188
    2   libnetwork.dylib                    0x0000000230eda074 nw_endpoint_get_port + 56
    3   libnetwork.dylib                    0x0000000230e6b984 <redacted> + 4756
    4   libnetwork.dylib                    0x0000000230d2b34c <redacted> + 180
    5   libnetwork.dylib                    0x0000000230e5c7d8 <redacted> + 1004
    6   libnetwork.dylib                    0x0000000230d2b34c <redacted> + 180
    7   libnetwork.dylib                    0x0000000230e5c7d8 <redacted> + 1004
    8   libnetwork.dylib                    0x0000000230d2b34c <redacted> + 180
    9   libnetwork.dylib                    0x0000000230c92194 <redacted> + 2280
    10  libnetwork.dylib                    0x0000000230ca5324 <redacted> + 1444
    11  libnetwork.dylib                    0x0000000230c9fb5c <redacted> + 1220
    12  libnetwork.dylib                    0x0000000230dc08f8 <redacted> + 1676
    13  libdispatch.dylib                   0x0000000100634c74 _dispatch_client_callout + 16
    14  libdispatch.dylib                   0x0000000100637ffc _dispatch_continuation_pop + 524
    15  libdispatch.dylib                   0x000000010064a610 _dispatch_source_invoke + 1444
    16  libdispatch.dylib                   0x000000010063ef68 _dispatch_workloop_invoke + 2692
    17  libdispatch.dylib                   0x000000010064777c _dispatch_workloop_worker_thread + 1148
    18  libsystem_pthread.dylib             0x000000022f999114 _pthread_wqthread + 304
    19  libsystem_pthread.dylib             0x000000022f99bcd4 start_wqthread + 4
2019-05-08 21:24:40.206572-0700 hearsay[17516:4961083]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
* Connecting to session: <MCSession: 0x282ab1900 MyPeerID = <MCPeerID: 0x2819bbec0 DisplayName = hearsayUser> SecurityIdentity = (null) EncryptionPreference = Required ConnectedPeers = () Delegate = <hearsay.MPCManager: 0x2830b2ed0>>
2019-05-08 21:24:41.460900-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:41.541184-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:41.692852-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:41.940897-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:42.346496-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:43.058966-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:44.291312-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:45.824926-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:47.352503-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:48.879142-0700 hearsay[17516:4961228]  [ERROR] ProcessEvent:1199   Send BINDING_REQUEST failed(C01A0041).
2019-05-08 21:24:50.026077-0700 hearsay[17516:4961085]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
2019-05-08 21:24:50.238074-0700 hearsay[17516:4961085]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
2019-05-08 21:24:50.386523-0700 hearsay[17516:4961085] [GCKSession] Not in connected state, so giving up for participant [19BF146B] on channel [0].
2019-05-08 21:24:50.386708-0700 hearsay[17516:4961085]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
2019-05-08 21:24:50.386899-0700 hearsay[17516:4961085] [GCKSession] Not in connected state, so giving up for participant [19BF146B] on channel [1].
2019-05-08 21:24:50.387044-0700 hearsay[17516:4961085]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
2019-05-08 21:24:50.387175-0700 hearsay[17516:4961085] [GCKSession] Not in connected state, so giving up for participant [19BF146B] on channel [2].
2019-05-08 21:24:50.387422-0700 hearsay[17516:4961085]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
2019-05-08 21:24:50.387544-0700 hearsay[17516:4961085] [GCKSession] Not in connected state, so giving up for participant [19BF146B] on channel [6].
2019-05-08 21:24:50.387708-0700 hearsay[17516:4961085]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
2019-05-08 21:24:50.387891-0700 hearsay[17516:4961085] [GCKSession] Not in connected state, so giving up for participant [19BF146B] on channel [7].
2019-05-08 21:24:50.388030-0700 hearsay[17516:4961085]  [ERROR] ICEStopConnectivityCheck:2688 ICEStopConnectivityCheck() found no ICE check with call id (431953003)
* Did not connect to session: <MCSession: 0x282ab1900 MyPeerID = <MCPeerID: 0x2819bbec0 DisplayName = hearsayUser> SecurityIdentity = (null) EncryptionPreference = Required ConnectedPeers = () Delegate = <hearsay.MPCManager: 0x2830b2ed0>>


In accordance to what I saw in that last post, I set a symbolic breakpoint at __nwlog_err_simulate_crash, gathered all the stack frames using 'bt all' and copied them into here.

thread #1, queue = 'com.apple.main-thread'
    frame #0: 0x000000022fd22dc4 CoreFoundation`__CFStringEqual + 108
    frame #1: 0x000000022fc64304 CoreFoundation`-[__NSCFString isEqual:] + 164
    frame #2: 0x00000002307b7c50 Foundation`NSKeyValueAccessorIsEqual + 60
    frame #3: 0x000000022fd9ee90 CoreFoundation`CFBasicHashFindBucket + 408
    frame #4: 0x000000022fd0dbe8 CoreFoundation`CFSetGetValue + 120
    frame #5: 0x00000002306d4ee4 Foundation`-[NSObject(NSKeyValueCoding) valueForKey:] + 172
    frame #6: 0x000000025c30310c UIKitCore`-[_UIStatusBarData copyWithZone:] + 260
    frame #7: 0x000000025c2f5038 UIKitCore`-[_UIStatusBar _updateWithAggregatedData:] + 64
    frame #8: 0x000000025c2f3a8c UIKitCore`__30-[_UIStatusBar initWithStyle:]_block_invoke + 56
    frame #9: 0x000000025c3054c8 UIKitCore`-[_UIStatusBarDataAggregator _updateForCoalescedKeysWithData:] + 328
    frame #10: 0x000000025c304f34 UIKitCore`-[_UIStatusBarDataAggregator _updateForDelayedKeysWithData:] + 168
    frame #11: 0x000000025c2f4e40 UIKitCore`-[_UIStatusBar _updateWithData:completionHandler:] + 196
    frame #12: 0x000000025c3302fc UIKitCore`-[UIStatusBar_Modern _updateWithData:force:] + 388
    frame #13: 0x000000025c33105c UIKitCore`-[UIStatusBar_Modern statusBarServer:didReceiveStatusBarData:withActions:] + 92
    frame #14: 0x000000025c315e88 UIKitCore`-[UIStatusBarServer _receivedStatusBarData:actions:animated:] + 108
    frame #15: 0x000000025c3160b0 UIKitCore`_UIStatusBarReceivedStatusBarDataAndActions + 276
    frame #16: 0x000000025c312a3c UIKitCore`_XReceivedStatusBarDataAndActions + 148
    frame #17: 0x0000000232582bc4 AppSupport`migHelperRecievePortCallout + 200
    frame #18: 0x000000022fd0a934 CoreFoundation`__CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 56
    frame #19: 0x000000022fd0a080 CoreFoundation`__CFRunLoopDoSource1 + 440
    frame #20: 0x000000022fd04ea4 CoreFoundation`__CFRunLoopRun + 2096
    frame #21: 0x000000022fd04354 CoreFoundation`CFRunLoopRunSpecific + 436
    frame #22: 0x0000000231f0479c GraphicsServices`GSEventRunModal + 104
    frame #23: 0x000000025c1adb68 UIKitCore`UIApplicationMain + 212
    frame #24: 0x0000000100310ffc hearsay`main at AppDelegate.swift:13:7
    frame #25: 0x000000022f7ca8e0 libdyld.dylib`start + 4
  thread #6, name = 'com.apple.uikit.eventfetch-thread'
    frame #0: 0x000000022f90b0f4 libsystem_kernel.dylib`mach_msg_trap + 8
    frame #1: 0x000000022f90a5a0 libsystem_kernel.dylib`mach_msg + 72
    frame #2: 0x000000022fd09cb4 CoreFoundation`__CFRunLoopServiceMachPort + 236
    frame #3: 0x000000022fd04bc4 CoreFoundation`__CFRunLoopRun + 1360
    frame #4: 0x000000022fd04354 CoreFoundation`CFRunLoopRunSpecific + 436
    frame #5: 0x00000002306d1fcc Foundation`-[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 300
    frame #6: 0x00000002306d1e5c Foundation`-[NSRunLoop(NSRunLoop) runUntilDate:] + 96
    frame #7: 0x000000025c293540 UIKitCore`-[UIEventFetcher threadMain] + 136
    frame #8: 0x00000002307fe6e4 Foundation`__NSThread__start__ + 984
    frame #9: 0x000000022f9982c0 libsystem_pthread.dylib`_pthread_body + 128
    frame #10: 0x000000022f998220 libsystem_pthread.dylib`_pthread_start + 44
    frame #11: 0x000000022f99bcdc libsystem_pthread.dylib`thread_start + 4
  thread #8, name = 'com.apple.multipeerconnectivity.gcksession.recvproc'
    frame #0: 0x000000022f916328 libsystem_kernel.dylib`__select + 8
    frame #1: 0x000000024c5daf1c MultipeerConnectivity`gckSessionRecvProc + 6268
    frame #2: 0x000000022f9982c0 libsystem_pthread.dylib`_pthread_body + 128
    frame #3: 0x000000022f998220 libsystem_pthread.dylib`_pthread_start + 44
    frame #4: 0x000000022f99bcdc libsystem_pthread.dylib`thread_start + 4
  thread #9, name = 'com.apple.multipeerconnectivity.gcksession.sendproc'
    frame #0: 0x000000022f916328 libsystem_kernel.dylib`__select + 8
    frame #1: 0x000000024c5db580 MultipeerConnectivity`gckSessionSendProc + 392
    frame #2: 0x000000022f9982c0 libsystem_pthread.dylib`_pthread_body + 128
    frame #3: 0x000000022f998220 libsystem_pthread.dylib`_pthread_start + 44
    frame #4: 0x000000022f99bcdc libsystem_pthread.dylib`thread_start + 4
  thread #10, name = 'com.apple.multipeerconnectivity.eventcallback.eventcbproc'
    frame #0: 0x000000022f915ee4 libsystem_kernel.dylib`__psynch_cvwait + 8
    frame #1: 0x000000022f9954a4 libsystem_pthread.dylib`_pthread_cond_wait$VARIANT$armv81 + 628
    frame #2: 0x000000024c5f371c MultipeerConnectivity`EventCBProc + 120
    frame #3: 0x000000022f9982c0 libsystem_pthread.dylib`_pthread_body + 128
    frame #4: 0x000000022f998220 libsystem_pthread.dylib`_pthread_start + 44
    frame #5: 0x000000022f99bcdc libsystem_pthread.dylib`thread_start + 4
  thread #13, name = 'com.apple.CFSocket.private'
    frame #0: 0x000000022f916328 libsystem_kernel.dylib`__select + 8
    frame #1: 0x000000022fd12998 CoreFoundation`__CFSocketManager + 620
    frame #2: 0x000000022f9982c0 libsystem_pthread.dylib`_pthread_body + 128
    frame #3: 0x000000022f998220 libsystem_pthread.dylib`_pthread_start + 44
    frame #4: 0x000000022f99bcdc libsystem_pthread.dylib`thread_start + 4
* thread #15, queue = 'com.apple.network.connections', stop reason = instruction step over
  * frame #0: 0x0000000230f74a1c libnetwork.dylib`__nwlog_err_simulate_crash + 380
    frame #1: 0x0000000230ecd6b4 libnetwork.dylib`-[NWConcrete_nw_endpoint port] + 184
    frame #2: 0x0000000230eda074 libnetwork.dylib`nw_endpoint_get_port + 56
    frame #3: 0x0000000230e6b984 libnetwork.dylib`nw_connection_endpoint_report + 4756
    frame #4: 0x0000000230d2b34c libnetwork.dylib`nw_endpoint_handler_report + 180
    frame #5: 0x0000000230e5c7d8 libnetwork.dylib`nw_endpoint_resolver_receive_report + 1004
    frame #6: 0x0000000230d2b34c libnetwork.dylib`nw_endpoint_handler_report + 180
    frame #7: 0x0000000230e5c7d8 libnetwork.dylib`nw_endpoint_resolver_receive_report + 1004
    frame #8: 0x0000000230d2b34c libnetwork.dylib`nw_endpoint_handler_report + 180
    frame #9: 0x0000000230c92194 libnetwork.dylib`nw_endpoint_flow_connected_path_change + 2280
    frame #10: 0x0000000230ca5324 libnetwork.dylib`nw_endpoint_flow_connected + 1444
    frame #11: 0x0000000230c9fb5c libnetwork.dylib`nw_endpoint_flow_protocol_connected + 1220
    frame #12: 0x0000000230dc08f8 libnetwork.dylib`nw_socket_handle_socket_event + 1676
    frame #13: 0x0000000100680c74 libdispatch.dylib`_dispatch_client_callout + 16
    frame #14: 0x0000000100683ffc libdispatch.dylib`_dispatch_continuation_pop + 524
    frame #15: 0x0000000100696610 libdispatch.dylib`_dispatch_source_invoke + 1444
    frame #16: 0x000000010068af68 libdispatch.dylib`_dispatch_workloop_invoke + 2692
    frame #17: 0x000000010069377c libdispatch.dylib`_dispatch_workloop_worker_thread + 1148
    frame #18: 0x000000022f999114 libsystem_pthread.dylib`_pthread_wqthread + 304
    frame #19: 0x000000022f99bcd4 libsystem_pthread.dylib`start_wqthread + 4
  thread #16, name = 'com.apple.CFStream.LegacyThread'
    frame #0: 0x000000022f90b0f4 libsystem_kernel.dylib`mach_msg_trap + 8
    frame #1: 0x000000022f90a5a0 libsystem_kernel.dylib`mach_msg + 72
    frame #2: 0x000000022fd09cb4 CoreFoundation`__CFRunLoopServiceMachPort + 236
    frame #3: 0x000000022fd04bc4 CoreFoundation`__CFRunLoopRun + 1360
    frame #4: 0x000000022fd04354 CoreFoundation`CFRunLoopRunSpecific + 436
    frame #5: 0x000000022fd1d094 CoreFoundation`_legacyStreamRunLoop_workThread + 260
    frame #6: 0x000000022f9982c0 libsystem_pthread.dylib`_pthread_body + 128
    frame #7: 0x000000022f998220 libsystem_pthread.dylib`_pthread_start + 44
    frame #8: 0x000000022f99bcdc libsystem_pthread.dylib`thread_start + 4
  thread #17, name = 'com.apple.NSURLConnectionLoader'
    frame #0: 0x000000022f90b0f4 libsystem_kernel.dylib`mach_msg_trap + 8
    frame #1: 0x000000022f90a5a0 libsystem_kernel.dylib`mach_msg + 72
    frame #2: 0x000000022fd09cb4 CoreFoundation`__CFRunLoopServiceMachPort + 236
    frame #3: 0x000000022fd04bc4 CoreFoundation`__CFRunLoopRun + 1360
    frame #4: 0x000000022fd04354 CoreFoundation`CFRunLoopRunSpecific + 436
    frame #5: 0x000000023031d74c CFNetwork`-[__CoreSchedulingSetRunnable runForever] + 216
    frame #6: 0x00000002307fe6e4 Foundation`__NSThread__start__ + 984
    frame #7: 0x000000022f9982c0 libsystem_pthread.dylib`_pthread_body + 128
    frame #8: 0x000000022f998220 libsystem_pthread.dylib`_pthread_start + 44
    frame #9: 0x000000022f99bcdc libsystem_pthread.dylib`thread_start + 4
  thread #18
    frame #0: 0x000000022f99bcd0 libsystem_pthread.dylib`start_wqthread
  thread #19, queue = 'com.apple.MCSession.syncQueue'
    frame #0: 0x0000000100756524 dyld`getattrlist + 8
    frame #1: 0x000000010074fe7c dyld`realpath$DARWIN_EXTSN + 852
    frame #2: 0x000000010072baf0 dyld`ImageLoaderMachO::getRPaths(ImageLoader::LinkContext const&, std::__1::vector<char const*, std::__1::allocator<char const*> >&) const + 196
    frame #3: 0x0000000100720bc8 dyld`dlopen_internal + 688
    frame #4: 0x000000022f7cd908 libdyld.dylib`dlopen + 176
    frame #5: 0x000000024c5c1544 MultipeerConnectivity`__WirelessDiagnosticsLibrary_block_invoke + 24
    frame #6: 0x0000000100680c74 libdispatch.dylib`_dispatch_client_callout + 16
    frame #7: 0x0000000100682c84 libdispatch.dylib`_dispatch_once_callout + 84
    frame #8: 0x000000024c5c151c MultipeerConnectivity`initAWDServerConnection + 88
    frame #9: 0x000000024c5c13fc MultipeerConnectivity`__MCAWDEnsureInitialized_block_invoke + 28
    frame #10: 0x0000000100680c74 libdispatch.dylib`_dispatch_client_callout + 16
    frame #11: 0x0000000100682c84 libdispatch.dylib`_dispatch_once_callout + 84
    frame #12: 0x000000024c5c0ff4 MultipeerConnectivity`MCAWDSubmit + 400
    frame #13: 0x000000024c5c0e58 MultipeerConnectivity`MCAWDLogMaxConnectedPeersCount + 80
    frame #14: 0x000000024c5cea9c MultipeerConnectivity`-[MCSession syncLogMaxConnectedPeers] + 308
    frame #15: 0x000000024c5c6488 MultipeerConnectivity`-[MCSession syncPeer:changeStateTo:shouldForceCallback:] + 872
    frame #16: 0x000000010067f6f0 libdispatch.dylib`_dispatch_call_block_and_release + 24
    frame #17: 0x0000000100680c74 libdispatch.dylib`_dispatch_client_callout + 16
    frame #18: 0x0000000100688bf4 libdispatch.dylib`_dispatch_lane_serial_drain + 712
    frame #19: 0x00000001006898b4 libdispatch.dylib`_dispatch_lane_invoke + 456
    frame #20: 0x000000010069377c libdispatch.dylib`_dispatch_workloop_worker_thread + 1148
    frame #21: 0x000000022f999114 libsystem_pthread.dylib`_pthread_wqthread + 304
    frame #22: 0x000000022f99bcd4 libsystem_pthread.dylib`start_wqthread + 4
  thread #20, queue = 'com.apple.MCSession.callbackQueue'
    frame #0: 0x000000022f91793c libsystem_kernel.dylib`kevent_id + 8
    frame #1: 0x00000001006a0774 libdispatch.dylib`_dispatch_kq_poll + 328
    frame #2: 0x00000001006a1260 libdispatch.dylib`_dispatch_event_loop_wait_for_ownership + 412
    frame #3: 0x000000010068f7b8 libdispatch.dylib`__DISPATCH_WAIT_FOR_QUEUE__ + 312
    frame #4: 0x000000010068f208 libdispatch.dylib`_dispatch_sync_f_slow + 176
    frame #5: 0x000000024c5cc6dc MultipeerConnectivity`-[MCSession connectedPeers] + 112
    frame #6: 0x000000024c5c3d54 MultipeerConnectivity`-[MCSession description] + 164
    frame #7: 0x000000025dacf0fc libswiftFoundation.dylib`merged protocol witness for Swift.CustomStringConvertible.description.getter : Swift.String in conformance __C.NSObject : Swift.CustomStringConvertible in Foundation + 20
    frame #8: 0x000000025d6f5884 libswiftCore.dylib`Swift.DefaultStringInterpolation.appendInterpolation<A where A: Swift.CustomStringConvertible>(A) -> () + 40
    frame #9: 0x00000001003213cc hearsay`MPCManager.session(session=0x00000002804d2260, peerID=0x00000002837c8290, state=notConnected, self=0x0000000281ec5b90) at hearsayMPC.swift:98:53
    frame #10: 0x0000000100321580 hearsay`@objc MPCManager.session(_:peer:didChange:) at <compiler-generated>:0
    frame #11: 0x000000024c5c6568 MultipeerConnectivity`__56-[MCSession syncPeer:changeStateTo:shouldForceCallback:]_block_invoke + 144
    frame #12: 0x000000010067f6f0 libdispatch.dylib`_dispatch_call_block_and_release + 24
    frame #13: 0x0000000100680c74 libdispatch.dylib`_dispatch_client_callout + 16
    frame #14: 0x0000000100688bf4 libdispatch.dylib`_dispatch_lane_serial_drain + 712
    frame #15: 0x00000001006898b4 libdispatch.dylib`_dispatch_lane_invoke + 456
    frame #16: 0x000000010069377c libdispatch.dylib`_dispatch_workloop_worker_thread + 1148
    frame #17: 0x000000022f999114 libsystem_pthread.dylib`_pthread_wqthread + 304
    frame #18: 0x000000022f99bcd4 libsystem_pthread.dylib`start_wqthread + 4


Not sure how to proceed-- any advice is appreciated!


Regards

Replies

In any case, here's the source code that reproduces the crash.

Just to clarify, this isn’t an actual crash, right? There’s no crash report? Rather, the symptoms are:

  • You get this log message.

  • Your Multipeer Connectivity code fails to connect.

Correct?

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"

Correct; I should have made that more clear besides just within the parentheses in the OP.

Any ideas/suggestions?

Any ideas/suggestions?

No, alas. The backtrace of the thread that logs that message (thread 15) doesn’t reveal anything particularly insightful. The failure to connect is occurring at the MultipeerConnectivity level, and there are no MultipeerConnectivity frames in that backtrace, suggesting that this log message is just ‘collateral damage’ for whatever is causing the connect to fail.

Do you see any sog messages coming out of MultipeerConnectivity itself? If so, I recommend you focus on those.

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"