Delve into the world of built-in app and system services available to developers. Discuss leveraging these services to enhance your app's functionality and user experience.

Post

Replies

Boosts

Views

Activity

ControlWidget jump deep link and custom icon error
When i use Xcode16 Beta4, I finish some code for example @available(iOS 18.0, *) struct Test001ControlWidget: ControlWidget { let kind: String = "Test001ControlWidgetKind" var body: some ControlWidgetConfiguration { StaticControlConfiguration(kind: kind, content: { ControlWidgetButton(action: Test001ControlAppIntent(), label: { HStack { Image("controlcenter_point") Text("Test001") } }) }) .displayName("Test001") } } @available(iOS 18.0, *) struct Test001ControlAppIntent: AppIntent { static let title: LocalizedStringResource = "Open Demo Some Page" static var isDiscoverable: Bool = false static var openAppWhenRun: Bool = true func perform() async throws -> some IntentResult & OpensIntent { let defaultIntent = OpenURLIntent() guard let url = URL(string: Test001JumpType.sohuWatchPoint.jumpLink()) else { return .result(opensIntent: defaultIntent) } return .result(opensIntent: OpenURLIntent(url)) } } The icon can be displayed normally and icon type is png. And deep link also jump normally.(Note: The control widget file target membership are main app and widgetExtension) But iOS18 RC code is no working and icon show "?" How do I deal with these issues? I hope to hear from you soon. Tks a lot...
1
0
133
6d
Unexpected iOS App foregrounding
I am seeing some unexpected behavior, in particular, is seems that iOS is periodically foregrounding my test app with no user intervention. I am curious why this is. I wrote a simple test app to see how long the app would run to collect location while in the background with only "While in Use" location permission. The app will start location updates when foregrounded and continue in the background. While backgrounded, I see the blue arrow in the dynamic island as expected. What is unexpected is that every few days, I see the UI of the app displayed in the foreground, without having foregrounded it myself (and no, I did not tap the blue arrow). This is using the legacy CoreLocation apis on iOS 17.5.1. My question is how/why does this happen?
7
0
471
Jul ’24
ClassKit App Freezing Issue
Hello Apple Developer Team, I hope you’re doing well. I’m writing to report an issue with the Schoolwork app and ClassKit integration. We’ve implemented the ClassKit framework according to the documentation, and while it works fine when the app is terminated, we encounter a problem when the app is in the background. When accessing a student’s profile in the Schoolwork app and clicking the START and CONTINUE buttons, the Sample ClassKit app opens via the deep link. However, the app freezes after about 3 seconds and remains unresponsive until we receive the Student Progress Alert, which takes approximately 15 seconds. We’re only experiencing this issue and would greatly appreciate your technical support to resolve it. Thank you for your assistance, and I look forward to your response. Steps to Reproduce the Issue: Open the Sample ClassKit app. Open the Settings app. Navigate to Developer and select ClassKit API. Choose Teacher. Open the Schoolwork app. Click on Create New Assignment. A popover view titled New Assignment will appear. Click the Add Activities button (blue background) and search for the app named Sample ClassKit. Ensure the necessary symbol for Student Progress is checked. If not available, terminate all apps and reopen the Sample ClassKit project, then repeat step 1. Click on the app. Find and select the exercise titled Explore In 3D. Click the + icon and then the Done button in the top right corner. Enter the title and assign it as needed. Return to the Settings app: Navigate to Developer and select ClassKit API. Choose Student. Open the Schoolwork app: Click on the student assignment. Click either the Start or Continue button. The Sample ClassKit project will open. Click on Gallery 3 to 4 times. You will notice that the Student Progress Alert does not appear, and the app freezes if the Sample ClassKit project is coming from background to active mode. Note: The issue does not occur if the Sample ClassKit app is terminated before clicking Start or Continue; in that case, the alert appears immediately.
2
0
69
1w
XPCConnectionTerminationWatchdog Crash
I recently update my ionic app to ionic angular 7. I'm having this crash that does not happen in the same way, neither in the same place. Aside from needed some entitlements that I've already requested the app is crashing all the time. This is the error. ⚡️ TO JS {"value":"en"} 2024-09-24 15:43:56.097126+0200 App[33392:5520337] [Process] 0x10d003260 - [PID=33408] WebProcessProxy::didClose: (web process 0 crash) 2024-09-24 15:43:56.097185+0200 App[33392:5520337] [Process] 0x10d003260 - [PID=33408] WebProcessProxy::processDidTerminateOrFailedToLaunch: reason=Crash 2024-09-24 15:43:56.097270+0200 App[33392:5520337] [ProcessSuspension] 0x10c020720 - ProcessAssertion: Failed to acquire RBS Background assertion 'XPCConnectionTerminationWatchdog' for process because PID 0 is invalid 2024-09-24 15:43:56.097368+0200 App[33392:5521826] [ProcessSuspension] 0x10c020720 - ProcessAssertion::acquireSync Failed to acquire RBS assertion 'XPCConnectionTerminationWatchdog' for process with PID=0, error: (null) 2024-09-24 15:43:56.098184+0200 App[33392:5520337] [Process] 0x142832618 - [pageProxyID=8, webPageID=9, PID=33408] WebPageProxy::processDidTerminate: (pid 33408), reason=Crash 2024-09-24 15:43:56.101821+0200 App[33392:5520337] [Loading] 0x142832618 - [pageProxyID=8, webPageID=9, PID=33408] WebPageProxy::dispatchProcessDidTerminate: reason=Crash 2024-09-24 15:43:56.117084+0200 App[33392:5522124] [com.apple.VisionKit.processing] Error processing request from MAD on result: Error Domain=NSOSStatusErrorDomain Code=-128 "Request was canceled" UserInfo={NSLocalizedDescription=Request was canceled} request: <VKCImageAnalyzerRequest: 0x2830d0690> requestID: 6 madRequestID: 6 cancelled: YES 2024-09-24 15:43:56.245502+0200 App[33392:5520337] [Process] 0x10c07c380 - GPUProcessProxy::gpuProcessExited: reason=IdleExit 2024-09-24 15:43:56.245552+0200 App[33392:5520337] [Process] 0x10d002ce0 - [PID=33412] WebProcessProxy::gpuProcessExited: reason=IdleExit 2024-09-24 15:43:57.682680+0200 App[33392:5520337] Could not signal service com.apple.WebKit.WebContent: 113: Could not find specified service 2024-09-24 15:44:04.249892+0200 App[33392:5520337] Could not signal service com.apple.WebKit.WebContent: 113: Could not find specified service 2024-09-24 15:44:12.223579+0200 App[33392:5520337] Could not signal service com.apple.WebKit.WebContent: 113: Could not find specified service 2024-09-24 15:44:26.098426+0200 App[33392:5520337] Could not signal service com.apple.WebKit.WebContent: 113: Could not find specified service 2024-09-24 15:44:59.812245+0200 App[33392:5522961] [MADService] Client XPC connection invalidated
1
0
91
1w
Detect iPhone Mirroring in iOS18
Hi everyone, Is there any way to detect an app is being mirrored from an iPhone to macOS via iPhone Mirroring (new feature from iOS18 and macOS 15 Sequoia)? My app has a business requirement to disable screen mirroring and recording (or just display a black screen when it's active). However, the current implementation doesn't seem to work with iPhone Mirroring to macOS. Is there any solution for this? Because as far as I know, seems like there is no API to detect it What I've tried so far 1. Count the UIScreen var totalScreens = UIScreen.screens.count Screen counts: iPhone only (without mirroring or airplay): 1 iPhone Airplay (screen mirroring): 2 iPhone Mirroring (iOS18) to MacOS15: 1 conclusion: both iPhone only and iPhone mirroring to macOS returns the same screen count (no difference) 2. Mask the entire screen with passwordTextField.isSecureTextEntry= true Result iPhone screen recording: Black screen iPhone screen mirroring (AirPlay): Black screen iPhone Mirroring (with macOS): No blackscreen, it works as usual The implementation is similar to https://stackoverflow.com/a/67054892 and https://forums.developer.apple.com/forums/thread/736112?answerId=765331022#765331022 What I want to achieve is something like the FairPlay Streaming API (https://developer.apple.com/streaming/fps/), where it turns the screen black when a screenshot, screen recording, screen mirroring, or iPhone mirroring is active. Thank you
2
1
127
1w
Woke up this morning to all of our app clips showing "App Clip Unavailable" on the app clip card with no change on our side.
I woke up this morning to all of our app clips showing "App Clip Unavailable" on the app clip card with no change on our side to the app or app clips. What's weird is that the app clip card shows up fine if you have our app installed, otherwise it shows the error message on the app clip card. My leading theory is it could be an issue with apple's system (wouldn't be the first time we've had issues that were magically broken then fixed with nothing being changed), anybody else seeing issues or have ideas? Have verified the apple-app-site-association files have not changed and that the Associated Domains in any recent app releases all are the same.
1
1
518
Feb ’24
App Clip Invocation Issues on iOS 18 and iOS 18.1 - NFC and QR Invocation not working for Default App Clip Experience
We have identified an issue on iOS 18 and iOS 18.1 (developer beta) where App Clips invoked via NFC or QR codes without a pre-configured Advanced App Clip experience (aka they should be using the Default App Clip Experience) are not functioning as expected. This issue is specific to iOS 18, as the behavior works correctly on iOS devices running 17.x. Steps to Reproduce: Set up two scenarios: One scenario where an App Clip has a pre-configured advanced app clip experience (with metadata such as title, subtitle, image). Another scenario where the App Clip is invoked without any pre-configured experience (should use the default App Clip experience). On an iOS 18 or iOS 18.1 device: For the default App Clip experience (no pre-configured advanced app clip experence): Scan the NFC tag when the phone is locked. Scan the NFC tag when the phone is unlocked. Scan the QR code. For the pre-configured App Clip experience: Perform the same tests (NFC and QR code scans). Test the same scenarios on an iOS 17 device for comparison. Expected Behavior: For default App Clip experience invocations (NFC or QR): Scanning NFC or QR should still trigger the App Clip card, even without metadata or a pre-configured advanced experience, on both locked and unlocked devices. For pre-configured Advanced App Clip Experence invocations: The App Clip card should display correctly with the configured metadata and behave as expected on both locked and unlocked devices. Observed Behavior on iOS 18 and iOS 18.1: For default App Clip experience invocations: When scanning the NFC tag on a locked device, an error message is shown - e.g., "App Clip Unavailable" or "The operation couldn't be completed. (CPSErrorDomain error 2.)" . When scanning the NFC tag on an unlocked device, the system redirects straight to the web browser instead of displaying the App Clip card (or even the normal NFC top of screen push notification style thing) Scanning the QR code also prompts the user to open the web browser similar to the experience of scanning a non app clip QR code, skipping the expected App Clip experience. For pre-configured Advanced App Clip Experence invocations: The App Clip behaves as expected, showing the correct card with metadata and functioning properly on both locked and unlocked devices. Notes: The issue is only observed on iOS 18 and iOS 18.1, while the expected behavior is working fine on iOS 17. This may indicate a regression or change in behavior introduced with iOS 18 that affects App Clip invocations that do not have a pre-configured experience.
0
4
154
1w
Call Blocking and Identification Not Working in iOS 18 Beta
We are experiencing an issue with the Call Blocking and Identification feature in iOS 18 Beta. This feature was functioning correctly in iOS 17, but after updating to the iOS 18 Beta, it no longer works as expected looks like iOS is blocking the number because we are getting notification but still we are getting the direct calls. We have attached the Kindly waiting for you replay. Thanks.
7
0
996
Jul ’24
CA certificate is not trusted on iOS 18 and iPadOS 18
Hi everyone, I have an iPad with iOS 18 and used my old device to sync data. There is a trusted CA certificate on my old device. After device data synchronization, the certificate was not synchronized on the iPad. When I tried to manually install the CA certificate on my iPad, it was not in the device's certificate trust settings. Environment • iOS Version: iOS 18 • Device: iPad mini 5 Thank you
0
2
173
1w
PDFKit PDFPage.characterBounds(at:) returns incorrect coordinates iOS 18 beta 4
PDFKit PDFPage.characterBounds(at: Int) is returning incorrect coordinates with iOS 18 beta 4 and later / Xcode 16 beta 4. It worked fine in iOS 17 and earlier (after showing the same issue during the early iOS 17 beta cycle) It breaks critical functionality that my app relies on. I have filed feedback (FB14843671). So far no changes in the latest betas. iOS release date is approaching fast! Anybody having the same issue? Any workaround available?
3
1
463
Aug ’24
Speech Recognition Problem in iOS 18.0
It looks like Apple has added some new API(s) to SFSpeechRecognition My app, which is currently listed on App Store does feature speech recognition. Yet, trying to use it under iOS 18.0 throws errors: -[SFSpeechRecognitionTask localSpeechRecognitionClient:speechRecordingDidFail:]_block_invoke Ignoring subsequent local speech recording error: Error Domain=kAFAssistantErrorDomain Code=1101 "(null)" What happens is that after several words are transcribed and displayed, the next sentence results in previous words disappearance. That's probably what that portion of the error text - "Ignoring subsequent local speech recording error: Error Domain=kAFAssistantErrorDomain Code=1101 "(null)" means. The problem occurs ONLY when the app is running under iOS 18.0 Even when it's compiled in Xcode 16.0 using iOS 17.5 everything works fine. Any suggestions?
21
6
1.3k
Aug ’24
FinderSync Extension UI disappear on macOS 15's Setting
Description We used to use FIFinderSyncController.showExtensionManagementInterface() to navigate to the corresponding Setting's path via a button in our app to make the user enable our FinderSync App. (Or user can navigate manually via "System Settings -> Privacy & Security -> Extensions -> Added Extensions" themselves in Settings.app) But the UI is now disappearing on macOS 15.0 As a result, if user had previously enabled it, user will now be unable to disable it, and if user had not previously enabled it, user will never be able to enable it. STEPS TO REPRODUCE Create an empty macOS app xcodeprojc, add Finder Sync Extension and run it. Or you can use the repo here to reproduce the issue. https://github.com/Kyle-Ye/MenuHelper
1
2
108
1w
File transfer issue from iPhone to Watch after iOS 17.5 & WatchOS 10.5 update
After updating to iOS 17.5 & WatchOS 10.5, the didFinish response from WCSessionDelegate does not come when transferring files from iPhone to Watch. It worked normally until 17.4 & 10.4. There is no problem with checking file completion even if a didFinish response is not received, but I think Apple needs to check this issue and update. File transfer is done using the transferFile function of WCSession. The file being transferred is a single file and its size does not exceed 30MB. When you try to transfer Pi, the message below appears in the Xcode log section. -[WCFileStorage persistOutgoingFileTransfer:] error serializing file transfer <WCSessionFileTransfer: 0x300155d60, session file: <WCSessionFile: 0x3001575c0, identifier: 0C8857EC-7D74-4E78-BA28-6C5526DE8949, file: /private/var/mobile/Containers/Data/Application/DD797847-DED1-42C0-989F-34CD05825007/tmp/C042D096-F12B-4B50-8792-868475DBBF47.zip, hasMetadata: YES>, transferring: YES> due to Error Domain=NSCocoaErrorDomain Code=4866 "Caught exception during archival: This object may only be encoded by an NSXPCCoder. ( 0 CoreFoundation 0x000000019b064f2c 00E76A98-210C-3CB5-930B-F236807FF24C + 540460 1 libobjc.A.dylib 0x0000000192ef6018 objc_exception_throw + 60 2 Foundation 0x0000000199fe7778 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 1419128 3 Foundation 0x0000000199ea0e14 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 81428 4 WatchConnectivity 0x000000021d055f60 1AB4DDD6-9238-3965-B744-819F2916C8CC + 126816 5 Foundation 0x0000000199ea0e14 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 81428 6 WatchConnectivity 0x000000021d0567f0 1AB4DDD6-9238-3965-B744-819F2916C8CC + 129008 7 Foundation 0x0000000199ea0e14 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 81428 8 Foundation 0x0000000199f30628 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 669224 9 WatchConnectivity 0x000000021d0583ac 1AB4DDD6-9238-3965-B744-819F2916C8CC + 136108 10 WatchConnectivity 0x000000021d04390c 1AB4DDD6-9238-3965-B744-819F2916C8CC + 51468 11 WatchConnectivity 0x000000021d046640 1AB4DDD6-9238-3965-B744-819F2916C8CC + 63040 12 Foundation 0x0000000199ea9be0 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 117728 13 Foundation 0x0000000199ea9aa0 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 117408 14 Foundation 0x0000000199ea98a0 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 116896 15 Foundation 0x0000000199ea7b40 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 109376 16 Foundation 0x0000000199f2c558 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 652632 17 Foundation 0x0000000199f2c1a4 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 651684 18 libdispatch.dylib 0x0000000105ed7764 _dispatch_block_async_invoke2 + 148 19 libdispatch.dylib 0x0000000105ec67bc _dispatch_client_callout + 20 20 libdispatch.dylib 0x0000000105ec98e0 _dispatch_continuation_pop + 676 21 libdispatch.dylib 0x0000000105ec8bb8 _dispatch_async_redirect_invoke + 680 22 libdispatch.dylib 0x0000000105edaae4 _dispatch_root_queue_drain + 404 23 libdispatch.dylib 0x0000000105edb4d8 _dispatch_worker_thread2 + 188 24 libsystem_pthread.dylib 0x00000001f7ebb8f8 _pthread_wqthread + 228 25 libsystem_pthread.dylib 0x00000001f7eb80cc start_wqthread + 8 )" UserInfo={NSDebugDescription=Caught exception during archival: This object may only be encoded by an NSXPCCoder. ( 0 CoreFoundation 0x000000019b064f2c 00E76A98-210C-3CB5-930B-F236807FF24C + 540460 1 libobjc.A.dylib 0x0000000192ef6018 objc_exception_throw + 60 2 Foundation 0x0000000199fe7778 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 1419128 3 Foundation 0x0000000199ea0e14 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 81428 4 WatchConnectivity 0x000000021d055f60 1AB4DDD6-9238-3965-B744-819F2916C8CC + 126816 5 Foundation 0x0000000199ea0e14 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 81428 6 WatchConnectivity 0x000000021d0567f0 1AB4DDD6-9238-3965-B744-819F2916C8CC + 129008 7 Foundation 0x0000000199ea0e14 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 81428 8 Foundation 0x0000000199f30628 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 669224 9 WatchConnectivity 0x000000021d0583ac 1AB4DDD6-9238-3965-B744-819F2916C8CC + 136108 10 WatchConnectivity 0x000000021d04390c 1AB4DDD6-9238-3965-B744-819F2916C8CC + 51468 11 WatchConnectivity 0x000000021d046640 1AB4DDD6-9238-3965-B744-819F2916C8CC + 63040 12 Foundation 0x0000000199ea9be0 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 117728 13 Foundation 0x0000000199ea9aa0 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 117408 14 Foundation 0x0000000199ea98a0 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 116896 15 Foundation 0x0000000199ea7b40 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 109376 16 Foundation 0x0000000199f2c558 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 652632 17 Foundation 0x0000000199f2c1a4 3D3A12E3-F5E9-361F-B00A-4A5E8861AA55 + 651684 18 libdispatch.dylib 0x0000000105ed7764 _dispatch_block_async_invoke2 + 148 19 libdispatch.dylib 0x0000000105ec67bc _dispatch_client_callout + 20 20 libdispatch.dylib 0x0000000105ec98e0 _dispatch_continuation_pop + 676 21 libdispatch.dylib 0x0000000105ec8bb8 _dispatch_async_redirect_invoke + 680 22 libdispatch.dylib 0x0000000105edaae4 _dispatch_root_queue_drain + 404 23 libdispatch.dylib 0x0000000105edb4d8 _dispatch_worker_thread2 + 188 24 libsystem_pthread.dylib 0x00000001f7ebb8f8 _pthread_wqthread + 228 25 libsystem_pthread.dylib 0x00000001f7eb80cc start_wqthread + 8 )}
27
13
3.2k
May ’24
Restricting available units for a Measurement<UnitDuration> @Parameter
Hello, I'm preparing my app Tameno for iOS 18, adding a couple of Control Center widgets. One of them allows users to select their favorite interval. But in the context of my app, only seconds and minutes make sense as a unit value - I don't need milli-pseconds, nor hours. Is there a way restrict these available options that come from a ControlConfigurationIntent? @available(iOS 18.0, iOSApplicationExtension 18.0, *) struct TamenoFavoriteIntervalControlWidgetSetupIntent : ControlConfigurationIntent { static let title: LocalizedStringResource = "cw_FavoriteIntervalSetup" static let isDiscoverable: Bool = false @Parameter(title: "cw_IntervalParameter", defaultValue: 5.0, defaultUnit: .seconds, supportsNegativeNumbers: false) var interval: Measurement<UnitDuration>? @MainActor func perform() async throws -> some IntentResult { .result() } } I am able to restrict it just to seconds or minutes only (by adding unit: .seconds, or unit: .minutes to the @Parameter setup), but I'd really like to offer both. Thank you, Matthias
3
0
251
3w
iOS 18 启动崩溃 main_executable_path_missing
Triggered by Thread: 0 Thread 0 Crashed: 0 dyld 0x1a87922b0 lsl::PreallocatedAllocatorLayout<278528ull>::init(char const**, char const**, void*) + 436 1 dyld 0x1a878ba38 start + 1960 Thread 0 crashed with ARM Thread State (64-bit): x0: 0x2010003030100000 x1: 0x0000000fffffc0d0 x2: 0x0000000000000004 x3: 0x00000001a87607a9 x4: 0x0000000000000000 x5: 0x0000000000000000 x6: 0x0000000000000000 x7: 0x0000000000000000 x8: 0x2010003030100000 x9: 0x2010003030100000 x10: 0x000000016d923dfd x11: 0x00000001a87ccf30 x12: 0x0000000000000050 x13: 0x0000000000000044 x14: 0x0000000000052010 x15: 0x0000000000000000 x16: 0x0000000000000000 x17: 0x0000000000000000 x18: 0x0000000000000000 x19: 0x00000001801d0000 x20: 0x000000016d923b50 x21: 0x000000016d923af8 x22: 0x00000001e6184050 x23: 0x000000016d9237d8 x24: 0x0000000fffffc10c x25: 0x0000000000000000 x26: 0x0000000000000000 x27: 0x0000000000000000 x28: 0x0000000000000000 fp: 0x000000016d923870 lr: 0xb0228001a8792130 sp: 0x000000016d9237d0 pc: 0x00000001a87922b0 cpsr: 0x60001000 far: 0x00000001e61840e0 esr: 0x92000047 (Data Abort) byte write Translation fault Binary Images: 0x1a8758000 - 0x1a87db693 dyld arm64e <77c1eed22ed7396aba34e770120d81d4> /usr/lib/dyld 0x1024dc000 - 0x10594ffff main_executable_path_missing arm64 /main_executable_path_missing 0x0 - 0xffffffffffffffff ??? unknown-arch <00000000000000000000000000000000> ??? Error Formulating Crash Report: dyld_process_snapshot_get_shared_cache failed EOF crash.log
4
2
171
1w