0

Let's say I have the following code:

guard let URLData = URL(string: "https://www.bing.com") else {
    print("Unable to access \(URLString)")
    return
}

When I run this on my Apple Watch Series 7 (Connected to stable WiFi), it throws a bunch of stuff in the console, such as Error getting network data status Error Domain=NSPOSIXErrorDomain Code=19 "Operation not supported by device" and NSURLConnection finished with error - code -1009.

I know error code -1009 means there was a failure in connection... Why is this happening? My Apple Watch is definitely connected to the internet. Same with my iPhone. Also, I'm now having concerns about URL access on watchOS, due to their "Operation not supported by device" thing and the fact that stuff like WebKit is already locked from development on watches...

IDK! Help!

Shabnam Siddiqui
  • 579
  • 4
  • 13
PersonDudeGuy
  • 113
  • 1
  • 4
  • I am having this issue on the same situation on a Series 5. Did you manage to fix it? – Wes Souza Sep 09 '22 at 18:00
  • @WesSouza sadly, I have not yet found a solution... – PersonDudeGuy Sep 09 '22 at 20:56
  • The more I dig the worse it gets, apparently WebSockets were never supported on watchOS due to apple engineering considering it to be low level network. The fact it worked and my app even got approved with it is infuriating. https://developer.apple.com/forums/thread/127232 – Wes Souza Sep 18 '22 at 15:08

0 Answers0