Post

Replies

Boosts

Views

Activity

Reply to Frequent iOS 15.1 crashes
If that's helpful, we did find a solution to our most immediate problem (the crash itself): digging through our own code we discovered that our logic to recover from an unexpected disconnect event was flawed, as our app was calling connect more than once in response to a single disconnect event. The crash went away after we cleaned up redundant connect calls. It is still unclear why iOS 13, 14 were unaffected by the redundant calls - but it no longer matters at this point.
Topic: App & System Services SubTopic: Core OS Tags:
Nov ’21
Reply to Unrelated 3rd party apps interfering with NWConnectionGroup's state
Yes allowLocalEndpointReuse is set to true Here is the entire code from the test app in the GitHub repository import Foundation import UIKit import Network class ViewController: UIViewController {   @IBOutlet weak var stateLabel: UILabel! var connectionGroup: NWMulticastGroup!   override func viewDidLoad() {     super.viewDidLoad()     let multicastGroup = try! NWMulticastGroup(for: [ .hostPort(host: "239.255.255.250", port: 1900) ])     let parameters = NWParameters.udp     parameters.allowLocalEndpointReuse = true     let connectionGroup = NWConnectionGroup(with: multicastGroup, using: .udp)     stateLabel.text = "\(connectionGroup.state)"     connectionGroup.setReceiveHandler(maximumMessageSize: 16384, rejectOversizedMessages: true) { message, content, isComplete in       NSLog("Received \(content?.count ?? 0) bytes from \(String(describing: message.remoteEndpoint))")     }     connectionGroup.stateUpdateHandler = { newState in       NSLog("Group entered state \(String(describing: newState))")       self.stateLabel.text = "\(newState)"     }     connectionGroup.start(queue: .main)   } }
Sep ’22
Reply to Unrelated 3rd party apps interfering with NWConnectionGroup's state
Thanks Quinn! With the understanding that we can't reasonably ask users to kill 3rd party apps, this means that using the Network framework to implement an SSDP client is not recommended at this time? I just want to be clear that there isn't a Network way to implement the SSDP client that I somehow missed. Here is the bug# FB11642799 (SSDP clients broken by unrelated 3rd party apps)
Oct ’22
Reply to Frequent iOS 15.1 crashes
If that's helpful, we did find a solution to our most immediate problem (the crash itself): digging through our own code we discovered that our logic to recover from an unexpected disconnect event was flawed, as our app was calling connect more than once in response to a single disconnect event. The crash went away after we cleaned up redundant connect calls. It is still unclear why iOS 13, 14 were unaffected by the redundant calls - but it no longer matters at this point.
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
Nov ’21
Reply to Unrelated 3rd party apps interfering with NWConnectionGroup's state
Yes allowLocalEndpointReuse is set to true Here is the entire code from the test app in the GitHub repository import Foundation import UIKit import Network class ViewController: UIViewController {   @IBOutlet weak var stateLabel: UILabel! var connectionGroup: NWMulticastGroup!   override func viewDidLoad() {     super.viewDidLoad()     let multicastGroup = try! NWMulticastGroup(for: [ .hostPort(host: "239.255.255.250", port: 1900) ])     let parameters = NWParameters.udp     parameters.allowLocalEndpointReuse = true     let connectionGroup = NWConnectionGroup(with: multicastGroup, using: .udp)     stateLabel.text = "\(connectionGroup.state)"     connectionGroup.setReceiveHandler(maximumMessageSize: 16384, rejectOversizedMessages: true) { message, content, isComplete in       NSLog("Received \(content?.count ?? 0) bytes from \(String(describing: message.remoteEndpoint))")     }     connectionGroup.stateUpdateHandler = { newState in       NSLog("Group entered state \(String(describing: newState))")       self.stateLabel.text = "\(newState)"     }     connectionGroup.start(queue: .main)   } }
Replies
Boosts
Views
Activity
Sep ’22
Reply to Unrelated 3rd party apps interfering with NWConnectionGroup's state
Yes after cloning the test app, same interference. The first opened app will be in status ready, and the app started subsequently will show the error status failed(POSIXErrorCode ....address already in use)
Replies
Boosts
Views
Activity
Sep ’22
Reply to Unrelated 3rd party apps interfering with NWConnectionGroup's state
Thanks Quinn! With the understanding that we can't reasonably ask users to kill 3rd party apps, this means that using the Network framework to implement an SSDP client is not recommended at this time? I just want to be clear that there isn't a Network way to implement the SSDP client that I somehow missed. Here is the bug# FB11642799 (SSDP clients broken by unrelated 3rd party apps)
Replies
Boosts
Views
Activity
Oct ’22