Post

Replies

Boosts

Views

Activity

Reply to [AppKit] CNPropertyNotFetchedException when using CNContactFormatter on CNContact retrieved from CNContactPicker
Sorry for the late response, for some reason I wasn't notified via mail about your response. Here's there information you were asking for: Code reproducing your issue: #import "ViewController.h" @import Contacts; @import ContactsUI; @implementation ViewController CNContactPicker *contactPicker; -(IBAction)buttonPressed:(id)sender { contactPicker = [[CNContactPicker alloc] init]; contactPicker.delegate = self; contactPicker.displayedKeys = @[CNContactPostalAddressesKey]; [contactPicker showRelativeToRect:NSZeroRect ofView:sender preferredEdge:NSRectEdgeMinY]; } - (void)contactPicker:(CNContactViewController *)picker didSelectContactProperty:(CNContactProperty *)contactProperty { CNPostalAddressFormatter *formatter = [[CNPostalAddressFormatter alloc] init]; NSString *formattedAddress = [formatter stringFromPostalAddress:contactProperty.value]; NSLog(@"Formatted Address:\n%@", formattedAddress); @try { CNContactFormatter *contactFormatter = [[CNContactFormatter alloc] init]; NSString *formattedContact = [contactFormatter stringFromContact:contactProperty.contact]; NSLog(@"Formatted Contact:\n%@", formattedContact); } @catch(id anException) { NSLog(@"Exception:\n%@", anException); } } @end iOS version reproducing your issue: This is not an iOS issue. It happens in AppKit on macOS Sonoma 14.6.1. Does the issue also occur when using Xcode 16 beta 2? I didn't test Xcode 16 Beta 2 but it also happens with the (more recent) Xcode 16.1 Beta
Aug ’24
Reply to NSTextList not rendering on MacOS
I'm not sure if it's regression - the NSTextList never worked in the first place (or, they only work when you manually add the bullets into the text content itself - which user could select and delete). On iOS, the bullets are non-selectable and added automatically, just by setting the ParagraphStyle. I submitted a feedback report: FB15162186
Sep ’24
Reply to UITabBarController render glitch since iOS18 beta 1 & 2 when activating tabs.
@BMS have you filed a bug report and received any response to it? I am hitting the same issue and feel like there shouldn't be a workaround needed. But it seems like Apple really wants us to have only UINavigationController as children for the UITabBarController - the new "tab bar" on iPad also only seems to share the space with the navigation bar of child view controllers - it doesn't work if the Tab bar controller itself is nested in a UINavigationController
Sep ’24
Reply to UIDocumentPickerViewController: Cannot access file from OneDrive
You can force the OneDrive app to download the file first by settings "asCopy" to true: https://developer.apple.com/documentation/uikit/uidocumentpickerviewcontroller/3566731-initforexportingurls However, this can cause a hang, especially when the file is large and OneDrive doesn't show a progress indicator. I am also on the search for a way to download the file asynchronously and be able to show a progress indicator in my app
Oct ’24
Reply to Clarification on the correct use for CLServiceSession
@joey_needs_sleep I am struggling with the same problem after the iOS 18 update. Is the feature working reliably for you again now? Adding location to UIBackgroundModes is not needed, is it? Also, allowsBackgroundLocationUpdates doesn't need to be set to true in order to monitor geofences in the background? I am using CLMonitor.events and haven't found a way to query the minimal horizontalAccuracy for the geofencing to work Do you also start your CLServiceSession in the background, when the app is relaunched? According to the WWDC session, you can only start holding one (a CLServiceSession) when your app is in the foreground https://developer.apple.com/videos/play/wwdc2024/10212?time=522 and also ... CLMonitor.events won’t yield results when it is not in use, unless a session which was started in the foreground, .... https://developer.apple.com/videos/play/wwdc2024/10212?time=663
2w
Reply to CLMonitor does not always trigger on entry
I am also experiencing unreliable geofence entry & exit events since iOS 18. With iOS 17, I didn't need to use a CLServiceSession at all, now even when using one, it's unreliable. I also see the same behavior of the events timestamp to be the current time, and not the time of actual geofence entry. I made sure the app has the "Always" permission but I did not set the new NSLocationRequireExplicitServiceSession key in the Info.plist (I tested it, but couldn't see any change in the reliability) What I am confused about is whether to start a CLServiceSession if the app is restarted in the background. Apple is not clear about it. In the WWDC session they say: ... So your job, ..., is to make sure that your process launch logic knows what features it has been tasked with pursuing, and re-takes session objects... https://developer.apple.com/videos/play/wwdc2024/10212?time=758 But on the other hand it's also said that: you can only start holding one (a CLServiceSession) when your app is in the foreground https://developer.apple.com/videos/play/wwdc2024/10212?time=522 and also ... CLMonitor.events won’t yield results when it is not in use, unless a session which was started in the foreground, .... https://developer.apple.com/videos/play/wwdc2024/10212?time=663 It is also not clear if we need to use CLLocationManager.allowsBackgroundLocationUpdates (which is documented as "Apps that receive location updates when running in the background must include the UIBackgroundModes key (with the location value) in their app’s Info.plist file"). However, in my tests, doing so didn't yield any improvement (and as I said, in iOS 17 it wasn't required either).
2w
Reply to Issue with geolocation without using maps
I am also experiencing unreliable geofence entry & exit events since iOS 18. With iOS 17, I didn't need to use a CLServiceSession at all, now even when using one, it's unreliable. I also see the same behavior of the events timestamp to be the current time, and not the time of actual geofence entry. I made sure the app has the "Always" permission but I did not set the new NSLocationRequireExplicitServiceSession key in the Info.plist (I tested it, but couldn't see any change in the reliability) What I am confused about is whether to start a CLServiceSession if the app is restarted in the background. Apple is not clear about it. In the WWDC session they say: ... So your job, ..., is to make sure that your process launch logic knows what features it has been tasked with pursuing, and re-takes session objects... https://developer.apple.com/videos/play/wwdc2024/10212?time=758 But on the other hand it's also said that: you can only start holding one (a CLServiceSession) when your app is in the foreground https://developer.apple.com/videos/play/wwdc2024/10212?time=522 and also ... CLMonitor.events won’t yield results when it is not in use, unless a session which was started in the foreground, .... https://developer.apple.com/videos/play/wwdc2024/10212?time=663 It is also not clear if we need to use CLLocationManager.allowsBackgroundLocationUpdates (which is documented as "Apps that receive location updates when running in the background must include the UIBackgroundModes key (with the location value) in their app’s Info.plist file"). However, in my tests, doing so didn't yield any improvement (and as I said, in iOS 17 it wasn't required either). @Engineer what makes me doubt this being the cause for the unreliability of the geofencing is that it worked perfectly with iOS 17.
2w