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.

Posts under General subtopic

Post

Replies

Boosts

Views

Activity

Screen Time reaches the iPhone Instagram limit after Mac sync while Instagram is in the background (on both devices)
Hello, I have noticed, once again, that DeviceActivityMonitors are quite frustrating to work with, since they are triggering random events when using mulitple Apple devices. For example, if Instagram is open on some random (non-foreground!) tab in Safari on the Mac, the iPhone will reach its limit quite consistently & quickly atfer setting up a new device activity threshold. It would be great if A) background usage was not counted towards screen time: FB25576930 B) there was an API for us developers to set-up device-specific deviceactivitymonitors: FB24363336 Hope that helps!
0
0
102
1w
URGENT: Muse is AUTOMATICALLY blocked by Screen Time API whenever Facebook is blocked, 100% of the time with no workaround for users or developers
PLEASE ADDRESS ASAP: Muse is #1 on the App Store and Facebook is one of the most blocked apps for Screen Time. This is affecting a vast number of people. Description: When a user blocks the Facebook app in any screen time app, iOS automatically blocks Meta's Muse app too. Every single time. There is no way for the user or the developer to prevent it, allowlist it, or even detect that it happened. Muse shows Apple's generic blocked-app "Restricted" screen instead of the screen time app's own design, so the user cannot tell who blocked it or why. This is the worst possible combination of apps: Facebook is one of the most-blocked app across screen time apps. Muse ("Muse from Meta") is currently the #1 app on the App Store. A huge and fast-growing number of users block Facebook and silently lose the world's most popular new app. Muse launched Sept 8, 2026 and adoption is still climbing -- the affected population grows every day. There is NO workaround whatsoever: Users cannot allowlist Muse: it does not appear in Settings > Screen Time > Always Allowed. Developers cannot prevent it: the Screen Time API offers no opt-out; the extra block is applied by iOS itself. Developers cannot detect it: Muse's token (listed separately in FamilyActivityPicker) corresponds to no real identity anywhere else. Developers cannot customize it: their ShieldConfiguration is never consulted -- Muse gets Apple's generic shield UI. Users cannot even block Muse on purpose: shielding Muse's own token is a silent no-op. Screen Time usage statistics are also wrong -- Muse usage is recorded as "Facebook." This Screen Time bug renders screen time apps effectively unusable if users want to block Facebook and use Muse, which is extremely common. How can we get this addressed as soon as possible? Feedback Assistant ticket: https://feedbackassistant.apple.com/feedback/25019832
9
9
690
1w
Autoupdate of macOS app via Sparkle library fails
We have a macOS app distributed outside of the Mac App Store (Developer ID distribution). It incorporates the popular Sparkle library which offers autoupdate functionality (downloading and installing new versions of the app). The autoupdate functionality worked flawlessly for many years but with recent versions of macOS it started failing. To demonstrate the problem we offer the dts-demo.tar.gz file (available for download, see the links below). That file contains the sources of DemoApp and a build_packages.sh script that builds installer packages for two versions of DemoApp. The old version is 3.0 and the new version is 4.0. Manually installing the old version (by double-clicking the .pkg file and following the instructions) succeeds. After launching the app, trying to autoupdate to the new version by clicking the "Check for update" button fails. The process starts, the old version is deinstalled but then the installation of the new version fails. Manually installing the new version of the app over the old version succeeds. The problem has been observed on macOS versions after 26.6.2 (e.g. 26.7.3 or 27.0). The files we offer for download are: dts-demo.tar.gz at https://dx4vjdxzj60n5.cloudfront.net/dts-demo.tar.gz manual_install_v3.log at https://dx4vjdxzj60n5.cloudfront.net/manual_install_v3.log autoupdate_to_v4.log at https://dx4vjdxzj60n5.cloudfront.net/autoupdate_to_v4.log manual_install_v4_over_v3.log at https://dx4vjdxzj60n5.cloudfront.net/manual_install_v4_over_v3.log The provided log files are excerpts from the system's install.log file. The Sparkle framework included in dts-demo.tar.gz comes from the official Sparkle 2.10.1 release. That version is the latest available at the time of writing. Please note that it only accepts URLs with 'http' or 'https' schemes. This autoupdate problem looks like a bug in macOS because manual updates succeed. We'd like to have the bug fixed or at least find a workaround.
3
0
80
1w
CXCallUpdate not working for outgoing calls
I try to update remoteHandle using CXCallUpdate for outgoing call, but this works only on iOS 15 but not on 17 or 18 (16 didn't test). This problem actual only for outgoing calls, but for incoming calls update works fine. func startOutgoingCall(with callID: UUID, userID: String) { let handle = CXHandle(type: .generic, value: userID) let action = CXStartCallAction(call: callID, handle: handle) callController.requestTransaction(with: action) { [weak self] error in // ... } } func updateOutgoingCall(with callID: UUID, groupID: String) { let update = CXCallUpdate() update.remoteHandle = CXHandle(type: .generic, value: groupID) provider.reportCall(with: callID, updated: update) } I also tried phoneNumber type but it seems initial handle that I set to CXStartCallAction not possible to change (value or even type). I use this handle value to implement recall by tap on call in Recents tab of system address book. But since my calls can transform from p2p to group call, I need to update handle value or find some another way to pass call identification info.
5
1
1.4k
1w
Can an iOS app share Screen Time goal progress with friends?
I'm developing an app that helps users reduce social media usage through friendly competitions. With explicit permission, the app would track daily and weekly usage of selected apps like Instagram, TikTok, and YouTube. Users could voluntarily share their live total usage, percentage improvement, or goal-completion status with approved friends. Does Apple's Family Controls policy permit this? If not, is there an approved way to implement a friends leaderboard using Screen Time data? Thank you!
0
0
52
1w
Declared Age Range in sandbox: no sheet at launch, and the set per scenario
We are testing the Declared Age Range API with sandbox testers on an iPhone 17e with iOS 26.6.2 (Xcode 26.6, iOS 26.5 SDK). The app is not yet released; everything here is pre-release testing. We have filed three focused reports: FB25530441 (requestAgeRange returned .declinedSharing with no sheet), FB25530501 (the age that Age Assurance first shows at a sign-in against what the API reads), and FB25530513 (a selected scenario not reflected in requiredRegulatoryFeatures). Four questions remain that are not defects: When a sandbox tester has an Age Assurance scenario selected, should requestAgeRange present the sheet at launch, or answer from the scenario without showing one? Is there a way to see the sheet at launch in sandbox, as a first-time user would, so we can test the share and decline paths end to end? The article "Requesting people's age range information in your app" says the set's values "tell you which actions you need to take for compliance", and the sandbox page lists each scenario's age range, but we found neither saying which members each scenario produces. Please confirm: for each Age Assurance scenario, and for a tester with no scenario selected, what should requiredRegulatoryFeatures contain? Does the tester's App Store territory or creation date matter in sandbox? On 1 and 2. Our app calls requestAgeRange at launch when requiredRegulatoryFeatures contains .declaredAgeRangeRequired. On four days between October 31 and November 7, 2026, at every launch where we know it did make the request, Apple's age range sheet did not appear. Some requests we made by hand from a debug console returned the scenario's range with no sheet: on November 7, one on each of two testers on '13 - 15' returned a shared range of 13 to 15. One such request on October 31 did present the sheet; it is the only sheet on record across the four days (at a few launches the sheet was not written down separately). On 3. What we read on one tester, in this order, each scenario read before and after a relaunch unless noted: No scenario selected (signed in for the first time; Age Assurance showed no option selected), read after a relaunch only: none of the three members. '13 - 15, significant change approved', then '16 - 17, significant change declined', then 'Under 13, significant change approved': .declaredAgeRangeRequired and .significantAppChangeRequiresParentalConsent. '18+, age confirmed, significant change not applicable': .declaredAgeRangeRequired only. '18+, age confirmed, significant change applicable': .declaredAgeRangeRequired and .significantAppChangeRequiresAdultNotification. '18+, age not confirmed, significant change not applicable': .declaredAgeRangeRequired only. For these rows we read contains for the three members the iOS 26.5 SDK defines, so a member outside those three would not show. On November 5 we printed the whole set on 15 reads of sandbox testers, and no other member appeared.
0
0
75
1w
PDF Widget Annotations Disappear After Saving in PDFKit (including with Preview)
The Problem When a user toggles radio buttons or checkboxes in a PDF using Preview, the widgets disappear following subsequent interactions after the file is saved and reopened. This renders the form fields unusable. Steps to Reproduce the Problem Open a PDF with radio buttons or checkboxes in Preview. Toggle a radio button or checkbox. Save and close the file. Re-open the PDF in Preview. Toggle the same button again. The button (and any others with the same field name) will disappear. Expected Results Toggling a radio button or checkbox should update the field value without causing the button (or related buttons) to disappear. This behavior is consistent with previous versions of PDFKit. What is Happening In Preview, interacting with radio buttons and checkboxes correctly updates their appearance as expected. Saving the PDF, however, causes the appearance dictionary to reference a new N entry that is a single appearance stream unassociated with any state. The annotation's AS entry is not updated. The original N entry remains but is no longer referenced. Subsequent interactions fail to update the visual presentation because the appearance stream is missing. Impact on User Experience Radio buttons and checkboxes may disappear and become unusable when toggled. PDF documents become irreparably altered after a button is toggled and the file is saved. PDF file size significantly increases when the file is saved. Users may believe they have successfully completed a form, only for the data to become inaccessible or invisible to recipients. Forms may need to be completely restarted or recreated from scratch if the original becomes unusable. The corrupted PDF structure might cause the file to render incorrectly or crash in third-party PDF viewers. Affected Apps/OSs Tested with Preview 11.0 (1147), as well as other apps that use PDFKit, on macOS Golden Gate 27.0 (26A428). This problem also affects PDFKit on iOS 27.0 and iPadOS 27.0. Feedback/bug report: FB24866826 Related Sample Output Original PDF File Checkbox widget annotation (6 0 obj), its appearance dictionary (17 0 obj), and normal appearance dictionary (18 0 obj). Button is not checked. 6 0 obj << /Border [ 0 0 0 ] /Rect [ 90 390 110 410 ] /T (button1) /F 4 /Subtype /Widget /DA (/.AppleSystemUIFont 13 Tf 0 g) /MK 16 0 R /C [ 0 ] /AP 17 0 R /V /Off /M (D:20260919225320Z00'00') /AS /Off /FT /Btn /Type /Annot /Ff 0 >> endobj 17 0 obj << /N 18 0 R >> endobj 18 0 obj << /Yes 20 0 R /Off 22 0 R >> endobj PDF File after Save Checkbox widget annotation object (6 0 obj), its new appearance dictionary object (8 0 obj), a new normal appearance stream object (20 0 obj), and the original appearance stream dictionary (now 21 0 obj). File saved after user checked button. 6 0 obj << /Ff 0 /Type /Annot /AS /Off /AP 8 0 R /MK 9 0 R /C [ 0 ] /FT /Btn /M (D:20260919225320Z00'00') /DA (/.AppleSystemUIFont 13 Tf 0 g) /Subtype /Widget /F 4 /Border [ 0 0 0 ] /Rect [ 90 390 110 410 ] /T (button1) /V (Yes) >> endobj 8 0 obj << /N 20 0 R >> endobj 20 0 obj << /Filter /FlateDecode /Resources << /ColorSpace << /CS1 [ /ICCBased 29 0 R ] /CS2 [ /ICCBased 30 0 R ] >> >> /BBox [ 0 0 20 20 ] /Type /XObject /Subtype /Form /Length 123 >> stream x UéA ¬0 Ô}≈|†≈nà¢úÛÇ* —SA =}Ïr(»ñµ≤w◊€YËà’|ÙÎŒç'óRï∂#SäÏÌü∞¢S‰Ì§ôRÌX }–É•åY Éçˆ BŒ H " *â´8™ˆZø6z⁄ÿ ”ú6ɀ੠"∫t˘‹;'¬ endstream endobj 21 0 obj << /Off 22 0 R /Yes 23 0 R >> endobj Note: No object references 21 0 obj in the PDF.
5
0
1.1k
1w
PDF Widget Annotations appear Pixelated/Rasterized
The Problem On opening a PDF document in the Preview app, PDF widget annotations appear pixelated/rasterized. This problem exists with button, text, and choice widget subtypes. The pixelation becomes more apparent when zoomed in. Expected Results PDF widgets should appear sharp and smooth, without pixelation. In previous versions of the Preview app, widgets appear vector-based as expected. Impact on User Experience PDF widgets appear pixelated and inconsistent with text content in the same PDF document. Widgets do not look like elements of an interactive form but, instead, resemble low-quality embedded images. Affected Apps/OSs: Preview 11.0 (1147), as well as other apps that use PDFKit, on macOS Golden Gate 27.0 (26A428). A similar problem appears to affect PDFKit on iOS 27.0 and iPadOS 27.0 as well. Feedback/bug report: FB24843022
8
3
1.7k
1w
Declared Age Range: fallback behavior, cached results, and older iOS versions
Hello, I am preparing an 18+ workout logging app for iOS and would like to clarify the supported behavior of the Declared Age Range framework before completing its integration. Workout records, body measurements and saved videos are stored locally. Outside additional regulatory requirements, the planned entry flow uses a neutral adult self-declaration without collecting a date of birth or identity documents. The intended storefronts are Japan, the United States, the United Kingdom, Canada, Australia, New Zealand, Ireland and Singapore. These are implementation-design questions, not errors reproduced in a completed DAR integration. I am seeking documented API/platform behavior, not legal approval. Applicability checks that fail If isEligibleForAgeFeatures throws, returns notAvailable, or does not complete, is there a supported fallback signal or recommended retry strategy? I would not interpret an error as a successful “outside regulated scope” result. Is there a documented platform requirement for app access while applicability remains unresolved, separate from developers’ obligations under applicable law? Previously returned adult age ranges If declaredAgeRangeRequired applies and requestAgeRange fails after an earlier adult response, does Apple support relying on an app-stored result? I understand that the system caches responses; my question concerns a result stored separately by the app. Is there a supported way to detect when that result must be invalidated because of an Apple Account change, changes to age information, or sharing/consent changes? If no such signal exists, what implementation pattern does Apple recommend? I would not assume that a previous result always belongs to the current person or invent a cache lifetime. Earlier OS versions For affected newly created Apple Accounts in regulated regions, what supported path applies on: iOS versions without Declared Age Range; iOS 26.0–26.1, without isEligibleForAgeFeatures; iOS 26.2–26.3, without requiredRegulatoryFeatures? The age-assurance Q&A discusses existing Apple Accounts on iOS 18 or earlier. Is there additional documentation covering newly created affected accounts on earlier OS versions? While checks remain unresolved, the proposed design withholds advertising and new purchases and preserves existing data with free export. This is a proposed design, not an assumption that local recording is exempt from any requirement. References reviewed: https://developer.apple.com/support/age-assurance/ https://developer.apple.com/documentation/declaredagerange/requesting-people-share-their-age-range-with-your-app Pointers to relevant documentation or sample code would be appreciated. Thank you.
0
0
42
1w
PushToTalk: headset "play" never starts a transmission (goes to Music) — and is PTT appropriate for voice capture to an assistant?
Hi, We're building a voice assistant app. The user speaks to the assistant through a Bluetooth earset; the app records the speech, transcribes it and the assistant acts on it. We want the user to start and stop that capture from the earset button while the iPhone stays locked, without the Phone call UI. We prototyped this with the PushToTalk framework and have two questions. 1. Headset play button does not reach our joined PTT channel Setup (minimal test app, nothing else running): iPhone 14 Pro Max, iOS 26.6.1 (23G83). Entitlements: com.apple.developer.push-to-talk, aps-environment. Background modes: push-to-talk, audio, bluetooth-central. PTChannelManager.channelManager(delegate:restorationDelegate:) → requestJoinChannel in the foreground → didJoinChannel → setAccessoryButtonEventsEnabled(true, channelUUID:) completes without error. Audio session configured once before joining: .playAndRecord, options .allowBluetoothHFP; tried mode .default and .voiceChat. We never call setActive; audio starts only in didActivate (AVAudioEngine). What works: The system PTT UI talk button, phone locked: didBeginTransmitting → didActivate (earset HFP 16 kHz) → audio recorded. A Lock Screen / Control Center control running an intent that adopts PushToTalkTransmissionIntent, phone locked: one tap starts, one tap ends; 5+ minute transmissions; app cold-launched by the system when needed. What doesn't: pressing the earset's play/pause button (single press) while joined and idle never produces didBeginTransmitting. Same result with AirPods and with a third-party A2DP/HFP earset, locked and unlocked, Music app closed or not. mediaremoted logs, for every press: mediaremoted: Received command from client <... bundleIdentifier = com.apple.BTAvrcp ...>: <... command = Play ...> mediaremoted: No context for context-sensitive command <... command = Play, SenderBundleIdentifier = <com.apple.BTAvrcp> ...> mediaremoted: Destination app com.apple.Music not available for command <... command = Play ...> mediaremoted: Sending previously queued command <... command = Play ...> (Music is launched and plays)In thread 804205 you described this path as pressing "play" on an A2DP/HFP accessory "that's currently in playback mode". Questions: a) What exactly must be true for a headset AVRCP Play/Pause to be routed to the PTT system instead of the now-playing app? Is "playback mode" a state of our channel (e.g. only while setActiveRemoteParticipant is set / audio is playing), of the accessory, or of the route? b) Is an idle joined channel (no remote participant, nothing playing) expected to receive accessory events at all? c) Is a press-once start / press-once end mapping supported for accessory events, or is it press-and-hold only? d) If headset buttons cannot start a transmission from idle, is the BLE path (requestBeginTransmitting from a CoreBluetooth event) the only supported option for an earset trigger? (Our earset exposes no BLE button characteristic, so that would require firmware changes.) 2. Is this an appropriate use of PushToTalk? The audio goes from the user to our assistant service (speech-to-text, then the assistant responds in the app or by voice). There is no second human on the channel. In thread 816408 you noted the voice communication frameworks "can't be used for any other purpose". Would capturing a user's spoken requests/notes for an AI assistant through PTT be considered a supported use, or is PTT limited to person-to-person communication? If it isn't, is there any supported API that lets a user start and stop audio capture with an earset or a Lock Screen control while the device stays locked? A sysdiagnose and the test project are available on request. Thanks!
1
0
146
1w
Family Controls: what may leave the device, and does school distribution count as an organizational setting?
Hello, My colleague and I are building a digital wellbeing app for high school students aged 14–17. Students install it on their own iPhones and choose to use it. It is not a covert monitoring or parental control tool. Students set a daily social media goal and earn points for meeting it, which they can redeem for rewards offered by their school. We plan to use FamilyControls with individual authorization, and DeviceActivity. We have read the Family Controls Framework section of the Developer Program License Agreement (section 3.3.3). It says device or usage data may not be shared beyond the individual and their device, and we want to design within it. On-device storage: A DTS reply in another thread (https://developer.apple.com/forums/thread/825822) says device activity data may be used within the device activity target, as long as this doesn't involve storing or manipulating the data. May our DeviceActivityMonitor extension record in an App Group that a threshold was reached, so our main app can show the student their own progress? Derived results: With the student's explicit consent, may the app send our server only a coarse result computed on the device? For example: a. "Goal met" or "goal not met" for the day b. A daily tier, such as "under 1 hour" Does Apple consider either of these "device or usage data"? Redeeming rewards: If neither is allowed, what is the recommended way to let a student redeem a reward based on a result that stays on their device? School distribution: Schools would distribute the app. Staff would see only class-level aggregates, computed on our server from the results in question 2, such as "70% of consenting students met their goal". No individual result is visible to anyone but the student. Would this count as an "organizational setting" under the agreement? If so, which part of the design causes that? Would love some help on these questions, Barak
0
0
61
1w
Managed asset pack download fails with `PipelineNotFound` at 100 % after the app is backgrounded (iOS 27)
We ship a ~6.2 GB Apple-hosted managed asset pack and request it with AssetPackManager.ensureLocalAvailability(of:). If the app goes to the background even once while the download runs, the transfer continues to the end and then fails with ManagedBackgroundAssetsProcessingPipeline.Dispatcher.PipelineNotFound. The system discards the resume data, and the next attempt starts again from byte 0. What the sysdiagnose shows: On backgrounding, backgroundassets.user logs allows BG activity, pausing any foreground downloads for background demotion and hands the download to nsurlsessiond. On return it logs re-promoted 1 previously-demoted foreground downloads. Each handoff moves the stream to another STExtractionService.privileged instance, which logs No processing pipeline with the ID "…" was found; defaulting to an extraction memory footprint of 50 MB. When the HTTP response ends: [Relay] No endpoint was found for the key "…" (fault) → The stream couldn't be finished: No processing pipeline with the ID "…" was found → Removing the resumption info → the download fails. This happened on every app-requested download that was backgrounded at least once. One run reached 100 % in the foreground and still failed. The only download that ever completed was the system's own prefetch download, which ran entirely in the background with the app never launched. Over one afternoon about 46 GB were downloaded for a single 6.2 GB pack. Questions: Is this a known issue with the demotion/promotion of foreground asset-pack downloads? Is AssetPack.download(for: nil) plus BADownloadManager.scheduleDownload(_:) a supported way to request a managed pack from the app, so the download never gets foreground priority? We're testing it now. Is there any other way to keep a download requested from a foreground app from being demoted? Filed as FB24888599.
3
1
257
1w
How can I disable sharing age range with an app
I am still in development phase of an app, I integrated AgeRangeAPI and shared age range with my app. When I go to system settings > profile > personal information > Age Range for Apps , I see the app and it says "Shared", but I can't unshare anymore. I can unshare globally but now per app. I know the AgeRangeAPI can be tested from the Developer > Account > Manage, but that kind of testing skips the native UI I want to test again full scenario to see what real users will experience, I want to see the real UI of sharing again.
5
0
152
1w
URL parse strategy default scheme not working?
I'm trying to parse URLs that may not have a scheme specified. In that case, I want it to assume http, so I set the scheme strategy to .defaultValue("http"). However, when parsing a URL without a scheme, it fails with the following error: error: Error Domain=NSCocoaErrorDomain Code=2048 "Cannot parse example.com. String should adhere to the preferred format of the locale, such as https://user:password@www.example.com/path?color=red#name."If I prefix the URL string with "http://", it works fine. I also tried setting the default value to "http:" and "http://" with the same result. Here is the code I'm using to test this: import Foundation do { let url = try URL( "example.com", // this fails but "http://example.com" works strategy: .url .scheme(.defaultValue("http")) .port(.defaultValue(8080)) .path(.defaultValue("/")) ) print("parsed: \(url)") } catch let error { print("error: \(error)") }Is this a bug, or have I misunderstood the default value strategy? Thanks!
1
0
335
1w
DockKit: switching the Insta360 Flow 2 Pro between portrait and landscape from an app
I'm controlling an Insta360 Flow 2 Pro (firmware 5.50.80) from my own app with DockKit (iPhone 15 Pro, iOS 26.6.1). Pan and tilt work fine.   I need my app to switch the phone between portrait and landscape automatically, the way the gimbal's Switch button and the Insta360 app do. Is there a DockKit API for this? Is there also a way to read which orientation the gimbal is in?   I tried turning the roll motor myself, and it doesn't work:   // roll by speed (±45°/s), and by position (±90°, relative and absolute) try await accessory.setAngularVelocity(Vector3D(x: 0, y: 0, z: rollSpeed)) try await accessory.setOrientation(Vector3D(x: 0, y: 0, z: -.pi / 2),                                    duration: .seconds(1.5), relative: true)  Both calls return no error, but the phone doesn't turn. The same calls move pan as expected. The accessory's limits have no roll axis, and motionStates reports a roll of 0 even after the Switch button has turned the phone to landscape.   Is portrait/landscape switching supported in DockKit, and if not, is it planned?   Thanks!
0
0
63
1w
NSJSONSerialization silently drops U+FEFF from JSON string content — keys merge, characters vanish
NSJSONSerialization silently drops U+FEFF from JSON string content — keys merge, characters vanish TL;DR: NSJSONSerialization deletes U+FEFF (ZERO WIDTH NO-BREAK SPACE / BOM) from anywhere inside parsed JSON strings — not just a leading document BOM, and even when written as the \uFEFF escape (it's removed after unescaping). Distinct strings/keys silently collapse onto their U+FEFF-less twins. If you're seeing JSON keys mysteriously merge or a character disappear from a parsed value, this is probably why. It is not your code. Workaround and exhaustive scope below. The workaround Two options, depending on how attached you are to Foundation: A. Stay on NSJSONSerialization — swap U+FEFF for a private-use sentinel before parsing, restore after. You must handle both the raw bytes and the \uFEFF escape (the escape bites too, since deletion happens post-unescape): // 1. Pick a private-use scalar you've verified is absent from the source text. // 2. Replace every in-content U+FEFF (raw char AND \uFEFF escape) with it. // 3. Parse. NSJSONSerialization preserves the sentinel. // 4. Recursively restore the sentinel -> U+FEFF in the parsed tree. static id RestoreSentinel(id o, NSString *s, NSString *bom) { if ([o isKindOfClass:NSString.class]) return [o rangeOfString:s].location == NSNotFound ? o : [o stringByReplacingOccurrencesOfString:s withString:bom]; if ([o isKindOfClass:NSArray.class]) { NSMutableArray *a = [NSMutableArray arrayWithCapacity:[o count]]; for (id e in o) [a addObject:RestoreSentinel(e, s, bom)]; return a; } if ([o isKindOfClass:NSDictionary.class]) { NSMutableDictionary *d = [NSMutableDictionary dictionary]; [o enumerateKeysAndObjectsUsingBlock:^(id k, id v, BOOL *stop) { d[RestoreSentinel(k, s, bom)] = RestoreSentinel(v, s, bom); }]; return d; } return o; } Swap the escape form with a backslash-parity-aware regex so \uFEFF (escaped backslash + literal "uFEFF") is left intact: (?<!\\)((?:\\\\)*)\\u[Ff][Ee][Ff][Ff] -> $1<sentinel> B. Don't use Foundation for this file — a spec-compliant C parser like ++yyjson++ preserves U+FEFF and is faster on large files. (This is the route swift-transformers took for tokenizer.json.) Minimal repro // Object keys collapse: NSData *d1 = [@"{\"\\uFEFF#\":1,\"#\":2}" dataUsingEncoding:NSUTF8StringEncoding]; id o1 = [NSJSONSerialization JSONObjectWithData:d1 options:0 error:nil]; // EXPECTED: 2 keys ("\uFEFF#" and "#"); ACTUAL: 1 key ("#") — \uFEFF stripped, keys merged // String content lost: NSData *d2 = [@"[\"\\uFEFF\"]" dataUsingEncoding:NSUTF8StringEncoding]; id o2 = [NSJSONSerialization JSONObjectWithData:d2 options:0 error:nil]; // EXPECTED: ["\uFEFF"] (one code point); ACTUAL: [""] (empty string) Same outcome whether U+FEFF arrives as raw EF BB BF bytes or the \uFEFF escape. Why this is a bug, not a quirk Per RFC 8259 §7, a JSON string is a sequence of Unicode code points; U+FEFF is ordinary content and doesn't require escaping. Tolerating a leading document BOM is fine — deleting U+FEFF from string content is not. U+FEFF leads a double life (BOM signal vs. ZERO WIDTH NO-BREAK SPACE character); Foundation treats every occurrence as a stray BOM to scrub. Scope — exhaustive, not anecdotal I swept all 1,112,064 valid Unicode scalars (U+0000–U+10FFFF minus surrogates) through a parse round-trip, in both the \uFEFF-escape and raw-UTF-8 forms: U+FEFF is the only scalar altered. Every other scalar round-trips byte-identically — including the other zero-widths (U+200B, U+2060, U+00A0), which all survive. No Unicode normalization occurs (NFD stays decomposed, combining sequences and compatibility characters are preserved). So this is a deliberate BOM-stripping heuristic applied too broadly to string content — narrow and fixable, not general mangling. Why it's nasty in practice U+FEFF is zero-width, so the corruption is invisible — no trace in a diff or editor. Real-world hit: ML tokenizer vocabularies (e.g. Google's Gemma) legitimately contain U+FEFF-bearing tokens; loading tokenizer.json via NSJSONSerialization collapses those keys and assigns wrong token IDs, with zero visible symptom until output is subtly wrong. Filed as FB23271905 — please dupe if this has bitten you. More duplicates is what gets it triaged.
5
0
682
2w
Supported Screen Time data access for App Store users in Switzerland
Hello, We are developing an iOS app that helps people review their device use through daily carbon estimates, a garden, local history and Home Screen widgets. All processing stays on the device. We want users to grant permission without choosing each app or entering daily figures. The app has Family Controls distribution approval and the Family Controls App and Website Usage capability. However, the documentation for approvedWithDataAccess describes customer access for a device in the EU with an Apple Account set to an EU country or region. The Apple-provided development profile allows testing in other regions, so we do not treat a successful development test in Switzerland as approval for Swiss customers. Could an Apple engineer clarify the supported design for users located in Switzerland with a Swiss Apple Account? Is there a documented API, entitlement or approval route for direct app-duration access in this situation? If direct access is unavailable, can ordinary individual authorization and DeviceActivityReport show all available activity without an app-by-app picker? Under the report extension's privacy rules, can a daily result be made available to the main app's history and widgets through any supported mechanism, or must it stay inside the report? Do TestFlight installations follow the same regional conditions as App Store installations? We are looking for a design that follows the published access and privacy rules. We do not want to infer missing activity, work around regional restrictions, or treat development access as customer approval. Documentation: https://developer.apple.com/documentation/familycontrols/authorizationstatus/approvedwithdataaccess Thank you for any guidance.
0
0
85
2w
Clarification on Declared Age Range Prompt in Texas and Brazil
Hello Apple Developer Forum, We have implemented the Declared Age Range API exactly as described in Apple's documentation. Our implementation checks isEligibleForAgeFeatures before calling requestAgeRange, as recommended. We have been testing with different users located in Texas (US) and Brazil. However, for all users, isEligibleForAgeFeatures consistently returns false, so the Declared Age Range prompt is never displayed. We would appreciate some clarification on the following: Under what conditions does isEligibleForAgeFeatures return true? When is the Declared Age Range prompt expected to be shown? Besides the user's region, are there any additional eligibility requirements, such as whether the Apple ID has a verified payment method (credit/debit card), verified identity or address, account age or a phased rollout? Since all of our test users are in supported regions (Texas and Brazil), we expected at least some users to be eligible. However, all four test accounts consistently return false. Could you please clarify how Apple determines eligibility for the Declared Age Range feature and when developers should expect the prompt to appear? Thank you for your guidance.
1
1
811
2w
Screen Time reaches the iPhone Instagram limit after Mac sync while Instagram is in the background (on both devices)
Hello, I have noticed, once again, that DeviceActivityMonitors are quite frustrating to work with, since they are triggering random events when using mulitple Apple devices. For example, if Instagram is open on some random (non-foreground!) tab in Safari on the Mac, the iPhone will reach its limit quite consistently & quickly atfer setting up a new device activity threshold. It would be great if A) background usage was not counted towards screen time: FB25576930 B) there was an API for us developers to set-up device-specific deviceactivitymonitors: FB24363336 Hope that helps!
Replies
0
Boosts
0
Views
102
Activity
1w
URGENT: Muse is AUTOMATICALLY blocked by Screen Time API whenever Facebook is blocked, 100% of the time with no workaround for users or developers
PLEASE ADDRESS ASAP: Muse is #1 on the App Store and Facebook is one of the most blocked apps for Screen Time. This is affecting a vast number of people. Description: When a user blocks the Facebook app in any screen time app, iOS automatically blocks Meta's Muse app too. Every single time. There is no way for the user or the developer to prevent it, allowlist it, or even detect that it happened. Muse shows Apple's generic blocked-app "Restricted" screen instead of the screen time app's own design, so the user cannot tell who blocked it or why. This is the worst possible combination of apps: Facebook is one of the most-blocked app across screen time apps. Muse ("Muse from Meta") is currently the #1 app on the App Store. A huge and fast-growing number of users block Facebook and silently lose the world's most popular new app. Muse launched Sept 8, 2026 and adoption is still climbing -- the affected population grows every day. There is NO workaround whatsoever: Users cannot allowlist Muse: it does not appear in Settings > Screen Time > Always Allowed. Developers cannot prevent it: the Screen Time API offers no opt-out; the extra block is applied by iOS itself. Developers cannot detect it: Muse's token (listed separately in FamilyActivityPicker) corresponds to no real identity anywhere else. Developers cannot customize it: their ShieldConfiguration is never consulted -- Muse gets Apple's generic shield UI. Users cannot even block Muse on purpose: shielding Muse's own token is a silent no-op. Screen Time usage statistics are also wrong -- Muse usage is recorded as "Facebook." This Screen Time bug renders screen time apps effectively unusable if users want to block Facebook and use Muse, which is extremely common. How can we get this addressed as soon as possible? Feedback Assistant ticket: https://feedbackassistant.apple.com/feedback/25019832
Replies
9
Boosts
9
Views
690
Activity
1w
Autoupdate of macOS app via Sparkle library fails
We have a macOS app distributed outside of the Mac App Store (Developer ID distribution). It incorporates the popular Sparkle library which offers autoupdate functionality (downloading and installing new versions of the app). The autoupdate functionality worked flawlessly for many years but with recent versions of macOS it started failing. To demonstrate the problem we offer the dts-demo.tar.gz file (available for download, see the links below). That file contains the sources of DemoApp and a build_packages.sh script that builds installer packages for two versions of DemoApp. The old version is 3.0 and the new version is 4.0. Manually installing the old version (by double-clicking the .pkg file and following the instructions) succeeds. After launching the app, trying to autoupdate to the new version by clicking the "Check for update" button fails. The process starts, the old version is deinstalled but then the installation of the new version fails. Manually installing the new version of the app over the old version succeeds. The problem has been observed on macOS versions after 26.6.2 (e.g. 26.7.3 or 27.0). The files we offer for download are: dts-demo.tar.gz at https://dx4vjdxzj60n5.cloudfront.net/dts-demo.tar.gz manual_install_v3.log at https://dx4vjdxzj60n5.cloudfront.net/manual_install_v3.log autoupdate_to_v4.log at https://dx4vjdxzj60n5.cloudfront.net/autoupdate_to_v4.log manual_install_v4_over_v3.log at https://dx4vjdxzj60n5.cloudfront.net/manual_install_v4_over_v3.log The provided log files are excerpts from the system's install.log file. The Sparkle framework included in dts-demo.tar.gz comes from the official Sparkle 2.10.1 release. That version is the latest available at the time of writing. Please note that it only accepts URLs with 'http' or 'https' schemes. This autoupdate problem looks like a bug in macOS because manual updates succeed. We'd like to have the bug fixed or at least find a workaround.
Replies
3
Boosts
0
Views
80
Activity
1w
CXCallUpdate not working for outgoing calls
I try to update remoteHandle using CXCallUpdate for outgoing call, but this works only on iOS 15 but not on 17 or 18 (16 didn't test). This problem actual only for outgoing calls, but for incoming calls update works fine. func startOutgoingCall(with callID: UUID, userID: String) { let handle = CXHandle(type: .generic, value: userID) let action = CXStartCallAction(call: callID, handle: handle) callController.requestTransaction(with: action) { [weak self] error in // ... } } func updateOutgoingCall(with callID: UUID, groupID: String) { let update = CXCallUpdate() update.remoteHandle = CXHandle(type: .generic, value: groupID) provider.reportCall(with: callID, updated: update) } I also tried phoneNumber type but it seems initial handle that I set to CXStartCallAction not possible to change (value or even type). I use this handle value to implement recall by tap on call in Recents tab of system address book. But since my calls can transform from p2p to group call, I need to update handle value or find some another way to pass call identification info.
Replies
5
Boosts
1
Views
1.4k
Activity
1w
Can an iOS app share Screen Time goal progress with friends?
I'm developing an app that helps users reduce social media usage through friendly competitions. With explicit permission, the app would track daily and weekly usage of selected apps like Instagram, TikTok, and YouTube. Users could voluntarily share their live total usage, percentage improvement, or goal-completion status with approved friends. Does Apple's Family Controls policy permit this? If not, is there an approved way to implement a friends leaderboard using Screen Time data? Thank you!
Replies
0
Boosts
0
Views
52
Activity
1w
Declared Age Range in sandbox: no sheet at launch, and the set per scenario
We are testing the Declared Age Range API with sandbox testers on an iPhone 17e with iOS 26.6.2 (Xcode 26.6, iOS 26.5 SDK). The app is not yet released; everything here is pre-release testing. We have filed three focused reports: FB25530441 (requestAgeRange returned .declinedSharing with no sheet), FB25530501 (the age that Age Assurance first shows at a sign-in against what the API reads), and FB25530513 (a selected scenario not reflected in requiredRegulatoryFeatures). Four questions remain that are not defects: When a sandbox tester has an Age Assurance scenario selected, should requestAgeRange present the sheet at launch, or answer from the scenario without showing one? Is there a way to see the sheet at launch in sandbox, as a first-time user would, so we can test the share and decline paths end to end? The article "Requesting people's age range information in your app" says the set's values "tell you which actions you need to take for compliance", and the sandbox page lists each scenario's age range, but we found neither saying which members each scenario produces. Please confirm: for each Age Assurance scenario, and for a tester with no scenario selected, what should requiredRegulatoryFeatures contain? Does the tester's App Store territory or creation date matter in sandbox? On 1 and 2. Our app calls requestAgeRange at launch when requiredRegulatoryFeatures contains .declaredAgeRangeRequired. On four days between October 31 and November 7, 2026, at every launch where we know it did make the request, Apple's age range sheet did not appear. Some requests we made by hand from a debug console returned the scenario's range with no sheet: on November 7, one on each of two testers on '13 - 15' returned a shared range of 13 to 15. One such request on October 31 did present the sheet; it is the only sheet on record across the four days (at a few launches the sheet was not written down separately). On 3. What we read on one tester, in this order, each scenario read before and after a relaunch unless noted: No scenario selected (signed in for the first time; Age Assurance showed no option selected), read after a relaunch only: none of the three members. '13 - 15, significant change approved', then '16 - 17, significant change declined', then 'Under 13, significant change approved': .declaredAgeRangeRequired and .significantAppChangeRequiresParentalConsent. '18+, age confirmed, significant change not applicable': .declaredAgeRangeRequired only. '18+, age confirmed, significant change applicable': .declaredAgeRangeRequired and .significantAppChangeRequiresAdultNotification. '18+, age not confirmed, significant change not applicable': .declaredAgeRangeRequired only. For these rows we read contains for the three members the iOS 26.5 SDK defines, so a member outside those three would not show. On November 5 we printed the whole set on 15 reads of sandbox testers, and no other member appeared.
Replies
0
Boosts
0
Views
75
Activity
1w
PDF Widget Annotations Disappear After Saving in PDFKit (including with Preview)
The Problem When a user toggles radio buttons or checkboxes in a PDF using Preview, the widgets disappear following subsequent interactions after the file is saved and reopened. This renders the form fields unusable. Steps to Reproduce the Problem Open a PDF with radio buttons or checkboxes in Preview. Toggle a radio button or checkbox. Save and close the file. Re-open the PDF in Preview. Toggle the same button again. The button (and any others with the same field name) will disappear. Expected Results Toggling a radio button or checkbox should update the field value without causing the button (or related buttons) to disappear. This behavior is consistent with previous versions of PDFKit. What is Happening In Preview, interacting with radio buttons and checkboxes correctly updates their appearance as expected. Saving the PDF, however, causes the appearance dictionary to reference a new N entry that is a single appearance stream unassociated with any state. The annotation's AS entry is not updated. The original N entry remains but is no longer referenced. Subsequent interactions fail to update the visual presentation because the appearance stream is missing. Impact on User Experience Radio buttons and checkboxes may disappear and become unusable when toggled. PDF documents become irreparably altered after a button is toggled and the file is saved. PDF file size significantly increases when the file is saved. Users may believe they have successfully completed a form, only for the data to become inaccessible or invisible to recipients. Forms may need to be completely restarted or recreated from scratch if the original becomes unusable. The corrupted PDF structure might cause the file to render incorrectly or crash in third-party PDF viewers. Affected Apps/OSs Tested with Preview 11.0 (1147), as well as other apps that use PDFKit, on macOS Golden Gate 27.0 (26A428). This problem also affects PDFKit on iOS 27.0 and iPadOS 27.0. Feedback/bug report: FB24866826 Related Sample Output Original PDF File Checkbox widget annotation (6 0 obj), its appearance dictionary (17 0 obj), and normal appearance dictionary (18 0 obj). Button is not checked. 6 0 obj << /Border [ 0 0 0 ] /Rect [ 90 390 110 410 ] /T (button1) /F 4 /Subtype /Widget /DA (/.AppleSystemUIFont 13 Tf 0 g) /MK 16 0 R /C [ 0 ] /AP 17 0 R /V /Off /M (D:20260919225320Z00'00') /AS /Off /FT /Btn /Type /Annot /Ff 0 >> endobj 17 0 obj << /N 18 0 R >> endobj 18 0 obj << /Yes 20 0 R /Off 22 0 R >> endobj PDF File after Save Checkbox widget annotation object (6 0 obj), its new appearance dictionary object (8 0 obj), a new normal appearance stream object (20 0 obj), and the original appearance stream dictionary (now 21 0 obj). File saved after user checked button. 6 0 obj << /Ff 0 /Type /Annot /AS /Off /AP 8 0 R /MK 9 0 R /C [ 0 ] /FT /Btn /M (D:20260919225320Z00'00') /DA (/.AppleSystemUIFont 13 Tf 0 g) /Subtype /Widget /F 4 /Border [ 0 0 0 ] /Rect [ 90 390 110 410 ] /T (button1) /V (Yes) >> endobj 8 0 obj << /N 20 0 R >> endobj 20 0 obj << /Filter /FlateDecode /Resources << /ColorSpace << /CS1 [ /ICCBased 29 0 R ] /CS2 [ /ICCBased 30 0 R ] >> >> /BBox [ 0 0 20 20 ] /Type /XObject /Subtype /Form /Length 123 >> stream x UéA ¬0 Ô}≈|†≈nà¢úÛÇ* —SA =}Ïr(»ñµ≤w◊€YËà’|ÙÎŒç'óRï∂#SäÏÌü∞¢S‰Ì§ôRÌX }–É•åY Éçˆ BŒ H " *â´8™ˆZø6z⁄ÿ ”ú6ɀ੠"∫t˘‹;'¬ endstream endobj 21 0 obj << /Off 22 0 R /Yes 23 0 R >> endobj Note: No object references 21 0 obj in the PDF.
Replies
5
Boosts
0
Views
1.1k
Activity
1w
PDF Widget Annotations appear Pixelated/Rasterized
The Problem On opening a PDF document in the Preview app, PDF widget annotations appear pixelated/rasterized. This problem exists with button, text, and choice widget subtypes. The pixelation becomes more apparent when zoomed in. Expected Results PDF widgets should appear sharp and smooth, without pixelation. In previous versions of the Preview app, widgets appear vector-based as expected. Impact on User Experience PDF widgets appear pixelated and inconsistent with text content in the same PDF document. Widgets do not look like elements of an interactive form but, instead, resemble low-quality embedded images. Affected Apps/OSs: Preview 11.0 (1147), as well as other apps that use PDFKit, on macOS Golden Gate 27.0 (26A428). A similar problem appears to affect PDFKit on iOS 27.0 and iPadOS 27.0 as well. Feedback/bug report: FB24843022
Replies
8
Boosts
3
Views
1.7k
Activity
1w
Declared Age Range: fallback behavior, cached results, and older iOS versions
Hello, I am preparing an 18+ workout logging app for iOS and would like to clarify the supported behavior of the Declared Age Range framework before completing its integration. Workout records, body measurements and saved videos are stored locally. Outside additional regulatory requirements, the planned entry flow uses a neutral adult self-declaration without collecting a date of birth or identity documents. The intended storefronts are Japan, the United States, the United Kingdom, Canada, Australia, New Zealand, Ireland and Singapore. These are implementation-design questions, not errors reproduced in a completed DAR integration. I am seeking documented API/platform behavior, not legal approval. Applicability checks that fail If isEligibleForAgeFeatures throws, returns notAvailable, or does not complete, is there a supported fallback signal or recommended retry strategy? I would not interpret an error as a successful “outside regulated scope” result. Is there a documented platform requirement for app access while applicability remains unresolved, separate from developers’ obligations under applicable law? Previously returned adult age ranges If declaredAgeRangeRequired applies and requestAgeRange fails after an earlier adult response, does Apple support relying on an app-stored result? I understand that the system caches responses; my question concerns a result stored separately by the app. Is there a supported way to detect when that result must be invalidated because of an Apple Account change, changes to age information, or sharing/consent changes? If no such signal exists, what implementation pattern does Apple recommend? I would not assume that a previous result always belongs to the current person or invent a cache lifetime. Earlier OS versions For affected newly created Apple Accounts in regulated regions, what supported path applies on: iOS versions without Declared Age Range; iOS 26.0–26.1, without isEligibleForAgeFeatures; iOS 26.2–26.3, without requiredRegulatoryFeatures? The age-assurance Q&A discusses existing Apple Accounts on iOS 18 or earlier. Is there additional documentation covering newly created affected accounts on earlier OS versions? While checks remain unresolved, the proposed design withholds advertising and new purchases and preserves existing data with free export. This is a proposed design, not an assumption that local recording is exempt from any requirement. References reviewed: https://developer.apple.com/support/age-assurance/ https://developer.apple.com/documentation/declaredagerange/requesting-people-share-their-age-range-with-your-app Pointers to relevant documentation or sample code would be appreciated. Thank you.
Replies
0
Boosts
0
Views
42
Activity
1w
PushToTalk: headset "play" never starts a transmission (goes to Music) — and is PTT appropriate for voice capture to an assistant?
Hi, We're building a voice assistant app. The user speaks to the assistant through a Bluetooth earset; the app records the speech, transcribes it and the assistant acts on it. We want the user to start and stop that capture from the earset button while the iPhone stays locked, without the Phone call UI. We prototyped this with the PushToTalk framework and have two questions. 1. Headset play button does not reach our joined PTT channel Setup (minimal test app, nothing else running): iPhone 14 Pro Max, iOS 26.6.1 (23G83). Entitlements: com.apple.developer.push-to-talk, aps-environment. Background modes: push-to-talk, audio, bluetooth-central. PTChannelManager.channelManager(delegate:restorationDelegate:) → requestJoinChannel in the foreground → didJoinChannel → setAccessoryButtonEventsEnabled(true, channelUUID:) completes without error. Audio session configured once before joining: .playAndRecord, options .allowBluetoothHFP; tried mode .default and .voiceChat. We never call setActive; audio starts only in didActivate (AVAudioEngine). What works: The system PTT UI talk button, phone locked: didBeginTransmitting → didActivate (earset HFP 16 kHz) → audio recorded. A Lock Screen / Control Center control running an intent that adopts PushToTalkTransmissionIntent, phone locked: one tap starts, one tap ends; 5+ minute transmissions; app cold-launched by the system when needed. What doesn't: pressing the earset's play/pause button (single press) while joined and idle never produces didBeginTransmitting. Same result with AirPods and with a third-party A2DP/HFP earset, locked and unlocked, Music app closed or not. mediaremoted logs, for every press: mediaremoted: Received command from client <... bundleIdentifier = com.apple.BTAvrcp ...>: <... command = Play ...> mediaremoted: No context for context-sensitive command <... command = Play, SenderBundleIdentifier = <com.apple.BTAvrcp> ...> mediaremoted: Destination app com.apple.Music not available for command <... command = Play ...> mediaremoted: Sending previously queued command <... command = Play ...> (Music is launched and plays)In thread 804205 you described this path as pressing "play" on an A2DP/HFP accessory "that's currently in playback mode". Questions: a) What exactly must be true for a headset AVRCP Play/Pause to be routed to the PTT system instead of the now-playing app? Is "playback mode" a state of our channel (e.g. only while setActiveRemoteParticipant is set / audio is playing), of the accessory, or of the route? b) Is an idle joined channel (no remote participant, nothing playing) expected to receive accessory events at all? c) Is a press-once start / press-once end mapping supported for accessory events, or is it press-and-hold only? d) If headset buttons cannot start a transmission from idle, is the BLE path (requestBeginTransmitting from a CoreBluetooth event) the only supported option for an earset trigger? (Our earset exposes no BLE button characteristic, so that would require firmware changes.) 2. Is this an appropriate use of PushToTalk? The audio goes from the user to our assistant service (speech-to-text, then the assistant responds in the app or by voice). There is no second human on the channel. In thread 816408 you noted the voice communication frameworks "can't be used for any other purpose". Would capturing a user's spoken requests/notes for an AI assistant through PTT be considered a supported use, or is PTT limited to person-to-person communication? If it isn't, is there any supported API that lets a user start and stop audio capture with an earset or a Lock Screen control while the device stays locked? A sysdiagnose and the test project are available on request. Thanks!
Replies
1
Boosts
0
Views
146
Activity
1w
Family Controls: what may leave the device, and does school distribution count as an organizational setting?
Hello, My colleague and I are building a digital wellbeing app for high school students aged 14–17. Students install it on their own iPhones and choose to use it. It is not a covert monitoring or parental control tool. Students set a daily social media goal and earn points for meeting it, which they can redeem for rewards offered by their school. We plan to use FamilyControls with individual authorization, and DeviceActivity. We have read the Family Controls Framework section of the Developer Program License Agreement (section 3.3.3). It says device or usage data may not be shared beyond the individual and their device, and we want to design within it. On-device storage: A DTS reply in another thread (https://developer.apple.com/forums/thread/825822) says device activity data may be used within the device activity target, as long as this doesn't involve storing or manipulating the data. May our DeviceActivityMonitor extension record in an App Group that a threshold was reached, so our main app can show the student their own progress? Derived results: With the student's explicit consent, may the app send our server only a coarse result computed on the device? For example: a. "Goal met" or "goal not met" for the day b. A daily tier, such as "under 1 hour" Does Apple consider either of these "device or usage data"? Redeeming rewards: If neither is allowed, what is the recommended way to let a student redeem a reward based on a result that stays on their device? School distribution: Schools would distribute the app. Staff would see only class-level aggregates, computed on our server from the results in question 2, such as "70% of consenting students met their goal". No individual result is visible to anyone but the student. Would this count as an "organizational setting" under the agreement? If so, which part of the design causes that? Would love some help on these questions, Barak
Replies
0
Boosts
0
Views
61
Activity
1w
Managed asset pack download fails with `PipelineNotFound` at 100 % after the app is backgrounded (iOS 27)
We ship a ~6.2 GB Apple-hosted managed asset pack and request it with AssetPackManager.ensureLocalAvailability(of:). If the app goes to the background even once while the download runs, the transfer continues to the end and then fails with ManagedBackgroundAssetsProcessingPipeline.Dispatcher.PipelineNotFound. The system discards the resume data, and the next attempt starts again from byte 0. What the sysdiagnose shows: On backgrounding, backgroundassets.user logs allows BG activity, pausing any foreground downloads for background demotion and hands the download to nsurlsessiond. On return it logs re-promoted 1 previously-demoted foreground downloads. Each handoff moves the stream to another STExtractionService.privileged instance, which logs No processing pipeline with the ID "…" was found; defaulting to an extraction memory footprint of 50 MB. When the HTTP response ends: [Relay] No endpoint was found for the key "…" (fault) → The stream couldn't be finished: No processing pipeline with the ID "…" was found → Removing the resumption info → the download fails. This happened on every app-requested download that was backgrounded at least once. One run reached 100 % in the foreground and still failed. The only download that ever completed was the system's own prefetch download, which ran entirely in the background with the app never launched. Over one afternoon about 46 GB were downloaded for a single 6.2 GB pack. Questions: Is this a known issue with the demotion/promotion of foreground asset-pack downloads? Is AssetPack.download(for: nil) plus BADownloadManager.scheduleDownload(_:) a supported way to request a managed pack from the app, so the download never gets foreground priority? We're testing it now. Is there any other way to keep a download requested from a foreground app from being demoted? Filed as FB24888599.
Replies
3
Boosts
1
Views
257
Activity
1w
How can I disable sharing age range with an app
I am still in development phase of an app, I integrated AgeRangeAPI and shared age range with my app. When I go to system settings > profile > personal information > Age Range for Apps , I see the app and it says "Shared", but I can't unshare anymore. I can unshare globally but now per app. I know the AgeRangeAPI can be tested from the Developer > Account > Manage, but that kind of testing skips the native UI I want to test again full scenario to see what real users will experience, I want to see the real UI of sharing again.
Replies
5
Boosts
0
Views
152
Activity
1w
URL parse strategy default scheme not working?
I'm trying to parse URLs that may not have a scheme specified. In that case, I want it to assume http, so I set the scheme strategy to .defaultValue("http"). However, when parsing a URL without a scheme, it fails with the following error: error: Error Domain=NSCocoaErrorDomain Code=2048 "Cannot parse example.com. String should adhere to the preferred format of the locale, such as https://user:password@www.example.com/path?color=red#name."If I prefix the URL string with "http://", it works fine. I also tried setting the default value to "http:" and "http://" with the same result. Here is the code I'm using to test this: import Foundation do { let url = try URL( "example.com", // this fails but "http://example.com" works strategy: .url .scheme(.defaultValue("http")) .port(.defaultValue(8080)) .path(.defaultValue("/")) ) print("parsed: \(url)") } catch let error { print("error: \(error)") }Is this a bug, or have I misunderstood the default value strategy? Thanks!
Replies
1
Boosts
0
Views
335
Activity
1w
DockKit: switching the Insta360 Flow 2 Pro between portrait and landscape from an app
I'm controlling an Insta360 Flow 2 Pro (firmware 5.50.80) from my own app with DockKit (iPhone 15 Pro, iOS 26.6.1). Pan and tilt work fine.   I need my app to switch the phone between portrait and landscape automatically, the way the gimbal's Switch button and the Insta360 app do. Is there a DockKit API for this? Is there also a way to read which orientation the gimbal is in?   I tried turning the roll motor myself, and it doesn't work:   // roll by speed (±45°/s), and by position (±90°, relative and absolute) try await accessory.setAngularVelocity(Vector3D(x: 0, y: 0, z: rollSpeed)) try await accessory.setOrientation(Vector3D(x: 0, y: 0, z: -.pi / 2),                                    duration: .seconds(1.5), relative: true)  Both calls return no error, but the phone doesn't turn. The same calls move pan as expected. The accessory's limits have no roll axis, and motionStates reports a roll of 0 even after the Switch button has turned the phone to landscape.   Is portrait/landscape switching supported in DockKit, and if not, is it planned?   Thanks!
Replies
0
Boosts
0
Views
63
Activity
1w
NSJSONSerialization silently drops U+FEFF from JSON string content — keys merge, characters vanish
NSJSONSerialization silently drops U+FEFF from JSON string content — keys merge, characters vanish TL;DR: NSJSONSerialization deletes U+FEFF (ZERO WIDTH NO-BREAK SPACE / BOM) from anywhere inside parsed JSON strings — not just a leading document BOM, and even when written as the \uFEFF escape (it's removed after unescaping). Distinct strings/keys silently collapse onto their U+FEFF-less twins. If you're seeing JSON keys mysteriously merge or a character disappear from a parsed value, this is probably why. It is not your code. Workaround and exhaustive scope below. The workaround Two options, depending on how attached you are to Foundation: A. Stay on NSJSONSerialization — swap U+FEFF for a private-use sentinel before parsing, restore after. You must handle both the raw bytes and the \uFEFF escape (the escape bites too, since deletion happens post-unescape): // 1. Pick a private-use scalar you've verified is absent from the source text. // 2. Replace every in-content U+FEFF (raw char AND \uFEFF escape) with it. // 3. Parse. NSJSONSerialization preserves the sentinel. // 4. Recursively restore the sentinel -> U+FEFF in the parsed tree. static id RestoreSentinel(id o, NSString *s, NSString *bom) { if ([o isKindOfClass:NSString.class]) return [o rangeOfString:s].location == NSNotFound ? o : [o stringByReplacingOccurrencesOfString:s withString:bom]; if ([o isKindOfClass:NSArray.class]) { NSMutableArray *a = [NSMutableArray arrayWithCapacity:[o count]]; for (id e in o) [a addObject:RestoreSentinel(e, s, bom)]; return a; } if ([o isKindOfClass:NSDictionary.class]) { NSMutableDictionary *d = [NSMutableDictionary dictionary]; [o enumerateKeysAndObjectsUsingBlock:^(id k, id v, BOOL *stop) { d[RestoreSentinel(k, s, bom)] = RestoreSentinel(v, s, bom); }]; return d; } return o; } Swap the escape form with a backslash-parity-aware regex so \uFEFF (escaped backslash + literal "uFEFF") is left intact: (?<!\\)((?:\\\\)*)\\u[Ff][Ee][Ff][Ff] -> $1<sentinel> B. Don't use Foundation for this file — a spec-compliant C parser like ++yyjson++ preserves U+FEFF and is faster on large files. (This is the route swift-transformers took for tokenizer.json.) Minimal repro // Object keys collapse: NSData *d1 = [@"{\"\\uFEFF#\":1,\"#\":2}" dataUsingEncoding:NSUTF8StringEncoding]; id o1 = [NSJSONSerialization JSONObjectWithData:d1 options:0 error:nil]; // EXPECTED: 2 keys ("\uFEFF#" and "#"); ACTUAL: 1 key ("#") — \uFEFF stripped, keys merged // String content lost: NSData *d2 = [@"[\"\\uFEFF\"]" dataUsingEncoding:NSUTF8StringEncoding]; id o2 = [NSJSONSerialization JSONObjectWithData:d2 options:0 error:nil]; // EXPECTED: ["\uFEFF"] (one code point); ACTUAL: [""] (empty string) Same outcome whether U+FEFF arrives as raw EF BB BF bytes or the \uFEFF escape. Why this is a bug, not a quirk Per RFC 8259 §7, a JSON string is a sequence of Unicode code points; U+FEFF is ordinary content and doesn't require escaping. Tolerating a leading document BOM is fine — deleting U+FEFF from string content is not. U+FEFF leads a double life (BOM signal vs. ZERO WIDTH NO-BREAK SPACE character); Foundation treats every occurrence as a stray BOM to scrub. Scope — exhaustive, not anecdotal I swept all 1,112,064 valid Unicode scalars (U+0000–U+10FFFF minus surrogates) through a parse round-trip, in both the \uFEFF-escape and raw-UTF-8 forms: U+FEFF is the only scalar altered. Every other scalar round-trips byte-identically — including the other zero-widths (U+200B, U+2060, U+00A0), which all survive. No Unicode normalization occurs (NFD stays decomposed, combining sequences and compatibility characters are preserved). So this is a deliberate BOM-stripping heuristic applied too broadly to string content — narrow and fixable, not general mangling. Why it's nasty in practice U+FEFF is zero-width, so the corruption is invisible — no trace in a diff or editor. Real-world hit: ML tokenizer vocabularies (e.g. Google's Gemma) legitimately contain U+FEFF-bearing tokens; loading tokenizer.json via NSJSONSerialization collapses those keys and assigns wrong token IDs, with zero visible symptom until output is subtly wrong. Filed as FB23271905 — please dupe if this has bitten you. More duplicates is what gets it triaged.
Replies
5
Boosts
0
Views
682
Activity
2w
Supported Screen Time data access for App Store users in Switzerland
Hello, We are developing an iOS app that helps people review their device use through daily carbon estimates, a garden, local history and Home Screen widgets. All processing stays on the device. We want users to grant permission without choosing each app or entering daily figures. The app has Family Controls distribution approval and the Family Controls App and Website Usage capability. However, the documentation for approvedWithDataAccess describes customer access for a device in the EU with an Apple Account set to an EU country or region. The Apple-provided development profile allows testing in other regions, so we do not treat a successful development test in Switzerland as approval for Swiss customers. Could an Apple engineer clarify the supported design for users located in Switzerland with a Swiss Apple Account? Is there a documented API, entitlement or approval route for direct app-duration access in this situation? If direct access is unavailable, can ordinary individual authorization and DeviceActivityReport show all available activity without an app-by-app picker? Under the report extension's privacy rules, can a daily result be made available to the main app's history and widgets through any supported mechanism, or must it stay inside the report? Do TestFlight installations follow the same regional conditions as App Store installations? We are looking for a design that follows the published access and privacy rules. We do not want to infer missing activity, work around regional restrictions, or treat development access as customer approval. Documentation: https://developer.apple.com/documentation/familycontrols/authorizationstatus/approvedwithdataaccess Thank you for any guidance.
Replies
0
Boosts
0
Views
85
Activity
2w
Clarification on Declared Age Range Prompt in Texas and Brazil
Hello Apple Developer Forum, We have implemented the Declared Age Range API exactly as described in Apple's documentation. Our implementation checks isEligibleForAgeFeatures before calling requestAgeRange, as recommended. We have been testing with different users located in Texas (US) and Brazil. However, for all users, isEligibleForAgeFeatures consistently returns false, so the Declared Age Range prompt is never displayed. We would appreciate some clarification on the following: Under what conditions does isEligibleForAgeFeatures return true? When is the Declared Age Range prompt expected to be shown? Besides the user's region, are there any additional eligibility requirements, such as whether the Apple ID has a verified payment method (credit/debit card), verified identity or address, account age or a phased rollout? Since all of our test users are in supported regions (Texas and Brazil), we expected at least some users to be eligible. However, all four test accounts consistently return false. Could you please clarify how Apple determines eligibility for the Declared Age Range feature and when developers should expect the prompt to appear? Thank you for your guidance.
Replies
1
Boosts
1
Views
811
Activity
2w