This only happens in my CI machine!
This only happens when running the tests, the app code works fine
I tried enabling location services on macOS just in case, but it didn't work.
That machine shouldn't have any network requests/URLs blocked
Does anyone have any information about this?
Here's some sample code:
Code Block let request = MKLocalSearch.Request() request.naturalLanguageQuery = "Venue" // this fixes it, but why?! let ibereCamargoMuseumCoordinates = CLLocationCoordinate2D(latitude: -30.0777596, longitude: -51.2477212) let span = MKCoordinateSpan(latitudeDelta: 5, longitudeDelta: 5) request.region = MKCoordinateRegion(center: ibereCamargoMuseumCoordinates, span: span) if #available(iOS 13.0, *) { request.resultTypes = .pointOfInterest } let localSearch = MKLocalSearch(request: request) localSearch.start { response, error in ... }
Here's some debugging output:
Code Block (lldb) po error Error Domain=MKErrorDomain Code=4 "(null)" UserInfo={MKErrorGEOError=-8} (lldb) po error.userInfo ▿ 1 element ▿ 0 : 2 elements ▿ key : AnyHashable("MKErrorGEOError") - value : "MKErrorGEOError" - value : -8
If you're interested I asked this on Stack Overflow too.