WCSession is not reachable for sending messages

1.4k views Asked by At

I want to trigger few events to my watch extension app from the iOS app but I'm getting the error saying WCSession is not reachable. All my events are time-sensitive, So I can't wait for the user to turn on the watch display to trigger the events.

  1. Is there any way where I can achieve this using local notification?

  2. Is it possible to trigger watchOS launch, so that WCSession becomes reachable without user action?

1

There are 1 answers

0
kildos On

Is there any way where I can achieve this using local notification?

As far as I know, a notification does not change the reachability. You could debug its behaviour by using this on the iOS side to check if it becomes available.

func sessionReachabilityDidChange(_ session: WCSession) {}

I would recommend you to take a look at Extended Runtime Sessions, although it won't be running 24/7 in the background.