Posts under App & System Services topic

Post

Replies

Boosts

Views

Activity

iOS Background Location / Geofencing for Automatic Attendance — App Not Triggering Reliably
iOS Background Location / Geofencing for Automatic Attendance — App Not Triggering Reliably We are developing an enterprise attendance application called Attendo, which uses location-based geofencing for automatic employee check-in/check-out. Business requirement The application needs to work as follows: An employee is assigned an office/work location with a defined radius. When the employee enters the configured radius, the application should automatically record a Check-In. When the employee leaves the radius, the application should automatically record a Check-Out. This should happen without the employee having to open the application. The functionality needs to work even when the application is in the background and, where supported by iOS, after the application has been terminated. For example: «Office geofence = 200 meters Employee enters the 200 m radius → automatic Check-In Employee leaves the 200 m radius → automatic Check-Out» Current iOS implementation We are using iOS location services with: Location permission: Always Precise Location: enabled Background Location capability enabled Background location updates enabled Geofencing / region monitoring The application is intended to respond to location/geofence events without requiring the user to open the app. However, we are seeing cases where the application does not reliably receive/process the required location/geofence event when the application has been in the background for an extended period. The same business workflow works more reliably while the application is active. Our concern Our understanding is that iOS does not allow an application to maintain a continuously running background service in the same way that Android can. However, our requirement does not necessarily require continuous GPS polling if there is an Apple-supported mechanism that can reliably wake/relaunch the application when a user crosses a geofence. We would therefore like to understand the recommended architecture for this use case. Questions Is Core Location Region Monitoring the recommended mechanism for an enterprise geofencing application that needs to detect entry/exit while the app is not running? Can iOS relaunch the application after it has been terminated by the user/system when a monitored region is entered or exited? Is there any supported way to guarantee that an application will continue receiving location/geofence events after it has been in the background for a long period? Does enabling: "UIBackgroundModes = location" "allowsBackgroundLocationUpdates" "CLLocationManager" Region Monitoring provide the expected behavior, or are there additional requirements/configurations we should consider? Are there known limitations regarding: Low Power Mode device movement speed GPS/location accuracy stationary devices iOS terminating/suspending the application force-quitting the application from the App Switcher large/small geofence radius multiple monitored regions Is it possible to use significant-change location updates + region monitoring together for this type of attendance workflow? For an enterprise application where the user explicitly grants Always Allow Location permission and Precise Location is enabled, what level of reliability can realistically be expected from iOS geofencing? Important business constraint We cannot require employees to manually open the application every time they arrive at or leave the workplace. The objective is an automatic attendance system, where the employee's entry and exit from the workplace geofence is detected by iOS and the application records the corresponding attendance event. We understand that iOS is designed to protect battery life and user privacy and that continuous background execution may not be permitted. We are therefore looking for the Apple-recommended architecture for achieving this requirement using supported iOS APIs, rather than trying to circumvent iOS background execution policies. Any guidance from Apple engineers or developers who have implemented reliable enterprise geofencing would be greatly appreciated.
0
0
249
3d
AlarmKit: supported approach for a server-triggered wake-up alarm after an air-raid all-clear
Dear Apple Developer Support, I am developing HushRise, an iPhone alarm application intended to help people in Ukraine manage sleep disrupted by wartime air-raid alerts. Nighttime alerts can force people to interrupt their sleep and seek shelter, sometimes repeatedly. Families must then plan work, school, and other responsibilities around these disruptions. Educational institutions and other services may suspend in-person activities during alerts, making a fixed wake-up time less useful than a wake-up signal that takes the current alert status into account. The purpose of HushRise is to support rest and daily routines under these conditions. It is not an official emergency-warning service and must not replace civil-defence alerts or encourage people to ignore them. The intended behavior is: A user sets a wake-up time and selects their region. At that time, the alarm starts only after a fresh server response confirms that no air-raid alert is active. If an alert is active, the application waits for the reported all-clear. Multiple alarms postponed during the same alert should produce one wake-up signal after the all-clear. A snoozed alarm must also obtain fresh confirmation before starting again. An alarm that has already started may continue until the user stops or snoozes it. We have tested a native AlarmKit integration on a physical iPhone. The system alarm, Lock Screen controls, Apple Watch presentation, and Stop action work. However, without ongoing background audio, iOS suspends our application’s status checks. In one test, an alarm due at 20:09 was not scheduled until the application returned to the foreground at 20:11. Audible background playback helped in experiments, but requiring continuous sound is not appropriate for the intended quiet sleep experience. Could your technical team please advise: What supported architecture should we use for an AlarmKit alarm whose trigger depends on a server event occurring at an unknown time? Can a server notification initiate the necessary validation and alarm scheduling while the iPhone is locked, and what execution guarantees or limitations apply? Is there an entitlement or approval process appropriate to this use case? Would Critical Alerts be applicable, or would another mechanism be more suitable? Which capabilities require Apple Developer Program membership? Our current prototype is installed through a free Personal Team. We understand that an offline device cannot receive new server information and that notification delivery may be delayed. We want to communicate these limitations honestly and build within Apple’s supported APIs. We can provide a minimal reproducible project, sanitized device logs, and a description of our physical-device tests. Thank you for helping us identify a reliable and appropriate approach for people whose sleep and daily lives are affected by the war in Ukraine. Kind regards, HushRise developer
2
0
383
3d
Location Services stopped working across the system on macOS
MacBook Air (M4) Current build: macOS 27 Developer Beta (26A5368g) I have a system-wide Location Services failure affecting Apple Maps, Safari geolocation APIs, and any application requesting the current location. Symptoms: Apple Maps cannot determine current location. Safari and browser geolocation APIs fail. Websites report that location cannot be found. Location Services are enabled and permissions are granted. The issue has persisted across: macOS 26.5 beta macOS 26.6 beta macOS 26.6 beta 2 macOS 27 Developer Beta Troubleshooting already performed: Multiple Wi-Fi networks tested. iPhone hotspot tested. VPN enabled and disabled. Location Services reset. Permissions reset and reauthorized. New clean local user account created (no Apple ID, no third-party software). Issue reproduces identically in the clean account. Technical observations: locationd logs repeatedly show: knownCount = 0 AlsWifi = unknown while Wi-Fi scanning itself appears successful: queryMacAddresses.size = 57 The system sees dozens of nearby access points, but none appear to be recognized for Wi-Fi positioning. Additional findings: Wi-Fi hardware functions normally. Internet connectivity is normal. Bluetooth and Find My device presence work. GeoServices resources are present on disk. No successful location fix is ever produced. Has anyone seen similar CoreLocation / GeoServices behavior where Wi-Fi scans succeed but knownCount always remains 0 and no location fix is generated?
5
2
1.6k
3d
Unable to invalidate interval: no data source available error when fetching steps using HKStatisticsCollectionQuery
While attempting to read a user’s daily step history spanning backward to the last 7 days, a small but consistent subset of users encounter Error Code 3 with the underlying error description: Error Code 3 "Unable to invalidate interval: no data source available." When this error occurs, we are entirely unable to read their step history. We have received ~10 direct user reports of this within the last couple of weeks.
15
2
2.1k
4d
Open parent app from ShieldAction extension in iOS
When I tap on one of the buttons in the ShieldAction extension I want to close the shield and open the parent app instead of the shielded app. Is there any way of doing this using the Screen Time API? class ShieldActionExtension: ShieldActionDelegate {      override func handle(action: ShieldAction, for application: ApplicationToken, completionHandler: @escaping (ShieldActionResponse) -> Void) {     // Handle the action as needed.           let store = ManagedSettingsStore()               switch action {     case .primaryButtonPressed:       //TODO - open parent app       completionHandler(.defer)     case .secondaryButtonPressed:       //remove shield       store.shield.applications?.remove(application)       completionHandler(.defer)         @unknown default:       fatalError()     }   }   }
15
9
7.1k
4d
macOS 26.7: opening Control Center Sound causes BLE HID mouse lag, HID service loss, and result 307
I am seeing a repeatable interaction between audio activity or audio-device discovery and a Bluetooth LE HID mouse on a Mac mini M2 Pro. Opening the detailed Sound panel in Control Center, or changing the HDMI audio output, makes the pointer stutter. Opening Apple’s Music.app has also caused a temporary complete loss of the mouse. In the worst cases, the mouse becomes completely unavailable and does not recover without Bluetooth troubleshooting or re-pairing. Configuration Mac mini Mac14,12, Apple M2 Pro, 32 GB RAM macOS Tahoe 26.7 (25G229) Also reproduced on macOS Tahoe 26.1 (25B78) Logitech MX Anywhere 3 Mac over Bluetooth LE VID 0x046D, PID 0xB025 Firmware MPM24.01_0015 Logitech MX Keys M Mac over Bluetooth LE PL4071UH display and audio output over HDMI Logi Options+ installed Trigger Connect the MX Anywhere 3 Mac and MX Keys over Bluetooth. Open Control Center from the menu bar. Open the detailed Sound panel, or change the HDMI audio output. Move the Bluetooth mouse continuously while audio-output discovery is taking place. The issue is intermittent, but it has been reproduced several times on both macOS 26.1 and 26.7. Pointer stuttering can continue after the Sound panel is closed. A later incident occurred when I opened Apple’s Music.app. The Bluetooth mouse became unavailable again, but this time it recovered automatically after approximately ten seconds. The Sony WH-1000XM6 headset was connected over Bluetooth, while the 512 GB USB flash drive was not connected. This shows that the USB drive is not required for a temporary mouse loss and makes concurrent Bluetooth audio activity a more relevant condition to investigate. The additional trigger suggests that the problem may not be limited to the Control Center interface itself and may also be associated with audio-subsystem initialization or audio-device activity. This is an observation, not yet a confirmed causal link. Additional condition in the permanent-loss cases In every incident where the mouse did not recover on its own and became effectively unusable, the following two devices were also present: a Sony WH-1000XM6 wireless headset connected over Bluetooth; a 512 GB SanDisk USB flash drive connected to the Mac. I am reporting this as a correlation, not as a confirmed cause. The headset adds simultaneous Bluetooth audio activity. The USB drive may or may not be relevant depending on its USB mode, activity, shielding, physical location, and possible 2.4 GHz interference. The 512 GB capacity is included only to identify the device. Less severe cursor stuttering has also been observed around Sound-panel discovery; the two devices above are specifically the common condition I recorded during the permanent mouse-loss incidents. Observed result The pointer starts stuttering and raw mouse HID reports develop multi-second gaps. In severe incidents, the Bluetooth mouse stops working entirely. Opening Music.app has also caused a temporary complete loss of the mouse; during that incident the Sony WH-1000XM6 was connected over Bluetooth, the USB flash drive was not connected, and the mouse recovered automatically after approximately ten seconds. Logi Options+ then displays the mouse as inactive. The mouse disappears from the IOHID tree, while the Bluetooth keyboard can remain present. A wired USB mouse remains responsive, so the Mac and pointer rendering are not completely frozen. The failure can persist after the Sound panel is closed. Relevant logs On macOS 26.7, bluetoothd repeatedly recorded the following sequence for the MX Anywhere 3 Mac: MX Anywhere 3 Mac needs low latency current connection parameters: interval 30.00 ms, latency 0 connection changed to: interval 7.50 ms, latency 44 Device "MX Anywhere 3 Mac" is Incompatible LE HID Device "MX Anywhere 3 Mac" does not have _HID_SERVICE_ Connection timed out disconnect result: 307 BLEPaired HIDBadBehavior Central The sequence repeated during automatic reconnection attempts. The mouse later recovered on some occasions, but other incidents required turning Bluetooth off for about 15 seconds, turning it back on, forgetting the mouse, and pairing it again. Instrumented reproduction During a monitored reproduction on macOS 26.1: detailed audio discovery started at +21.333 s; a 2.400 s gap in raw HID reports from the mouse occurred 0.899 s before that event; bluetoothd then reported a HID lag issue for VID 0x046D, PID 0xB025 at +1.897 s; no display-frame gaps were detected; there was no sustained CPU saturation. This indicates that the interruption is already present in the raw HID input stream. It does not appear to be only a cursor animation or WindowServer rendering delay. Expected result Discovering or switching audio outputs should not alter a separate BLE HID mouse connection, cause multi-second HID report gaps, remove _HID_SERVICE_, or disconnect the mouse. Technical points for investigation Could this be a macOS Bluetooth/HID connection-parameter or service-discovery problem triggered by concurrent audio discovery? In particular, why does macOS change the mouse from 30 ms / latency 0 to 7.5 ms / latency 44, then classify it as Incompatible LE HID, lose _HID_SERVICE_, and eventually disconnect it with result 307? Has anyone reproduced the same sequence with a Logitech BLE mouse, a Bluetooth audio headset, or a USB 3 storage device connected? The issue was also submitted through Apple’s public macOS feedback form on 24 September 2026. That form confirmed receipt but did not provide an FB case number. Possibly related report Another Developer Forums report describes a different BLE HID device with Incompatible LE HID and disconnect result 307 on macOS 27. The hardware and trigger are different, but the Bluetooth/HID failure signature may be related: https://developer.apple.com/forums/thread/845857
6
0
202
4d
CoreBluetooth reconnection to legacy BLE directed advertisements differs across iPad hardware
To whomever this may concern, We are investigating a BLE firmware-update compatibility issue affecting a legacy Nordic nRF51 DFU bootloader on a subset of iPads. We are seeking guidance on whether there are known CoreBluetooth or Bluetooth-controller differences across recent iPad hardware that could affect reconnection to Bluetooth LE connectable directed advertisements. Background Our accessory uses a legacy Nordic nRF51 DFU flow: The iPad is connected to the accessory’s normal application firmware. The app requests entry into DFU mode. The accessory disconnects normally. The accessory restarts into its bootloader. The bootloader sends connectable directed advertisements targeted at the iPad that initiated DFU. The iPad is expected to reconnect, after which the firmware transfer begins. Observed behavior On working iPads, the BLE trace shows: Application disconnect → accessory begins connectable directed advertising → iPad sends BLE connection indication → bootloader connection succeeds → DFU begins On affected iPads, the trace shows: Application disconnect → accessory begins the same connectable directed advertising → no connection indication from the iPad → DFU cannot proceed The accessory is advertising to the current resolvable address of the connected iPad. The bootloader starts directed advertising at nearly identical timing in both working and failing traces, approximately 456 ms after disconnect. The initial disconnect is normal in both cases: LL_TERMINATE_IND / Remote User Terminated Connection / reason 0x13 The problem occurs only after the accessory begins directed advertising. It seems like the iPad might be able to receive and listen to directed advertisement, however it seems to be unable to send back a connection indication. Hardware correlation observed so far We observed a correlation with Bluetooth controller vendor information visible in our BLE captures: FORMAT FOR FOLLOWING LINES Result -> Example device -> Observed controller vendor DFU succeeds -> iPad Air, 5th generation -> Broadcom DFU succeeds -> Other tested iPads, including one iPad with an A16-class platform -> Broadcom DFU fails -> One affected iPad with an A16-class platform -> MediaTek We want to be careful not to overstate this result: We have tested only one affected MediaTek-based iPad so far. The model string is MD3Y4LL/A and its current iOS version 26.6.1. The functioning Broadcomm iPads A16 we have tested that did not fail DFU process have model string MD7F4KN/A. The other iPad models we tested DFU on (which were all successful, albeit none of them were MediaTek chips, they were all Broadcomm) were: MRJN2KN/A, MM9C3KN/A, MQ6J3KN/A, MM6T3KN/A (the latter with iOS 26.6.1 as well, suggesting it is not necessarily an iPad OS version issue) We have not found a second MediaTek-based iPad to determine whether the behavior reproduces across that hardware. We initially suspected that recent non-cellular iPads might consistently use MediaTek, but this was disproved by the iPad Air, 5th generation we tested (MM9C3KN/A): it had no cellular connection and used Broadcom, and DFU worked normally. Therefore, we do not conclude that the issue is caused by MediaTek hardware. We only see a correlation worth investigating. What we have ruled out The target firmware image is not involved; failure occurs before any firmware data is transferred. The accessory reaches bootloader mode and sends directed advertisements at the expected time. The iOS Nordic DFU library already calls CoreBluetooth’s normal reconnect API: centralManager.connect(peripheral, options: nil) iOS does not expose an API allowing an app to create or send a raw Link Layer CONNECT_IND; therefore the application cannot directly work around controller-level connection behavior. The affected iPad does not provide a normal scanner/discovery callback for this directed bootloader advertisement, so matching by name or service UUID is not available as an application-layer workaround. Questions . Are there known CoreBluetooth, iPadOS, or Bluetooth-controller differences that can affect handling of BLE connectable directed advertisements, particularly when an accessory directs advertisements to a central using a resolvable private address? . Is there a recommended CoreBluetooth pattern for reconnecting to a known peripheral after it restarts into a legacy bootloader that uses directed advertising? . Does CBCentralManager.connect(_:options:) queue a pending connection request that should be serviced when a matching directed advertisement is received? If so, are there circumstances in which this behavior differs by iPad hardware or controller implementation? . Is there any public diagnostic information, entitlement, or supported API that could help us determine why a pending CoreBluetooth connection request does not result in a connection attempt in this scenario? . Does Apple recommend a specific compatibility approach for legacy BLE DFU bootloaders that use directed advertising, beyond updating the accessory firmware to use ordinary undirected advertising? . We can provide packet captures from both the working and failing cases, including timestamps, directed-advertisement target addresses, and the absence/presence of the subsequent connection indication. Thank you for any guidance on whether this is expected behavior, a known compatibility limitation, or if there is anything we could try on our end to hopefully resolve this issue.
1
0
114
4d
iOS 27: tel: links with call-forwarding codes now blocked as "Malicious Link Blocked" (FB24843805)
Starting in iOS 27, opening a tel: URL that contains a call-forwarding MMI code from an app shows a system alert and dials nothing: Malicious Link Blocked: This link was blocked because it contains malware that will forward all of your incoming messages and calls to 1 (XXX) XXX-XXXX. Scammers often provide malicious links that look legitimate via email, text, or chat. On iOS 26 the same call showed the normal call confirmation prompt and the carrier applied the forwarding. Repro (in response to a button tap): UIApplication.shared.open(URL(string: "tel:*21*XXXXXXXXXXX%23")!) Typing *21*XXXXXXXXXXX# into the Phone app's keypad by hand still works on iOS 27, so the capability is still there; only the in-app handoff is blocked. This breaks setup for call-screening and visual-voicemail apps whose onboarding depends on carrier forwarding (*21*, *61*, *67*, *71*, *72). It also blocks the disable codes (##21#, ##004#, *73), so users can't turn forwarding off from inside the app, which works against the user's own safety. The anti-hijack intent makes sense for links arriving from Messages, Mail or Safari. For a user tap inside an installed App Store app, a confirmation sheet ("Forward calls to ...? Allow") seems like the right balance, and disable codes should always be allowed. Filed as FB24843805. Questions: Is this block meant to apply to links opened by an installed app in response to a user tap? Is there a supported API, entitlement or URL form to hand a forwarding code to the Phone app with user confirmation? Our current workaround is to copy the code to the clipboard and ask the user to paste it into the keypad, which is a real drop-off point for our (mostly older) users. If you're affected too, please file your own feedback and reference FB24843805.
3
1
535
4d
CMLogItem.timestamp: which clock is it on, and how to convert to AVCaptureSession.synchronizationClock / host time?
We receive live relative-altitude updates from CMAltimeter.startRelativeAltitudeUpdates(to:withHandler:) on iPhone. CMAltitudeData inherits CMLogItem.timestamp, which the documentation describes as the time when the item is valid and as seconds since device boot. We need to determine whether a pressure measurement's event time falls inside an application operation bounded by a supported monotonic clock. Could Apple clarify the supported contract for CMAltitudeData.timestamp on iOS? Does CMAltitudeData.timestamp use the same epoch and rate as mach_absolute_time(), DispatchTime.uptimeNanoseconds, CACurrentMediaTime(), or ProcessInfo.systemUptime? If only some are compatible, which ones? Does it advance or pause during device sleep, device lock, application suspension, and background execution? In particular, are its sleep/suspension semantics guaranteed to match any of the clocks above? Is there a supported API for converting CMLogItem.timestamp to a host CMClock/Mach time, or for sampling “now” in the exact same clock domain used by CMAltitudeData.timestamp? Are the answers contractual across supported iPhone hardware and iOS releases, or are they implementation details that applications should not rely on? If direct comparison is not supported, what Apple-supported clock or conversion mechanism should an application use to compare a CMAltitudeData event time with two application-side monotonic operation boundaries? The question concerns clock semantics only. A minimal reproducer can be supplied if requested, but no application identifier, production data, sensor values, or user data is required to answer it.
6
0
440
4d
macOS 27.2 Beta 2 - High Power Mode broken on MacBook Pro 14" M5 Pro (Mac17,9)
Subject: Hard SMC and Kernel bug on 14" MacBook Pro M5 Pro (Mac17,9) in Build 26B5091g - High Power Mode completely unresponsive Hello CoreOS and Apple Silicon Performance Engineering Teams, I am writing to report a severe, reproducible system-level regression regarding High Power Mode and SMC power distribution on the new 14-inch MacBook Pro with the M5 Pro chip (Model Identifier: Mac17,9), currently running macOS 27.2 Beta 2 (Build 26B5091g). The issue prevents the M5 Pro hardware from scaling its cooling and power envelope correctly, rendering High Power Mode completely broken regardless of the power source (tested with both official 96W and 140W Apple power adapters). Key technical diagnostic findings from my device: Kernel vs UI State Mismatch: Running pmset -g via Terminal returns powermode 2, proving that the kernel registers High Power Mode as active. However, the System Information profile reader (Hardware -> Power) shows a direct conflict: "High Power Mode: No" and "Low Power Mode: Yes" (Режим энергосбережения: Да). Unresponsive SMC & Fan Curves: The cooling hardware remains completely unresponsive to the high-performance toggle. The fans fail to engage the pre-emptive 4500-5000 RPM cooling curve under heavy compute or gaming loads, remaining locked in the silent "Automatic" profile, which causes artificial thermal constraints. Powermetrics Telemetry Anomalies: A raw powermetrics trace captured during this state reveals a severe thread management bug: The P0-Cluster (High-Performance cores) shows a down residency of 98.88%, meaning the heavy performance cores are effectively kept asleep by the OS governor during high-power configuration. Combined Power (CPU + GPU + ANE) drops to a mere 429 mW. The thermal sampler entirely fails to pull hardware RPM telemetry from the SMC fan loops, providing only a generic "Current pressure level: Nominal" string. This profile behavior confirms that the macOS 27.2 power governor layer is suffering from a hard breakdown in SMC communication specific to the J614/Mac17,9 platform. The operating system handles the software flag but fails to pass the physical instruction downstream to the hardware control registers. Please prioritize this issue for the next macOS 27.2 beta cycle to ensure full thermal and compute optimization for the M5 Pro architecture prior to the final public release. I have attached the complete sysdiagnose archive, terminal configuration text files, and raw powermetrics logs. Thank you for your dedication to Apple Silicon optimization. FB24929043
3
0
88
4d
Background location indicator in Dynamic Island remains stuck after installing a new build over an app with an active location session
We are seeing a reproducible issue on a physical iPhone with Dynamic Island. Steps to reproduce Install and launch version 1 of the app locally. Start background location tracking using CLLocationUpdate.liveUpdates() together with CLBackgroundActivitySession. Move the app to the background. The blue location indicator appears in the Dynamic Island. While tracking is still active, install version 2 over the existing app. Open the updated app. Stop all location tracking: Cancel the CLLocationUpdate task. Call invalidate() on the CLBackgroundActivitySession. Release all references to the session. Move the app to the background again. Expected behavior The blue background location indicator disappears after the location updates and background activity session have been stopped. Actual behavior The blue location indicator remains permanently visible in the Dynamic Island, even though: No location updates are being received. No CLBackgroundActivitySession is retained. Starting and stopping another location session does not remove it. Force-quitting and reopening the app does not remove it. Only restarting the iPhone makes the indicator disappear. The problem occurs when a new build is installed over an existing installation while a background location session is active. Starting and stopping the same session normally within one installed version works as expected. Comparison with Live Activity background location The app also has a separate location feature that uses an active Live Activity to support background location updates without creating a CLBackgroundActivitySession. Installing a new build while that feature is active does not cause the blue location indicator to become stuck. The problem has only been reproduced when a CLBackgroundActivitySession is active during the installation. This suggests that the issue is specifically related to transferring or cleaning up CLBackgroundActivitySession state across an app update, rather than to CLLocationUpdate.liveUpdates() itself. Questions Is this a known issue with CLBackgroundActivitySession or CLLocationUpdate.liveUpdates()? Is there a supported way for the newly installed app process to invalidate or clean up a background location session created by the previous app process?
5
0
997
4d
vmnet_network_ref loses its DHCP reservations and port-forwarding rules when its last interface leaves
I'm using the macOS 26 vmnet network API with Virtualization framework (vmnet_network_create + VZVmnetNetworkDeviceAttachment) and giving each VM a stable address with vmnet_network_configuration_add_dhcp_reservation, plus creation-time rules from vmnet_network_configuration_add_port_forwarding_rule. Both work on the network's first run. But if the network's last interface leaves while I still hold the vmnet_network_ref, then the next interface start brings the network back without its reservations or forwarding rules. The subnet and gateway are kept. How it shows up in practice: a VM that is the only guest on its network gets restarted from inside the guest. Virtualization framework removes and re-adds the VM's vmnet interface about 1 s apart, with no delegate callback. That's enough to stop and restart the network, and the guest comes back on a dynamic lease with its forwarded ports refused. Minimal repro, no VM needed: Create a configuration in VMNET_SHARED_MODE with set_ipv4_subnet, one add_dhcp_reservation and one add_port_forwarding_rule, then call vmnet_network_create. vmnet_interface_start_with_network. InternetSharing logs port forwarding enabled …, and /etc/bootptab contains the reservation. vmnet_stop_interface. InternetSharing logs no internal interface left, stopping network → reset to idle, and /etc/bootptab is emptied. vmnet_interface_start_with_network again on the same, still-retained ref. InternetSharing logs has been started with no port forwarding enabled line, and /etc/bootptab is never rewritten. The forwarded port is refused. Control: release the ref, call vmnet_network_create again from the same configuration, and start an interface. The reservation and the rule are both back. Reproduced on macOS 27.0 (26A428) and (with a minimal vmnet only test, no actual VM) on macOS 26.6.2 (25G83). This seems to contradict the documentation for vmnet_network_create: "The lifetime of such reservation is the same as that of vmnet_network_ref." A related issue: vmnet_interface_add_ip_port_forwarding_rule and its remove and get counterparts return VMNET_FAILURE synchronously on an interface started with vmnet_interface_start_with_network. The same calls work on a vmnet_start_interface interface. The add_port_forwarding_rule documentation points to those calls for managing rules after start, so there's no way to put a rule back after the restart. The same "torn down on last detach while the ref lives on" lifecycle is also reported in apple/container#2051 (https://github.com/apple/container/issues/2051), with a different symptom (two networks sharing a bridge, so tearing one down breaks the other's egress). It proposes the same mitigation: an anchor interface held with vmnet_interface_start_with_network. Filed as: FB24895271: reservations and rules discarded when the last interface is removed FB24895264: the runtime forwarding calls fail on network-attached interfaces FB24895282: suggestion for a network state-change callback and a DHCP lease query by MAC Questions: Is losing reservations and rules when the network goes idle intended? Is holding an app-owned interface on the network (via vmnet_interface_start_with_network) so it never reaches zero interfaces a supported workaround, or does it risk other side effects?
1
0
292
4d
Supported lifecycle and termination guarantees for an embedded macOS XPC service
We are evaluating a lifecycle architecture for a local macOS application and would appreciate guidance on supported public APIs. Proposed architecture: A normally signed, non-root host application. One embedded XPC service with exactly one intended client. No application-created subprocesses inside the service. No privileged helper, persistent LaunchAgent, exported endpoints, private APIs, or reduced system security. One bounded operation per session. Failed or interrupted operations must not automatically be retried. Initial validation would use synthetic workloads only. Our current evaluation target is macOS 15.6 on Apple silicon, using the macOS 15.5 SDK. Please identify any relevant deployment-version limitations. The XPC overview (https://developer.apple.com/documentation/xpc) describes an embedded service as tied to its client's lifetime. We also understand that xpc_connection_cancel (https://developer.apple.com/documentation/xpc/xpc_connection_cancel(_:)) is asynchronous and non-preemptive; we are not treating connection cancellation as proof of service termination. We need clarification on these points: Client death and service startup Does the documented client-lifetime relationship cover client termination, including SIGKILL, during service startup before the first reply? Does it also cover an already running service that is blocked or stopped with SIGSTOP? Which behavior is guaranteed, and which timing or failure cases are intentionally unspecified? Timeout while the client remains alive What supported public mechanism should a normal application use to terminate its own unresponsive embedded service when an operation exceeds its deadline? We want to avoid PID enumeration, PID-reuse races, broad process-group signaling, and exporting a full task-control port. Is there a supported identity-bound termination mechanism? If not, what architecture does Apple recommend? A stopped or hung client remains alive, so we do not assume client-lifetime coupling handles that separate failure case. Observing termination Which public notification reliably identifies the exit of the particular service instance, as distinct from connection invalidation or a missing reply? Because launchd is the parent, the application cannot simply waitpid the service. Is reaping entirely launchd's responsibility, and what completion claim can the application legitimately make? Identity and required privileges Which public signing requirements, launch constraints, sandbox settings, or entitlements are necessary for this architecture? Please distinguish authentication before accepting work from constraints enforced before service code executes. We do not assume peer authentication also grants termination rights. Restart behavior After interruption, cancellation, client exit, or service failure, under what circumstances can launchd or subsequent XPC activity start a replacement service? What supported pattern prevents accidental resubmission or resumption of the same failed operation? We are not asking for hard real-time guarantees during kernel failure, or claiming that forced termination proves callback completion or explicit memory zeroization. If this combination of requirements is unsupported, identifying that boundary and the smallest supported architectural alternative would be a useful answer. Documentation references or a minimal public sample would be welcome.
3
0
131
4d
Restartable Sequences. What are they?
After scouring the XNU kernel source code, I came across restartable ranges [1]. They seem to be a task-level version of the the part of Linux's restartable sequences [2] for user requested synchronization [3] (akin to MEMBARRIER_CMD_RSEQ). Because of their differences, I would like to know more about how they work and what they are used for. From what I have gathered [4], they seem to be closer to RCU [5] that waits for eviction (as opposed to completion). But the fact that they are barely mentioned anywhere (see [4]) in the XNU source code I'd be really happy if you can point me to more information about them and how they compare to rseq (or rcu). What are the XNU devs planning on doing with them? [1] osfmk/kern/restartable.c: https://github.com/apple-oss-distributions/xnu/blob/f6217f8/osfmk/kern/restartable.c [2] https://criu.org/Restartable_Sequences [3] as opposed to (what I think is what makes rseq really cool) automatic eviction on preemption/CPU migration [4] there seems to be very little information online (including this forum) and the only places inside the XNU kernel source trees that aren't tests are in osfmk/kern/{thread,thread,sched_prim}.{c,h}, which doesn't really give much more information. [5] Read-Copy-Update: https://www.kernel.org/doc/html/latest/RCU/whatisRCU.html
1
0
88
4d
How to do line- and message-delimination
I'm trying to write a NWProtocolFramerImplementation class that will be channeled through a Framer wrapper. There are still some parts I need figuring out. For handleOutput(framer: message: messageLength: isComplete), what do the last two parameters do? Does isComplete refer to the end of the current conversation, or the entire connection? Why would we submit a messageLength if the data size should already be implied within message? If I parse by line breaks, is there a way to indicate if the latest line is the last of the current conversation, either input or output?
1
0
76
4d
Supported native alphabet navigation for CPListTemplate on iOS 27
We need to retain CarPlay's native A–Z button between the scroll arrows in an audio app. This is core navigation for an album/artist library. We use CPListSection(items:header:sectionIndexTitle:) with single-character labels. The sectionIndexTitle API is still documented and is not deprecated in the Xcode 27 SDK. We need the supported native implementation, not a custom picker. On a parked physical head unit with an iPhone running iOS 27, our app displays populated album rows and section headers but no A–Z. Apple Music displays A–Z on the same head unit. We do not know Apple Music's internal implementation. A standalone, public-API-only reproduction is prepared; its CarPlay scene code is included below. Each tab supplies four A/B/M/Z sections of ten synthetic rows. The variants are initially populated, updated after loading, the full section initializer, and securely archived and decoded sections. No network, authentication or artwork is required. The original app displays functioning native alphabet navigation on the iOS 26.5 CarPlay simulator. The public probe compiles. We cannot run an end-to-end iOS 27 CarPlay simulator session because Device Hub requires a physical device, as confirmed in developer forum thread 834440. Separately, an isolated local diagnostic hosted the native list renderer with CarPlay traits. Both runtimes receive four nonempty index labels and all 40 rows. On iOS 26.5 (23F77), its table data source returns A/B/M/Z. On iOS 27.0 (24A434), the attached UICollectionViewDiffableDataSource returns nil index titles. Both the full initializer and secure archive round-trip preserve titles but produce the same result. This diagnostic is not an end-to-end CarPlay session and does not establish the exact internals on the physical phone. A standard UIKit table supplied with index titles and CarPlay traits still displays the native A–Z button on the same iOS 27 runtime. The control itself still exists; the observed failure is the template-to-index connection. This control experiment is also hosted in a phone window, not a CarPlay session. A standard UIKit collection data source implementing indexTitles(for:) also shows index letters on this runtime; the unmodified template renderer's collection data source returns nil. We have not modified that renderer. Questions: Did iOS 27 move native CPListTemplate alphabet navigation to another API, configuration, or presentation requirement? What is the supported migration? If sectionIndexTitle remains the correct input, is this a known regression in the new list renderer, and what supported correction is available? How should third-party audio apps reproduce Apple Music's native alphabet navigation on iOS 27 without private API or replacing it with a custom control? Please provide a working public-API example or identify the relevant fix/version. Reproduction: use the audio CarPlay entitlement and configure CPTemplateApplicationScene with CarScene as its delegate. This is the scene code from the compiling standalone probe: import CarPlay import UIKit @MainActor func indexedSections() -> [CPListSection] { ["A", "B", "M", "Z"].map { letter in let items = (1...10).map { number in let item = CPListItem(text: "\(letter) Album \(number)", detailText: "Synthetic test entry") item.handler = { _, completion in completion() } return item } return CPListSection(items: items, header: letter, sectionIndexTitle: letter) } } final class CarScene: UIResponder, CPTemplateApplicationSceneDelegate { func templateApplicationScene(_ scene: CPTemplateApplicationScene, didConnect controller: CPInterfaceController) { let ready = CPListTemplate(title: "Ready", sections: indexedSections()) ready.tabTitle = "Ready" ready.tabImage = UIImage(systemName: "list.bullet") let updated = CPListTemplate(title: "Updated", sections: [CPListSection(items: [CPListItem(text: "Loading", detailText: nil)])]) updated.tabTitle = "Updated" updated.tabImage = UIImage(systemName: "arrow.clockwise") let full = CPListTemplate(title: "Full Init", sections: indexedSections().map { CPListSection(items: $0.items, header: $0.header ?? "", headerSubtitle: nil, headerImage: nil, headerButton: nil, sectionIndexTitle: $0.sectionIndexTitle) }) full.tabTitle = "Full Init" full.tabImage = UIImage(systemName: "list.bullet.rectangle") let decoded: CPListTemplate do { let sections = try indexedSections().map { section in let data = try NSKeyedArchiver.archivedData(withRootObject: section, requiringSecureCoding: true) guard let restored = try NSKeyedUnarchiver.unarchivedObject(ofClass: CPListSection.self, from: data) else { throw CocoaError(.coderReadCorrupt) } return restored } decoded = CPListTemplate(title: "Decoded", sections: sections) } catch { decoded = CPListTemplate(title: "Decode failed", sections: [CPListSection(items: [ CPListItem(text: "Section decoding failed", detailText: String(describing: error)) ])]) } decoded.tabTitle = "Decoded" decoded.tabImage = UIImage(systemName: "shippingbox") controller.setRootTemplate(CPTabBarTemplate(templates: [ready, updated, full, decoded]), animated: false) { _, _ in } Task { @MainActor in try? await Task.sleep(for: .seconds(2)) updated.updateSections(indexedSections()) } } }
0
0
58
4d
NSMenuItem.separator() appears as blank space in Finder Sync extension context menu
Hi, I’m developing a macOS Finder Sync extension and noticed that NSMenuItem.separator() does not appear to render as a standard separator line when used inside the menu returned from FIFinderSyncController. In a normal AppKit NSMenu, the separator renders as expected. However, when the same kind of menu is returned from the Finder Sync extension, the separator appears as a blank/full-height empty row rather than a thin dividing line. Example: override func menu(for menuKind: FIMenuKind) -> NSMenu { let menu = NSMenu(title: "") menu.addItem(NSMenuItem( title: "First Action", action: #selector(firstAction(_:)), keyEquivalent: "" )) menu.addItem(NSMenuItem.separator()) menu.addItem(NSMenuItem( title: "Second Action", action: #selector(secondAction(_:)), keyEquivalent: "" )) return menu } Expected result: The separator should render as a normal macOS menu separator line between the two menu items. Actual result: In Finder’s context menu, the separator is displayed as blank vertical space / an empty menu row. I understand that Finder Sync menus are rendered by Finder and may not support every NSMenuItem feature. However, NSMenuItem.separator() is a very standard way to visually group menu commands, so I wanted to ask: Is this a known limitation of Finder Sync extension menus? Is there a supported way to display a real separator line in Finder Sync context menus? Should this be filed as a Feedback Assistant issue against Finder Sync / AppKit? I’m trying to avoid fake separators such as disabled menu items with "────" as the title, since that does not feel native and may not behave well with different fonts, accessibility settings, or appearance modes. Thanks!
1
1
581
4d
SwiftData with CloudKit Error: Error updating background task request
Hi, Overview I have a SwiftData project which automatically syncs with CloudKit. When I run the app, I see the following error in Xcode logs. Error updating background task request: Error Domain=BGSystemTaskSchedulerErrorDomain Code=3 "(null)" My attempt I can enable Background processing (under Signing & Capabilities > Background modes), but I don't know the BGTaskSchedulerPermittedIdentifiers to add in the Info.plist Questions How can I resolve this? If I should enable background processing, what are the BGTaskSchedulerPermittedIdentifiers to add in Info.plist?
19
0
2.3k
4d
iOS Background Location / Geofencing for Automatic Attendance — App Not Triggering Reliably
iOS Background Location / Geofencing for Automatic Attendance — App Not Triggering Reliably We are developing an enterprise attendance application called Attendo, which uses location-based geofencing for automatic employee check-in/check-out. Business requirement The application needs to work as follows: An employee is assigned an office/work location with a defined radius. When the employee enters the configured radius, the application should automatically record a Check-In. When the employee leaves the radius, the application should automatically record a Check-Out. This should happen without the employee having to open the application. The functionality needs to work even when the application is in the background and, where supported by iOS, after the application has been terminated. For example: «Office geofence = 200 meters Employee enters the 200 m radius → automatic Check-In Employee leaves the 200 m radius → automatic Check-Out» Current iOS implementation We are using iOS location services with: Location permission: Always Precise Location: enabled Background Location capability enabled Background location updates enabled Geofencing / region monitoring The application is intended to respond to location/geofence events without requiring the user to open the app. However, we are seeing cases where the application does not reliably receive/process the required location/geofence event when the application has been in the background for an extended period. The same business workflow works more reliably while the application is active. Our concern Our understanding is that iOS does not allow an application to maintain a continuously running background service in the same way that Android can. However, our requirement does not necessarily require continuous GPS polling if there is an Apple-supported mechanism that can reliably wake/relaunch the application when a user crosses a geofence. We would therefore like to understand the recommended architecture for this use case. Questions Is Core Location Region Monitoring the recommended mechanism for an enterprise geofencing application that needs to detect entry/exit while the app is not running? Can iOS relaunch the application after it has been terminated by the user/system when a monitored region is entered or exited? Is there any supported way to guarantee that an application will continue receiving location/geofence events after it has been in the background for a long period? Does enabling: "UIBackgroundModes = location" "allowsBackgroundLocationUpdates" "CLLocationManager" Region Monitoring provide the expected behavior, or are there additional requirements/configurations we should consider? Are there known limitations regarding: Low Power Mode device movement speed GPS/location accuracy stationary devices iOS terminating/suspending the application force-quitting the application from the App Switcher large/small geofence radius multiple monitored regions Is it possible to use significant-change location updates + region monitoring together for this type of attendance workflow? For an enterprise application where the user explicitly grants Always Allow Location permission and Precise Location is enabled, what level of reliability can realistically be expected from iOS geofencing? Important business constraint We cannot require employees to manually open the application every time they arrive at or leave the workplace. The objective is an automatic attendance system, where the employee's entry and exit from the workplace geofence is detected by iOS and the application records the corresponding attendance event. We understand that iOS is designed to protect battery life and user privacy and that continuous background execution may not be permitted. We are therefore looking for the Apple-recommended architecture for achieving this requirement using supported iOS APIs, rather than trying to circumvent iOS background execution policies. Any guidance from Apple engineers or developers who have implemented reliable enterprise geofencing would be greatly appreciated.
Replies
0
Boosts
0
Views
249
Activity
3d
AlarmKit: supported approach for a server-triggered wake-up alarm after an air-raid all-clear
Dear Apple Developer Support, I am developing HushRise, an iPhone alarm application intended to help people in Ukraine manage sleep disrupted by wartime air-raid alerts. Nighttime alerts can force people to interrupt their sleep and seek shelter, sometimes repeatedly. Families must then plan work, school, and other responsibilities around these disruptions. Educational institutions and other services may suspend in-person activities during alerts, making a fixed wake-up time less useful than a wake-up signal that takes the current alert status into account. The purpose of HushRise is to support rest and daily routines under these conditions. It is not an official emergency-warning service and must not replace civil-defence alerts or encourage people to ignore them. The intended behavior is: A user sets a wake-up time and selects their region. At that time, the alarm starts only after a fresh server response confirms that no air-raid alert is active. If an alert is active, the application waits for the reported all-clear. Multiple alarms postponed during the same alert should produce one wake-up signal after the all-clear. A snoozed alarm must also obtain fresh confirmation before starting again. An alarm that has already started may continue until the user stops or snoozes it. We have tested a native AlarmKit integration on a physical iPhone. The system alarm, Lock Screen controls, Apple Watch presentation, and Stop action work. However, without ongoing background audio, iOS suspends our application’s status checks. In one test, an alarm due at 20:09 was not scheduled until the application returned to the foreground at 20:11. Audible background playback helped in experiments, but requiring continuous sound is not appropriate for the intended quiet sleep experience. Could your technical team please advise: What supported architecture should we use for an AlarmKit alarm whose trigger depends on a server event occurring at an unknown time? Can a server notification initiate the necessary validation and alarm scheduling while the iPhone is locked, and what execution guarantees or limitations apply? Is there an entitlement or approval process appropriate to this use case? Would Critical Alerts be applicable, or would another mechanism be more suitable? Which capabilities require Apple Developer Program membership? Our current prototype is installed through a free Personal Team. We understand that an offline device cannot receive new server information and that notification delivery may be delayed. We want to communicate these limitations honestly and build within Apple’s supported APIs. We can provide a minimal reproducible project, sanitized device logs, and a description of our physical-device tests. Thank you for helping us identify a reliable and appropriate approach for people whose sleep and daily lives are affected by the war in Ukraine. Kind regards, HushRise developer
Replies
2
Boosts
0
Views
383
Activity
3d
Location Services stopped working across the system on macOS
MacBook Air (M4) Current build: macOS 27 Developer Beta (26A5368g) I have a system-wide Location Services failure affecting Apple Maps, Safari geolocation APIs, and any application requesting the current location. Symptoms: Apple Maps cannot determine current location. Safari and browser geolocation APIs fail. Websites report that location cannot be found. Location Services are enabled and permissions are granted. The issue has persisted across: macOS 26.5 beta macOS 26.6 beta macOS 26.6 beta 2 macOS 27 Developer Beta Troubleshooting already performed: Multiple Wi-Fi networks tested. iPhone hotspot tested. VPN enabled and disabled. Location Services reset. Permissions reset and reauthorized. New clean local user account created (no Apple ID, no third-party software). Issue reproduces identically in the clean account. Technical observations: locationd logs repeatedly show: knownCount = 0 AlsWifi = unknown while Wi-Fi scanning itself appears successful: queryMacAddresses.size = 57 The system sees dozens of nearby access points, but none appear to be recognized for Wi-Fi positioning. Additional findings: Wi-Fi hardware functions normally. Internet connectivity is normal. Bluetooth and Find My device presence work. GeoServices resources are present on disk. No successful location fix is ever produced. Has anyone seen similar CoreLocation / GeoServices behavior where Wi-Fi scans succeed but knownCount always remains 0 and no location fix is generated?
Replies
5
Boosts
2
Views
1.6k
Activity
3d
Unable to invalidate interval: no data source available error when fetching steps using HKStatisticsCollectionQuery
While attempting to read a user’s daily step history spanning backward to the last 7 days, a small but consistent subset of users encounter Error Code 3 with the underlying error description: Error Code 3 "Unable to invalidate interval: no data source available." When this error occurs, we are entirely unable to read their step history. We have received ~10 direct user reports of this within the last couple of weeks.
Replies
15
Boosts
2
Views
2.1k
Activity
4d
Open parent app from ShieldAction extension in iOS
When I tap on one of the buttons in the ShieldAction extension I want to close the shield and open the parent app instead of the shielded app. Is there any way of doing this using the Screen Time API? class ShieldActionExtension: ShieldActionDelegate {      override func handle(action: ShieldAction, for application: ApplicationToken, completionHandler: @escaping (ShieldActionResponse) -> Void) {     // Handle the action as needed.           let store = ManagedSettingsStore()               switch action {     case .primaryButtonPressed:       //TODO - open parent app       completionHandler(.defer)     case .secondaryButtonPressed:       //remove shield       store.shield.applications?.remove(application)       completionHandler(.defer)         @unknown default:       fatalError()     }   }   }
Replies
15
Boosts
9
Views
7.1k
Activity
4d
macOS 26.7: opening Control Center Sound causes BLE HID mouse lag, HID service loss, and result 307
I am seeing a repeatable interaction between audio activity or audio-device discovery and a Bluetooth LE HID mouse on a Mac mini M2 Pro. Opening the detailed Sound panel in Control Center, or changing the HDMI audio output, makes the pointer stutter. Opening Apple’s Music.app has also caused a temporary complete loss of the mouse. In the worst cases, the mouse becomes completely unavailable and does not recover without Bluetooth troubleshooting or re-pairing. Configuration Mac mini Mac14,12, Apple M2 Pro, 32 GB RAM macOS Tahoe 26.7 (25G229) Also reproduced on macOS Tahoe 26.1 (25B78) Logitech MX Anywhere 3 Mac over Bluetooth LE VID 0x046D, PID 0xB025 Firmware MPM24.01_0015 Logitech MX Keys M Mac over Bluetooth LE PL4071UH display and audio output over HDMI Logi Options+ installed Trigger Connect the MX Anywhere 3 Mac and MX Keys over Bluetooth. Open Control Center from the menu bar. Open the detailed Sound panel, or change the HDMI audio output. Move the Bluetooth mouse continuously while audio-output discovery is taking place. The issue is intermittent, but it has been reproduced several times on both macOS 26.1 and 26.7. Pointer stuttering can continue after the Sound panel is closed. A later incident occurred when I opened Apple’s Music.app. The Bluetooth mouse became unavailable again, but this time it recovered automatically after approximately ten seconds. The Sony WH-1000XM6 headset was connected over Bluetooth, while the 512 GB USB flash drive was not connected. This shows that the USB drive is not required for a temporary mouse loss and makes concurrent Bluetooth audio activity a more relevant condition to investigate. The additional trigger suggests that the problem may not be limited to the Control Center interface itself and may also be associated with audio-subsystem initialization or audio-device activity. This is an observation, not yet a confirmed causal link. Additional condition in the permanent-loss cases In every incident where the mouse did not recover on its own and became effectively unusable, the following two devices were also present: a Sony WH-1000XM6 wireless headset connected over Bluetooth; a 512 GB SanDisk USB flash drive connected to the Mac. I am reporting this as a correlation, not as a confirmed cause. The headset adds simultaneous Bluetooth audio activity. The USB drive may or may not be relevant depending on its USB mode, activity, shielding, physical location, and possible 2.4 GHz interference. The 512 GB capacity is included only to identify the device. Less severe cursor stuttering has also been observed around Sound-panel discovery; the two devices above are specifically the common condition I recorded during the permanent mouse-loss incidents. Observed result The pointer starts stuttering and raw mouse HID reports develop multi-second gaps. In severe incidents, the Bluetooth mouse stops working entirely. Opening Music.app has also caused a temporary complete loss of the mouse; during that incident the Sony WH-1000XM6 was connected over Bluetooth, the USB flash drive was not connected, and the mouse recovered automatically after approximately ten seconds. Logi Options+ then displays the mouse as inactive. The mouse disappears from the IOHID tree, while the Bluetooth keyboard can remain present. A wired USB mouse remains responsive, so the Mac and pointer rendering are not completely frozen. The failure can persist after the Sound panel is closed. Relevant logs On macOS 26.7, bluetoothd repeatedly recorded the following sequence for the MX Anywhere 3 Mac: MX Anywhere 3 Mac needs low latency current connection parameters: interval 30.00 ms, latency 0 connection changed to: interval 7.50 ms, latency 44 Device "MX Anywhere 3 Mac" is Incompatible LE HID Device "MX Anywhere 3 Mac" does not have _HID_SERVICE_ Connection timed out disconnect result: 307 BLEPaired HIDBadBehavior Central The sequence repeated during automatic reconnection attempts. The mouse later recovered on some occasions, but other incidents required turning Bluetooth off for about 15 seconds, turning it back on, forgetting the mouse, and pairing it again. Instrumented reproduction During a monitored reproduction on macOS 26.1: detailed audio discovery started at +21.333 s; a 2.400 s gap in raw HID reports from the mouse occurred 0.899 s before that event; bluetoothd then reported a HID lag issue for VID 0x046D, PID 0xB025 at +1.897 s; no display-frame gaps were detected; there was no sustained CPU saturation. This indicates that the interruption is already present in the raw HID input stream. It does not appear to be only a cursor animation or WindowServer rendering delay. Expected result Discovering or switching audio outputs should not alter a separate BLE HID mouse connection, cause multi-second HID report gaps, remove _HID_SERVICE_, or disconnect the mouse. Technical points for investigation Could this be a macOS Bluetooth/HID connection-parameter or service-discovery problem triggered by concurrent audio discovery? In particular, why does macOS change the mouse from 30 ms / latency 0 to 7.5 ms / latency 44, then classify it as Incompatible LE HID, lose _HID_SERVICE_, and eventually disconnect it with result 307? Has anyone reproduced the same sequence with a Logitech BLE mouse, a Bluetooth audio headset, or a USB 3 storage device connected? The issue was also submitted through Apple’s public macOS feedback form on 24 September 2026. That form confirmed receipt but did not provide an FB case number. Possibly related report Another Developer Forums report describes a different BLE HID device with Incompatible LE HID and disconnect result 307 on macOS 27. The hardware and trigger are different, but the Bluetooth/HID failure signature may be related: https://developer.apple.com/forums/thread/845857
Replies
6
Boosts
0
Views
202
Activity
4d
Resubmit Your Request for a Critical Alert Notifications Entitlement
If you submitted a request for a Critical Alert Notifications entitlement and did not receive a response, please resubmit your request.
Replies
3
Boosts
0
Views
2.3k
Activity
4d
CoreBluetooth reconnection to legacy BLE directed advertisements differs across iPad hardware
To whomever this may concern, We are investigating a BLE firmware-update compatibility issue affecting a legacy Nordic nRF51 DFU bootloader on a subset of iPads. We are seeking guidance on whether there are known CoreBluetooth or Bluetooth-controller differences across recent iPad hardware that could affect reconnection to Bluetooth LE connectable directed advertisements. Background Our accessory uses a legacy Nordic nRF51 DFU flow: The iPad is connected to the accessory’s normal application firmware. The app requests entry into DFU mode. The accessory disconnects normally. The accessory restarts into its bootloader. The bootloader sends connectable directed advertisements targeted at the iPad that initiated DFU. The iPad is expected to reconnect, after which the firmware transfer begins. Observed behavior On working iPads, the BLE trace shows: Application disconnect → accessory begins connectable directed advertising → iPad sends BLE connection indication → bootloader connection succeeds → DFU begins On affected iPads, the trace shows: Application disconnect → accessory begins the same connectable directed advertising → no connection indication from the iPad → DFU cannot proceed The accessory is advertising to the current resolvable address of the connected iPad. The bootloader starts directed advertising at nearly identical timing in both working and failing traces, approximately 456 ms after disconnect. The initial disconnect is normal in both cases: LL_TERMINATE_IND / Remote User Terminated Connection / reason 0x13 The problem occurs only after the accessory begins directed advertising. It seems like the iPad might be able to receive and listen to directed advertisement, however it seems to be unable to send back a connection indication. Hardware correlation observed so far We observed a correlation with Bluetooth controller vendor information visible in our BLE captures: FORMAT FOR FOLLOWING LINES Result -> Example device -> Observed controller vendor DFU succeeds -> iPad Air, 5th generation -> Broadcom DFU succeeds -> Other tested iPads, including one iPad with an A16-class platform -> Broadcom DFU fails -> One affected iPad with an A16-class platform -> MediaTek We want to be careful not to overstate this result: We have tested only one affected MediaTek-based iPad so far. The model string is MD3Y4LL/A and its current iOS version 26.6.1. The functioning Broadcomm iPads A16 we have tested that did not fail DFU process have model string MD7F4KN/A. The other iPad models we tested DFU on (which were all successful, albeit none of them were MediaTek chips, they were all Broadcomm) were: MRJN2KN/A, MM9C3KN/A, MQ6J3KN/A, MM6T3KN/A (the latter with iOS 26.6.1 as well, suggesting it is not necessarily an iPad OS version issue) We have not found a second MediaTek-based iPad to determine whether the behavior reproduces across that hardware. We initially suspected that recent non-cellular iPads might consistently use MediaTek, but this was disproved by the iPad Air, 5th generation we tested (MM9C3KN/A): it had no cellular connection and used Broadcom, and DFU worked normally. Therefore, we do not conclude that the issue is caused by MediaTek hardware. We only see a correlation worth investigating. What we have ruled out The target firmware image is not involved; failure occurs before any firmware data is transferred. The accessory reaches bootloader mode and sends directed advertisements at the expected time. The iOS Nordic DFU library already calls CoreBluetooth’s normal reconnect API: centralManager.connect(peripheral, options: nil) iOS does not expose an API allowing an app to create or send a raw Link Layer CONNECT_IND; therefore the application cannot directly work around controller-level connection behavior. The affected iPad does not provide a normal scanner/discovery callback for this directed bootloader advertisement, so matching by name or service UUID is not available as an application-layer workaround. Questions . Are there known CoreBluetooth, iPadOS, or Bluetooth-controller differences that can affect handling of BLE connectable directed advertisements, particularly when an accessory directs advertisements to a central using a resolvable private address? . Is there a recommended CoreBluetooth pattern for reconnecting to a known peripheral after it restarts into a legacy bootloader that uses directed advertising? . Does CBCentralManager.connect(_:options:) queue a pending connection request that should be serviced when a matching directed advertisement is received? If so, are there circumstances in which this behavior differs by iPad hardware or controller implementation? . Is there any public diagnostic information, entitlement, or supported API that could help us determine why a pending CoreBluetooth connection request does not result in a connection attempt in this scenario? . Does Apple recommend a specific compatibility approach for legacy BLE DFU bootloaders that use directed advertising, beyond updating the accessory firmware to use ordinary undirected advertising? . We can provide packet captures from both the working and failing cases, including timestamps, directed-advertisement target addresses, and the absence/presence of the subsequent connection indication. Thank you for any guidance on whether this is expected behavior, a known compatibility limitation, or if there is anything we could try on our end to hopefully resolve this issue.
Replies
1
Boosts
0
Views
114
Activity
4d
iOS 27: tel: links with call-forwarding codes now blocked as "Malicious Link Blocked" (FB24843805)
Starting in iOS 27, opening a tel: URL that contains a call-forwarding MMI code from an app shows a system alert and dials nothing: Malicious Link Blocked: This link was blocked because it contains malware that will forward all of your incoming messages and calls to 1 (XXX) XXX-XXXX. Scammers often provide malicious links that look legitimate via email, text, or chat. On iOS 26 the same call showed the normal call confirmation prompt and the carrier applied the forwarding. Repro (in response to a button tap): UIApplication.shared.open(URL(string: "tel:*21*XXXXXXXXXXX%23")!) Typing *21*XXXXXXXXXXX# into the Phone app's keypad by hand still works on iOS 27, so the capability is still there; only the in-app handoff is blocked. This breaks setup for call-screening and visual-voicemail apps whose onboarding depends on carrier forwarding (*21*, *61*, *67*, *71*, *72). It also blocks the disable codes (##21#, ##004#, *73), so users can't turn forwarding off from inside the app, which works against the user's own safety. The anti-hijack intent makes sense for links arriving from Messages, Mail or Safari. For a user tap inside an installed App Store app, a confirmation sheet ("Forward calls to ...? Allow") seems like the right balance, and disable codes should always be allowed. Filed as FB24843805. Questions: Is this block meant to apply to links opened by an installed app in response to a user tap? Is there a supported API, entitlement or URL form to hand a forwarding code to the Phone app with user confirmation? Our current workaround is to copy the code to the clipboard and ask the user to paste it into the keypad, which is a real drop-off point for our (mostly older) users. If you're affected too, please file your own feedback and reference FB24843805.
Replies
3
Boosts
1
Views
535
Activity
4d
CMLogItem.timestamp: which clock is it on, and how to convert to AVCaptureSession.synchronizationClock / host time?
We receive live relative-altitude updates from CMAltimeter.startRelativeAltitudeUpdates(to:withHandler:) on iPhone. CMAltitudeData inherits CMLogItem.timestamp, which the documentation describes as the time when the item is valid and as seconds since device boot. We need to determine whether a pressure measurement's event time falls inside an application operation bounded by a supported monotonic clock. Could Apple clarify the supported contract for CMAltitudeData.timestamp on iOS? Does CMAltitudeData.timestamp use the same epoch and rate as mach_absolute_time(), DispatchTime.uptimeNanoseconds, CACurrentMediaTime(), or ProcessInfo.systemUptime? If only some are compatible, which ones? Does it advance or pause during device sleep, device lock, application suspension, and background execution? In particular, are its sleep/suspension semantics guaranteed to match any of the clocks above? Is there a supported API for converting CMLogItem.timestamp to a host CMClock/Mach time, or for sampling “now” in the exact same clock domain used by CMAltitudeData.timestamp? Are the answers contractual across supported iPhone hardware and iOS releases, or are they implementation details that applications should not rely on? If direct comparison is not supported, what Apple-supported clock or conversion mechanism should an application use to compare a CMAltitudeData event time with two application-side monotonic operation boundaries? The question concerns clock semantics only. A minimal reproducer can be supplied if requested, but no application identifier, production data, sensor values, or user data is required to answer it.
Replies
6
Boosts
0
Views
440
Activity
4d
macOS 27.2 Beta 2 - High Power Mode broken on MacBook Pro 14" M5 Pro (Mac17,9)
Subject: Hard SMC and Kernel bug on 14" MacBook Pro M5 Pro (Mac17,9) in Build 26B5091g - High Power Mode completely unresponsive Hello CoreOS and Apple Silicon Performance Engineering Teams, I am writing to report a severe, reproducible system-level regression regarding High Power Mode and SMC power distribution on the new 14-inch MacBook Pro with the M5 Pro chip (Model Identifier: Mac17,9), currently running macOS 27.2 Beta 2 (Build 26B5091g). The issue prevents the M5 Pro hardware from scaling its cooling and power envelope correctly, rendering High Power Mode completely broken regardless of the power source (tested with both official 96W and 140W Apple power adapters). Key technical diagnostic findings from my device: Kernel vs UI State Mismatch: Running pmset -g via Terminal returns powermode 2, proving that the kernel registers High Power Mode as active. However, the System Information profile reader (Hardware -> Power) shows a direct conflict: "High Power Mode: No" and "Low Power Mode: Yes" (Режим энергосбережения: Да). Unresponsive SMC & Fan Curves: The cooling hardware remains completely unresponsive to the high-performance toggle. The fans fail to engage the pre-emptive 4500-5000 RPM cooling curve under heavy compute or gaming loads, remaining locked in the silent "Automatic" profile, which causes artificial thermal constraints. Powermetrics Telemetry Anomalies: A raw powermetrics trace captured during this state reveals a severe thread management bug: The P0-Cluster (High-Performance cores) shows a down residency of 98.88%, meaning the heavy performance cores are effectively kept asleep by the OS governor during high-power configuration. Combined Power (CPU + GPU + ANE) drops to a mere 429 mW. The thermal sampler entirely fails to pull hardware RPM telemetry from the SMC fan loops, providing only a generic "Current pressure level: Nominal" string. This profile behavior confirms that the macOS 27.2 power governor layer is suffering from a hard breakdown in SMC communication specific to the J614/Mac17,9 platform. The operating system handles the software flag but fails to pass the physical instruction downstream to the hardware control registers. Please prioritize this issue for the next macOS 27.2 beta cycle to ensure full thermal and compute optimization for the M5 Pro architecture prior to the final public release. I have attached the complete sysdiagnose archive, terminal configuration text files, and raw powermetrics logs. Thank you for your dedication to Apple Silicon optimization. FB24929043
Replies
3
Boosts
0
Views
88
Activity
4d
Background location indicator in Dynamic Island remains stuck after installing a new build over an app with an active location session
We are seeing a reproducible issue on a physical iPhone with Dynamic Island. Steps to reproduce Install and launch version 1 of the app locally. Start background location tracking using CLLocationUpdate.liveUpdates() together with CLBackgroundActivitySession. Move the app to the background. The blue location indicator appears in the Dynamic Island. While tracking is still active, install version 2 over the existing app. Open the updated app. Stop all location tracking: Cancel the CLLocationUpdate task. Call invalidate() on the CLBackgroundActivitySession. Release all references to the session. Move the app to the background again. Expected behavior The blue background location indicator disappears after the location updates and background activity session have been stopped. Actual behavior The blue location indicator remains permanently visible in the Dynamic Island, even though: No location updates are being received. No CLBackgroundActivitySession is retained. Starting and stopping another location session does not remove it. Force-quitting and reopening the app does not remove it. Only restarting the iPhone makes the indicator disappear. The problem occurs when a new build is installed over an existing installation while a background location session is active. Starting and stopping the same session normally within one installed version works as expected. Comparison with Live Activity background location The app also has a separate location feature that uses an active Live Activity to support background location updates without creating a CLBackgroundActivitySession. Installing a new build while that feature is active does not cause the blue location indicator to become stuck. The problem has only been reproduced when a CLBackgroundActivitySession is active during the installation. This suggests that the issue is specifically related to transferring or cleaning up CLBackgroundActivitySession state across an app update, rather than to CLLocationUpdate.liveUpdates() itself. Questions Is this a known issue with CLBackgroundActivitySession or CLLocationUpdate.liveUpdates()? Is there a supported way for the newly installed app process to invalidate or clean up a background location session created by the previous app process?
Replies
5
Boosts
0
Views
997
Activity
4d
vmnet_network_ref loses its DHCP reservations and port-forwarding rules when its last interface leaves
I'm using the macOS 26 vmnet network API with Virtualization framework (vmnet_network_create + VZVmnetNetworkDeviceAttachment) and giving each VM a stable address with vmnet_network_configuration_add_dhcp_reservation, plus creation-time rules from vmnet_network_configuration_add_port_forwarding_rule. Both work on the network's first run. But if the network's last interface leaves while I still hold the vmnet_network_ref, then the next interface start brings the network back without its reservations or forwarding rules. The subnet and gateway are kept. How it shows up in practice: a VM that is the only guest on its network gets restarted from inside the guest. Virtualization framework removes and re-adds the VM's vmnet interface about 1 s apart, with no delegate callback. That's enough to stop and restart the network, and the guest comes back on a dynamic lease with its forwarded ports refused. Minimal repro, no VM needed: Create a configuration in VMNET_SHARED_MODE with set_ipv4_subnet, one add_dhcp_reservation and one add_port_forwarding_rule, then call vmnet_network_create. vmnet_interface_start_with_network. InternetSharing logs port forwarding enabled …, and /etc/bootptab contains the reservation. vmnet_stop_interface. InternetSharing logs no internal interface left, stopping network → reset to idle, and /etc/bootptab is emptied. vmnet_interface_start_with_network again on the same, still-retained ref. InternetSharing logs has been started with no port forwarding enabled line, and /etc/bootptab is never rewritten. The forwarded port is refused. Control: release the ref, call vmnet_network_create again from the same configuration, and start an interface. The reservation and the rule are both back. Reproduced on macOS 27.0 (26A428) and (with a minimal vmnet only test, no actual VM) on macOS 26.6.2 (25G83). This seems to contradict the documentation for vmnet_network_create: "The lifetime of such reservation is the same as that of vmnet_network_ref." A related issue: vmnet_interface_add_ip_port_forwarding_rule and its remove and get counterparts return VMNET_FAILURE synchronously on an interface started with vmnet_interface_start_with_network. The same calls work on a vmnet_start_interface interface. The add_port_forwarding_rule documentation points to those calls for managing rules after start, so there's no way to put a rule back after the restart. The same "torn down on last detach while the ref lives on" lifecycle is also reported in apple/container#2051 (https://github.com/apple/container/issues/2051), with a different symptom (two networks sharing a bridge, so tearing one down breaks the other's egress). It proposes the same mitigation: an anchor interface held with vmnet_interface_start_with_network. Filed as: FB24895271: reservations and rules discarded when the last interface is removed FB24895264: the runtime forwarding calls fail on network-attached interfaces FB24895282: suggestion for a network state-change callback and a DHCP lease query by MAC Questions: Is losing reservations and rules when the network goes idle intended? Is holding an app-owned interface on the network (via vmnet_interface_start_with_network) so it never reaches zero interfaces a supported workaround, or does it risk other side effects?
Replies
1
Boosts
0
Views
292
Activity
4d
Supported lifecycle and termination guarantees for an embedded macOS XPC service
We are evaluating a lifecycle architecture for a local macOS application and would appreciate guidance on supported public APIs. Proposed architecture: A normally signed, non-root host application. One embedded XPC service with exactly one intended client. No application-created subprocesses inside the service. No privileged helper, persistent LaunchAgent, exported endpoints, private APIs, or reduced system security. One bounded operation per session. Failed or interrupted operations must not automatically be retried. Initial validation would use synthetic workloads only. Our current evaluation target is macOS 15.6 on Apple silicon, using the macOS 15.5 SDK. Please identify any relevant deployment-version limitations. The XPC overview (https://developer.apple.com/documentation/xpc) describes an embedded service as tied to its client's lifetime. We also understand that xpc_connection_cancel (https://developer.apple.com/documentation/xpc/xpc_connection_cancel(_:)) is asynchronous and non-preemptive; we are not treating connection cancellation as proof of service termination. We need clarification on these points: Client death and service startup Does the documented client-lifetime relationship cover client termination, including SIGKILL, during service startup before the first reply? Does it also cover an already running service that is blocked or stopped with SIGSTOP? Which behavior is guaranteed, and which timing or failure cases are intentionally unspecified? Timeout while the client remains alive What supported public mechanism should a normal application use to terminate its own unresponsive embedded service when an operation exceeds its deadline? We want to avoid PID enumeration, PID-reuse races, broad process-group signaling, and exporting a full task-control port. Is there a supported identity-bound termination mechanism? If not, what architecture does Apple recommend? A stopped or hung client remains alive, so we do not assume client-lifetime coupling handles that separate failure case. Observing termination Which public notification reliably identifies the exit of the particular service instance, as distinct from connection invalidation or a missing reply? Because launchd is the parent, the application cannot simply waitpid the service. Is reaping entirely launchd's responsibility, and what completion claim can the application legitimately make? Identity and required privileges Which public signing requirements, launch constraints, sandbox settings, or entitlements are necessary for this architecture? Please distinguish authentication before accepting work from constraints enforced before service code executes. We do not assume peer authentication also grants termination rights. Restart behavior After interruption, cancellation, client exit, or service failure, under what circumstances can launchd or subsequent XPC activity start a replacement service? What supported pattern prevents accidental resubmission or resumption of the same failed operation? We are not asking for hard real-time guarantees during kernel failure, or claiming that forced termination proves callback completion or explicit memory zeroization. If this combination of requirements is unsupported, identifying that boundary and the smallest supported architectural alternative would be a useful answer. Documentation references or a minimal public sample would be welcome.
Replies
3
Boosts
0
Views
131
Activity
4d
Restartable Sequences. What are they?
After scouring the XNU kernel source code, I came across restartable ranges [1]. They seem to be a task-level version of the the part of Linux's restartable sequences [2] for user requested synchronization [3] (akin to MEMBARRIER_CMD_RSEQ). Because of their differences, I would like to know more about how they work and what they are used for. From what I have gathered [4], they seem to be closer to RCU [5] that waits for eviction (as opposed to completion). But the fact that they are barely mentioned anywhere (see [4]) in the XNU source code I'd be really happy if you can point me to more information about them and how they compare to rseq (or rcu). What are the XNU devs planning on doing with them? [1] osfmk/kern/restartable.c: https://github.com/apple-oss-distributions/xnu/blob/f6217f8/osfmk/kern/restartable.c [2] https://criu.org/Restartable_Sequences [3] as opposed to (what I think is what makes rseq really cool) automatic eviction on preemption/CPU migration [4] there seems to be very little information online (including this forum) and the only places inside the XNU kernel source trees that aren't tests are in osfmk/kern/{thread,thread,sched_prim}.{c,h}, which doesn't really give much more information. [5] Read-Copy-Update: https://www.kernel.org/doc/html/latest/RCU/whatisRCU.html
Replies
1
Boosts
0
Views
88
Activity
4d
How to do line- and message-delimination
I'm trying to write a NWProtocolFramerImplementation class that will be channeled through a Framer wrapper. There are still some parts I need figuring out. For handleOutput(framer: message: messageLength: isComplete), what do the last two parameters do? Does isComplete refer to the end of the current conversation, or the entire connection? Why would we submit a messageLength if the data size should already be implied within message? If I parse by line breaks, is there a way to indicate if the latest line is the last of the current conversation, either input or output?
Replies
1
Boosts
0
Views
76
Activity
4d
Supported native alphabet navigation for CPListTemplate on iOS 27
We need to retain CarPlay's native A–Z button between the scroll arrows in an audio app. This is core navigation for an album/artist library. We use CPListSection(items:header:sectionIndexTitle:) with single-character labels. The sectionIndexTitle API is still documented and is not deprecated in the Xcode 27 SDK. We need the supported native implementation, not a custom picker. On a parked physical head unit with an iPhone running iOS 27, our app displays populated album rows and section headers but no A–Z. Apple Music displays A–Z on the same head unit. We do not know Apple Music's internal implementation. A standalone, public-API-only reproduction is prepared; its CarPlay scene code is included below. Each tab supplies four A/B/M/Z sections of ten synthetic rows. The variants are initially populated, updated after loading, the full section initializer, and securely archived and decoded sections. No network, authentication or artwork is required. The original app displays functioning native alphabet navigation on the iOS 26.5 CarPlay simulator. The public probe compiles. We cannot run an end-to-end iOS 27 CarPlay simulator session because Device Hub requires a physical device, as confirmed in developer forum thread 834440. Separately, an isolated local diagnostic hosted the native list renderer with CarPlay traits. Both runtimes receive four nonempty index labels and all 40 rows. On iOS 26.5 (23F77), its table data source returns A/B/M/Z. On iOS 27.0 (24A434), the attached UICollectionViewDiffableDataSource returns nil index titles. Both the full initializer and secure archive round-trip preserve titles but produce the same result. This diagnostic is not an end-to-end CarPlay session and does not establish the exact internals on the physical phone. A standard UIKit table supplied with index titles and CarPlay traits still displays the native A–Z button on the same iOS 27 runtime. The control itself still exists; the observed failure is the template-to-index connection. This control experiment is also hosted in a phone window, not a CarPlay session. A standard UIKit collection data source implementing indexTitles(for:) also shows index letters on this runtime; the unmodified template renderer's collection data source returns nil. We have not modified that renderer. Questions: Did iOS 27 move native CPListTemplate alphabet navigation to another API, configuration, or presentation requirement? What is the supported migration? If sectionIndexTitle remains the correct input, is this a known regression in the new list renderer, and what supported correction is available? How should third-party audio apps reproduce Apple Music's native alphabet navigation on iOS 27 without private API or replacing it with a custom control? Please provide a working public-API example or identify the relevant fix/version. Reproduction: use the audio CarPlay entitlement and configure CPTemplateApplicationScene with CarScene as its delegate. This is the scene code from the compiling standalone probe: import CarPlay import UIKit @MainActor func indexedSections() -> [CPListSection] { ["A", "B", "M", "Z"].map { letter in let items = (1...10).map { number in let item = CPListItem(text: "\(letter) Album \(number)", detailText: "Synthetic test entry") item.handler = { _, completion in completion() } return item } return CPListSection(items: items, header: letter, sectionIndexTitle: letter) } } final class CarScene: UIResponder, CPTemplateApplicationSceneDelegate { func templateApplicationScene(_ scene: CPTemplateApplicationScene, didConnect controller: CPInterfaceController) { let ready = CPListTemplate(title: "Ready", sections: indexedSections()) ready.tabTitle = "Ready" ready.tabImage = UIImage(systemName: "list.bullet") let updated = CPListTemplate(title: "Updated", sections: [CPListSection(items: [CPListItem(text: "Loading", detailText: nil)])]) updated.tabTitle = "Updated" updated.tabImage = UIImage(systemName: "arrow.clockwise") let full = CPListTemplate(title: "Full Init", sections: indexedSections().map { CPListSection(items: $0.items, header: $0.header ?? "", headerSubtitle: nil, headerImage: nil, headerButton: nil, sectionIndexTitle: $0.sectionIndexTitle) }) full.tabTitle = "Full Init" full.tabImage = UIImage(systemName: "list.bullet.rectangle") let decoded: CPListTemplate do { let sections = try indexedSections().map { section in let data = try NSKeyedArchiver.archivedData(withRootObject: section, requiringSecureCoding: true) guard let restored = try NSKeyedUnarchiver.unarchivedObject(ofClass: CPListSection.self, from: data) else { throw CocoaError(.coderReadCorrupt) } return restored } decoded = CPListTemplate(title: "Decoded", sections: sections) } catch { decoded = CPListTemplate(title: "Decode failed", sections: [CPListSection(items: [ CPListItem(text: "Section decoding failed", detailText: String(describing: error)) ])]) } decoded.tabTitle = "Decoded" decoded.tabImage = UIImage(systemName: "shippingbox") controller.setRootTemplate(CPTabBarTemplate(templates: [ready, updated, full, decoded]), animated: false) { _, _ in } Task { @MainActor in try? await Task.sleep(for: .seconds(2)) updated.updateSections(indexedSections()) } } }
Replies
0
Boosts
0
Views
58
Activity
4d
Offline Maps for App via MapKit
I’m building an iOS app using MapKit that allows users to create and navigate trails. I need offline map functionality, I was wondering if MapKit supports that. If not I was wondering if MapBox is a viable alternative to MapKit though I would prefer using MapKit. Thanks!
Replies
3
Boosts
3
Views
1.1k
Activity
4d
NSMenuItem.separator() appears as blank space in Finder Sync extension context menu
Hi, I’m developing a macOS Finder Sync extension and noticed that NSMenuItem.separator() does not appear to render as a standard separator line when used inside the menu returned from FIFinderSyncController. In a normal AppKit NSMenu, the separator renders as expected. However, when the same kind of menu is returned from the Finder Sync extension, the separator appears as a blank/full-height empty row rather than a thin dividing line. Example: override func menu(for menuKind: FIMenuKind) -> NSMenu { let menu = NSMenu(title: "") menu.addItem(NSMenuItem( title: "First Action", action: #selector(firstAction(_:)), keyEquivalent: "" )) menu.addItem(NSMenuItem.separator()) menu.addItem(NSMenuItem( title: "Second Action", action: #selector(secondAction(_:)), keyEquivalent: "" )) return menu } Expected result: The separator should render as a normal macOS menu separator line between the two menu items. Actual result: In Finder’s context menu, the separator is displayed as blank vertical space / an empty menu row. I understand that Finder Sync menus are rendered by Finder and may not support every NSMenuItem feature. However, NSMenuItem.separator() is a very standard way to visually group menu commands, so I wanted to ask: Is this a known limitation of Finder Sync extension menus? Is there a supported way to display a real separator line in Finder Sync context menus? Should this be filed as a Feedback Assistant issue against Finder Sync / AppKit? I’m trying to avoid fake separators such as disabled menu items with "────" as the title, since that does not feel native and may not behave well with different fonts, accessibility settings, or appearance modes. Thanks!
Replies
1
Boosts
1
Views
581
Activity
4d
SwiftData with CloudKit Error: Error updating background task request
Hi, Overview I have a SwiftData project which automatically syncs with CloudKit. When I run the app, I see the following error in Xcode logs. Error updating background task request: Error Domain=BGSystemTaskSchedulerErrorDomain Code=3 "(null)" My attempt I can enable Background processing (under Signing & Capabilities > Background modes), but I don't know the BGTaskSchedulerPermittedIdentifiers to add in the Info.plist Questions How can I resolve this? If I should enable background processing, what are the BGTaskSchedulerPermittedIdentifiers to add in Info.plist?
Replies
19
Boosts
0
Views
2.3k
Activity
4d