Search results for

“DTiPhoneSimulatorErrorDomain Code 2”

162,370 results found

Post

Replies

Boosts

Views

Activity

AppTransaction.shared throws StoreKitError code=2 in macOS TestFlight while deviceVerificationID is available
I am implementing device authentication for a macOS app. Our iOS app uses App Attest, but App Attest is not available on macOS, so we are evaluating StoreKit's AppTransaction plus AppStore.deviceVerificationID as the macOS equivalent signal. The issue: in a macOS app installed through TestFlight, AppStore.deviceVerificationID is available, but AppTransaction.shared throws StoreKitError code=2. I reproduced this in a focused standalone macOS test app with no backend and no custom dependencies. Environment: Platform: macOS Distribution: TestFlight App Store Connect app ID: 6769568350 Bundle ID: com.soundcity.AppTransactionProbe App version: 1.0 Build: 1 Observed output from the TestFlight-installed app: Bundle ID: com.soundcity.AppTransactionProbe App version: 1.0 Build: 1 deviceVerificationID available: true deviceVerificationID prefix: CA91ED5D... AppTransaction.shared threw error: StoreKitError; domain=StoreKit.StoreKitError; code=2 The relevant code path is essen
1
0
183
1w
Is the MapKit Legal Notice required for displaying my own content?
If an application utilizes MapKit exclusively to render custom content via MKTileOverlay (with canReplaceMapContent = true to entirely suppress Apple’s default map layers), are developers still contractually or technically mandated to display Apple's default Legal link? Currently, the hardcoded Apple attribution document details extensive copyright disclaimers for data suppliers like TomTom, Acxiom, and Breezometer. When an application renders entirely standalone, proprietary, or open-source map tiles, displaying this link creates two distinct issues: User Confusion: It incorrectly implies to end-users that the custom data being viewed is sourced from or validated by Apple's third-party data partners. Attribution Inaccuracy: It forces the display of entirely irrelevant copyright data while doing a disservice to the actual copyright holders of the active custom tile layers, who require their own distinct, prominent on-screen credit. It would be a significant UX improvement if the framework could dynam
Topic: UI Frameworks SubTopic: UIKit Tags:
1
0
322
1w
Family Controls (Distribution) — 2 pending requests for 10 days, no status update (WA2MPH4572 + HCQXH9P8VM)
Subject: Family Controls (Distribution) — 2 pending requests for 9 days, no status update (WA2MPH4572 + HCQXH9P8VM) Tags: family-controls Body: Hello Apple Developer Forums and DTS team, I am requesting visibility on the status of two pending Family Controls (Distribution) entitlement requests submitted 10 days ago with no email confirmation or status update. REQUEST DETAILS App: SHIELD Bundle ID: app.shieldme Team ID: 4452N28RUS Request IDs (both submitted on May 6, 2026): WA2MPH4572 HCQXH9P8VM Status: Both showing Submitted in Identifiers → app.shieldme → Family Controls (Distribution) → View Requests USE CASE SHIELD is a Brazilian app focused on personal device usage management. The category covers the scenario the app addresses: device owners who want to apply additional access controls to their own apps in case of phone theft or loss, which are widespread concerns in Brazil. SHIELD is NOT a parental control app and does not facilitate management of devices belonging to other people. The
0
0
185
1w
Reply to Switch view that digital crown controls
The digital crown controls the current focused view. Did you try to use focused(_:equals:) and focusable() to make sure the focus is on your target view? If that doesn't work, maybe you can share your code here for folks to take a look? Best, —— Ziqiao Chen  Worldwide Developer Relations.
Topic: UI Frameworks SubTopic: General Tags:
1w
Count of Windows Open in App Switcher on iPadOS? Tried Via UIApplication.sharedApplication.openSessions
I'm trying to get the count of how many windows an iPadOS app has 'open' (open from the user's perspective in the app switcher). This is for the sake of determining whether I should show or hide a button that takes action on every window (if there is only 1 window, the button will be hidden). According to the documentation the proper API for this is this property on UIApplication: // All of the representations that currently have connected UIScene instances or had their sessions persisted by the system (ex: visible in iOS' switcher) @property(nonatomic, readonly) NSSet *openSessions So I print the count (only sessions with role UIWindowSceneSessionRoleApplication) when scenes are added/removed etc via appropriate lifecycle notifications like -sceneDidDisconnect: -sceneDidBecomeActive: and so forth. What I noticed is when I add a new window scene, the count increases by one so cool, that works. But when I kill a window in the App switcher the count does not decrease. I can end up in a situation where the app h
1
0
320
1w
Reply to How to handle all the core AppleEvents
You're right that SwiftUI covers oapp/rapp/odoc/quit natively, plus GURL via the .onOpenURL modifier. For the events you're asking about: Open content — could you clarify which event you mean? If you're thinking of GURL (Open URL / open this URL or content), that's the onOpenURL path. If you mean something else (a custom ocon or app-specific event), let me know and I can answer specifically. Print document (pdoc) — SwiftUI does not route this to NSApplicationDelegate.application(_:printFiles:withSettings:showPrintPanels:). I verified by sending osascript -e 'tell application Test to print POSIX file ...' to test apps using both WindowGroup and DocumentGroup in macOS 26.4 — the delegate method never fired. So the standard delegate path is silent under SwiftUI. The path that does work is registering directly with NSAppleEventManager. Install your handler in applicationWillFinishLaunching: (before any events arrive) and SwiftUI doesn't fight you for ownership: @main struct MyApp: App { @NSApplicationDelegateAdap
Topic: UI Frameworks SubTopic: SwiftUI Tags:
1w
Reply to NSTextAttachment view flicker while typing in same paragraph
Thanks for posting. I built a minimal test to try to reproduce this — a SwiftUI NSViewRepresentable-wrapped NSTextView with a custom NSTextAttachment subclass and a viewProvider returning a custom NSView. I then stress-tested it against five plausible causes, and none of them reproduced any flicker: Baseline pattern — custom attachment + view provider returning a tinted layer-backed view, type in the same paragraph as the inserted attachment: stable. No caching in loadView() — every call constructs a brand-new NSView with fresh subviews and constraints: stable. Aggressive layout invalidation on every keystroke — NSTextLayoutManager.invalidateLayout(for: documentRange) from a textDidChange: delegate: stable. Mixed content sources — both attachment.image set to a programmatically drawn NSImage and a custom viewProvider returning a separate NSView: stable. Raster image content — loadView() returns an NSView containing an NSImageView with a real NSBitmapImageRep-backed NSImage instead of a layer-tinted plain view
Topic: UI Frameworks SubTopic: AppKit
1w
Reply to After binding to NSBrowser indexPaths the browser assumes I'm using NSBrowserCell and calls unimplemented methods on my NSCell subclass
Hi Macho Man Randy Savage, Your diagnosis is essentially right, and I dug deeper than I expected after reproducing it. The situation is worse than just one wrong selector — NSBrowser's Cocoa Bindings layer doesn't compose with the item-based delegate API at all, regardless of cell class. I built a small test project (item-based NSBrowser, an NSTextFieldCell subclass installed as cellPrototype, and selectionIndexPaths bound to a property). With the binding in place, the app crashes during draw with: *** -[NSTextFieldCell setLeaf:]: unrecognized selector sent to instance ... The actual selector is setLeaf:, not setIsLeaf: (worth knowing if you grep for it). The stack tells the rest of the story: 0 CoreFoundation __exceptionPreprocess 1 libobjc.A.dylib objc_exception_throw ... 5 AppKit -[NSBrowserBinder browser:willDisplayCell:atRow:column:] + 156 6 AppKit -[_NSBindingAdaptor browser:willDisplayCell:atRow:column:] + 288 7 AppKit -[NSBrowser _sendDelegateWillDisplayCell:atRow:column:] + 64 When you bind selection
Topic: UI Frameworks SubTopic: AppKit Tags:
1w
Update stuck in 'In Review' for 80 days
Hello, I'm posting again — and unfortunately, I already know how this thread is going to go. My app (ID: 6756186616) has now been stuck in In Review for 80 days. To save everyone time, here is the reply I expect to receive within a day or two, copy-pasted from the response on my last thread: Thank you for your post. We're investigating and The App Review team will contact you in App Store Connect to provide further assistance. If you continue to experience issues during review, please contact us. Nothing actually happened after that reply last time. No follow-up in App Store Connect. No further communication. Just silence. When I escalated to Developer Support (case #20000111565861), I was told explicitly that Developer Support has no way to reach the App Review team and no authority to intervene on submissions stuck in review. So Developer Support points back to App Review, and the standard forum reply points back to contact us — which loops back to Developer Support. This is a closed loop that does
0
0
285
1w
Reply to iOS crash: EXC_BAD_ACCESS in iOS 26+ when mouting/dismounting WebView
Thanks for posting the crash log. The stack you've shown isn't enough on its own to point at a specific cause — the WebKit frames are still , and there's no information about the WebView itself or what triggers the crash. Before going further, could you share the following? The WebView setup — how you create, configure, and present or dismiss the WebView. The relevant view controller code, your WKWebViewConfiguration, and the navigation flow that leads to the crash. Reproduction steps — what does someone do (or what does the app do) right before the crash? The frame _UIContextMenuAnimator performAllCompletions suggests a long-press preview menu may be involved. Does the crash require a context menu to have opened first? Frequency and conditions — does this happen in your own testing, or only in production via crash analytics? Specific iOS version (26.0, 26.1, 26.4)? Specific devices? Any particular network or content state? The original crash report, not a forwarded copy — those WebKit frames are us
Topic: Safari & Web SubTopic: General Tags:
1w
Reply to Programatically adding to a TextField and moving the TextSelection point in SwiftUI
Thanks for the focused reproducer and the video — they made this easy to investigate. There are two separate problems in what you're seeing, and the right answer is to switch to a different SwiftUI API for this kind of programmatic text editing. The bug in your code: String.Index invalidation after replaceSubrange RangeReplaceableCollection.replaceSubrange(_:with:) invalidates all indices into the collection (per the documentation), not just indices at or after the modified range. In your code: self.text.replaceSubrange(from..
Topic: UI Frameworks SubTopic: SwiftUI Tags:
1w
Reply to Programatically adding to a TextField and moving the TextSelection point in SwiftUI
Thank you! Very much appreciate the workaround ideas and the correction to the code. I will also file a feedback report.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w
AppTransaction.shared throws StoreKitError code=2 in macOS TestFlight while deviceVerificationID is available
I am implementing device authentication for a macOS app. Our iOS app uses App Attest, but App Attest is not available on macOS, so we are evaluating StoreKit's AppTransaction plus AppStore.deviceVerificationID as the macOS equivalent signal. The issue: in a macOS app installed through TestFlight, AppStore.deviceVerificationID is available, but AppTransaction.shared throws StoreKitError code=2. I reproduced this in a focused standalone macOS test app with no backend and no custom dependencies. Environment: Platform: macOS Distribution: TestFlight App Store Connect app ID: 6769568350 Bundle ID: com.soundcity.AppTransactionProbe App version: 1.0 Build: 1 Observed output from the TestFlight-installed app: Bundle ID: com.soundcity.AppTransactionProbe App version: 1.0 Build: 1 deviceVerificationID available: true deviceVerificationID prefix: CA91ED5D... AppTransaction.shared threw error: StoreKitError; domain=StoreKit.StoreKitError; code=2 The relevant code path is essen
Replies
1
Boosts
0
Views
183
Activity
1w
Is the MapKit Legal Notice required for displaying my own content?
If an application utilizes MapKit exclusively to render custom content via MKTileOverlay (with canReplaceMapContent = true to entirely suppress Apple’s default map layers), are developers still contractually or technically mandated to display Apple's default Legal link? Currently, the hardcoded Apple attribution document details extensive copyright disclaimers for data suppliers like TomTom, Acxiom, and Breezometer. When an application renders entirely standalone, proprietary, or open-source map tiles, displaying this link creates two distinct issues: User Confusion: It incorrectly implies to end-users that the custom data being viewed is sourced from or validated by Apple's third-party data partners. Attribution Inaccuracy: It forces the display of entirely irrelevant copyright data while doing a disservice to the actual copyright holders of the active custom tile layers, who require their own distinct, prominent on-screen credit. It would be a significant UX improvement if the framework could dynam
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
1
Boosts
0
Views
322
Activity
1w
Family Controls (Distribution) — 2 pending requests for 10 days, no status update (WA2MPH4572 + HCQXH9P8VM)
Subject: Family Controls (Distribution) — 2 pending requests for 9 days, no status update (WA2MPH4572 + HCQXH9P8VM) Tags: family-controls Body: Hello Apple Developer Forums and DTS team, I am requesting visibility on the status of two pending Family Controls (Distribution) entitlement requests submitted 10 days ago with no email confirmation or status update. REQUEST DETAILS App: SHIELD Bundle ID: app.shieldme Team ID: 4452N28RUS Request IDs (both submitted on May 6, 2026): WA2MPH4572 HCQXH9P8VM Status: Both showing Submitted in Identifiers → app.shieldme → Family Controls (Distribution) → View Requests USE CASE SHIELD is a Brazilian app focused on personal device usage management. The category covers the scenario the app addresses: device owners who want to apply additional access controls to their own apps in case of phone theft or loss, which are widespread concerns in Brazil. SHIELD is NOT a parental control app and does not facilitate management of devices belonging to other people. The
Replies
0
Boosts
0
Views
185
Activity
1w
Reply to Switch view that digital crown controls
The digital crown controls the current focused view. Did you try to use focused(_:equals:) and focusable() to make sure the focus is on your target view? If that doesn't work, maybe you can share your code here for folks to take a look? Best, —— Ziqiao Chen  Worldwide Developer Relations.
Topic: UI Frameworks SubTopic: General Tags:
Replies
Boosts
Views
Activity
1w
Count of Windows Open in App Switcher on iPadOS? Tried Via UIApplication.sharedApplication.openSessions
I'm trying to get the count of how many windows an iPadOS app has 'open' (open from the user's perspective in the app switcher). This is for the sake of determining whether I should show or hide a button that takes action on every window (if there is only 1 window, the button will be hidden). According to the documentation the proper API for this is this property on UIApplication: // All of the representations that currently have connected UIScene instances or had their sessions persisted by the system (ex: visible in iOS' switcher) @property(nonatomic, readonly) NSSet *openSessions So I print the count (only sessions with role UIWindowSceneSessionRoleApplication) when scenes are added/removed etc via appropriate lifecycle notifications like -sceneDidDisconnect: -sceneDidBecomeActive: and so forth. What I noticed is when I add a new window scene, the count increases by one so cool, that works. But when I kill a window in the App switcher the count does not decrease. I can end up in a situation where the app h
Replies
1
Boosts
0
Views
320
Activity
1w
Core Data for 2 level data
I'm attempting to create a feature where I can allow two levels of information
Replies
2
Boosts
0
Views
493
Activity
1w
Reply to How to handle all the core AppleEvents
You're right that SwiftUI covers oapp/rapp/odoc/quit natively, plus GURL via the .onOpenURL modifier. For the events you're asking about: Open content — could you clarify which event you mean? If you're thinking of GURL (Open URL / open this URL or content), that's the onOpenURL path. If you mean something else (a custom ocon or app-specific event), let me know and I can answer specifically. Print document (pdoc) — SwiftUI does not route this to NSApplicationDelegate.application(_:printFiles:withSettings:showPrintPanels:). I verified by sending osascript -e 'tell application Test to print POSIX file ...' to test apps using both WindowGroup and DocumentGroup in macOS 26.4 — the delegate method never fired. So the standard delegate path is silent under SwiftUI. The path that does work is registering directly with NSAppleEventManager. Install your handler in applicationWillFinishLaunching: (before any events arrive) and SwiftUI doesn't fight you for ownership: @main struct MyApp: App { @NSApplicationDelegateAdap
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w
Reply to NSTextAttachment view flicker while typing in same paragraph
Thanks for posting. I built a minimal test to try to reproduce this — a SwiftUI NSViewRepresentable-wrapped NSTextView with a custom NSTextAttachment subclass and a viewProvider returning a custom NSView. I then stress-tested it against five plausible causes, and none of them reproduced any flicker: Baseline pattern — custom attachment + view provider returning a tinted layer-backed view, type in the same paragraph as the inserted attachment: stable. No caching in loadView() — every call constructs a brand-new NSView with fresh subviews and constraints: stable. Aggressive layout invalidation on every keystroke — NSTextLayoutManager.invalidateLayout(for: documentRange) from a textDidChange: delegate: stable. Mixed content sources — both attachment.image set to a programmatically drawn NSImage and a custom viewProvider returning a separate NSView: stable. Raster image content — loadView() returns an NSView containing an NSImageView with a real NSBitmapImageRep-backed NSImage instead of a layer-tinted plain view
Topic: UI Frameworks SubTopic: AppKit
Replies
Boosts
Views
Activity
1w
Reply to After binding to NSBrowser indexPaths the browser assumes I'm using NSBrowserCell and calls unimplemented methods on my NSCell subclass
Hi Macho Man Randy Savage, Your diagnosis is essentially right, and I dug deeper than I expected after reproducing it. The situation is worse than just one wrong selector — NSBrowser's Cocoa Bindings layer doesn't compose with the item-based delegate API at all, regardless of cell class. I built a small test project (item-based NSBrowser, an NSTextFieldCell subclass installed as cellPrototype, and selectionIndexPaths bound to a property). With the binding in place, the app crashes during draw with: *** -[NSTextFieldCell setLeaf:]: unrecognized selector sent to instance ... The actual selector is setLeaf:, not setIsLeaf: (worth knowing if you grep for it). The stack tells the rest of the story: 0 CoreFoundation __exceptionPreprocess 1 libobjc.A.dylib objc_exception_throw ... 5 AppKit -[NSBrowserBinder browser:willDisplayCell:atRow:column:] + 156 6 AppKit -[_NSBindingAdaptor browser:willDisplayCell:atRow:column:] + 288 7 AppKit -[NSBrowser _sendDelegateWillDisplayCell:atRow:column:] + 64 When you bind selection
Topic: UI Frameworks SubTopic: AppKit Tags:
Replies
Boosts
Views
Activity
1w
Update stuck in 'In Review' for 80 days
Hello, I'm posting again — and unfortunately, I already know how this thread is going to go. My app (ID: 6756186616) has now been stuck in In Review for 80 days. To save everyone time, here is the reply I expect to receive within a day or two, copy-pasted from the response on my last thread: Thank you for your post. We're investigating and The App Review team will contact you in App Store Connect to provide further assistance. If you continue to experience issues during review, please contact us. Nothing actually happened after that reply last time. No follow-up in App Store Connect. No further communication. Just silence. When I escalated to Developer Support (case #20000111565861), I was told explicitly that Developer Support has no way to reach the App Review team and no authority to intervene on submissions stuck in review. So Developer Support points back to App Review, and the standard forum reply points back to contact us — which loops back to Developer Support. This is a closed loop that does
Replies
0
Boosts
0
Views
285
Activity
1w
StoreKit 2 returns empty products array on device (iPhone) even though IAP is Ready to Submit
Hi, I’m experiencing an issue with StoreKit 2 in my iOS app where Product.products(for:) always returns an empty array on a real iPhone device. iOS: 26 Device: iPhone 16 pro Max Xcode: 26.5 StoreKit: StoreKit 2
Replies
0
Boosts
0
Views
132
Activity
1w
Reply to iOS crash: EXC_BAD_ACCESS in iOS 26+ when mouting/dismounting WebView
Thanks for posting the crash log. The stack you've shown isn't enough on its own to point at a specific cause — the WebKit frames are still , and there's no information about the WebView itself or what triggers the crash. Before going further, could you share the following? The WebView setup — how you create, configure, and present or dismiss the WebView. The relevant view controller code, your WKWebViewConfiguration, and the navigation flow that leads to the crash. Reproduction steps — what does someone do (or what does the app do) right before the crash? The frame _UIContextMenuAnimator performAllCompletions suggests a long-press preview menu may be involved. Does the crash require a context menu to have opened first? Frequency and conditions — does this happen in your own testing, or only in production via crash analytics? Specific iOS version (26.0, 26.1, 26.4)? Specific devices? Any particular network or content state? The original crash report, not a forwarded copy — those WebKit frames are us
Topic: Safari & Web SubTopic: General Tags:
Replies
Boosts
Views
Activity
1w
Reply to Programatically adding to a TextField and moving the TextSelection point in SwiftUI
Thanks for the focused reproducer and the video — they made this easy to investigate. There are two separate problems in what you're seeing, and the right answer is to switch to a different SwiftUI API for this kind of programmatic text editing. The bug in your code: String.Index invalidation after replaceSubrange RangeReplaceableCollection.replaceSubrange(_:with:) invalidates all indices into the collection (per the documentation), not just indices at or after the modified range. In your code: self.text.replaceSubrange(from..
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w
StoreKit 2 returns empty products array on device (iPhone) even though IAP is Ready to Submit
Hi, I'm experiencing an issue with StoreKit 2 in my iOS app where Product.products(for:) always returns an empty array on a real iPhone device. 📱 Environment iOS: 26 Device: iPhone 16 pro max Xcode: 26.5 StoreKit: StoreKit 2
Replies
1
Boosts
0
Views
102
Activity
2w