Foundation

RSS for tag

Access essential data types, collections, and operating-system services to define the base layer of functionality for your app using Foundation.

Posts under Foundation tag

200 Posts

Post

Replies

Boosts

Views

Activity

Networking Resources
General: Forums subtopic: App & System Services > Networking TN3151 Choosing the right networking API Networking Overview document — Despite the fact that this is in the archive, this is still really useful. TLS for App Developers forums post Choosing a Network Debugging Tool documentation WWDC 2019 Session 712 Advances in Networking, Part 1 — This explains the concept of constrained networking, which is Apple’s preferred solution to questions like How do I check whether I’m on Wi-Fi? TN3135 Low-level networking on watchOS TN3179 Understanding local network privacy Adapt to changing network conditions tech talk TCP and UDP ports used by Apple software products support article Understanding Also-Ran Connections forums post Extra-ordinary Networking forums post Foundation networking: Forums tags: Foundation, CFNetwork URL Loading System documentation — NSURLSession, or URLSession in Swift, is the recommended API for HTTP[S] on Apple platforms. Moving to Fewer, Larger Transfers forums post Testing Background Session Code forums post Network framework: Forums tag: Network Network framework documentation — Network framework is the recommended API for TCP, UDP, and QUIC on Apple platforms. WWDC 2025 Session 250 Use structured concurrency with Network framework — This is a great introduction to the new Network framework API introduced in appleOS 2026. Building a custom peer-to-peer protocol sample code (aka TicTacToe) Implementing netcat with Network Framework sample code (aka nwcat) Configuring a Wi-Fi accessory to join a network sample code Moving from Multipeer Connectivity to Network Framework forums post NWEndpoint History and Advice forums post Wi-Fi (general): How to modernize your captive network developer news post Wi-Fi Fundamentals forums post Filing a Wi-Fi Bug Report forums post Working with a Wi-Fi Accessory forums post — This is part of the Extra-ordinary Networking series. Wi-Fi (iOS): TN3111 iOS Wi-Fi API overview technote Wi-Fi Aware framework documentation Building peer-to-peer apps sample code WirelessInsights framework documentation iOS Network Signal Strength forums post Network Extension Resources Wi-Fi on macOS: Forums tag: Core WLAN Core WLAN framework documentation Secure networking: Forums tags: Security Apple Platform Security support document Preventing Insecure Network Connections documentation — This is all about App Transport Security (ATS). WWDC 2017 Session 701 Your Apps and Evolving Network Security Standards [1] — This is generally interesting, but the section starting at 17:40 is, AFAIK, the best information from Apple about how certificate revocation works on modern systems. WWDC 2025 Session 314 Get ahead with quantum-secure cryptography Available trusted root certificates for Apple operating systems support article Requirements for trusted certificates in iOS 13 and macOS 10.15 support article About upcoming limits on trusted certificates support article Apple’s Certificate Transparency policy support article What’s new for enterprise in iOS 18 support article — This discusses new key usage requirements. Prepare your network environment for stricter security requirements support article — This is primarily of interest to folks developing management software, for example, an MDM server. Technote 2232 HTTPS Server Trust Evaluation Technote 2326 Creating Certificates for TLS Testing QA1948 HTTPS and Test Servers Miscellaneous: More network-related forums tags: 5G, QUIC, Bonjour On FTP forums post Using the Multicast Networking Additional Capability forums post Investigating Network Latency Problems forums post Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = "eskimo" + "1" + "@" + "apple.com" [1] This video is no longer available from Apple, but the URL should help you locate other sources of this info.
0
0
6.6k
Sep ’26
Has the iOS system adapted to the time zone policy of British Columbia, Canada?
Has the iOS system adapted to the time zone policy of British Columbia, Canada? If the iPhone's system time zone is set to America/Edmonton, what result should the code below return after adapting? [[NSTimeZone systemTimeZone] isDaylightSavingTime] [[NSTimeZone systemTimeZone] secondsFromGMT] [[NSTimeZone systemTimeZone] daylightSavingTimeOffset]
1
0
56
17h
iOS System Language does not change to Albanian or Macedonian
Hello, I’m trying to determine whether Albanian (sq) and Macedonian (mk) are supported as full system display languages on iOS. When I go to: Settings → General → Language & Region → iPhone Language Albanian and Macedonian are not available as system languages. However, both languages appear to have support in other parts of iOS. For example, Apple currently lists Albanian and Macedonian among the supported QuickType keyboard languages. 
https://www.apple.com/in/ios/feature-availability/?utm_source=chatgpt.com I have tested this behavior on: - iOS 16.7 - iOS 17.5 - iOS 26.6.1 - iOS 27.0.1 In all tested versions, I cannot change the iPhone system/display language to Albanian or Macedonian. I would like to clarify: 1. Are Albanian (sq) and Macedonian (mk) officially supported as iOS system/display languages? 2. If they are not supported, is there an official Apple documentation page listing the supported iOS system languages? 3. Is there any API or mechanism available to an app to determine whether a language is supported as a system UI language, as opposed to being supported only for keyboards or other language features? 4. Are there plans to add Albanian and Macedonian as full iOS system languages? I understand that app localization is separate from the iOS system language. Apple documentation explains that an app's localization is determined from the user's preferred languages and the localizations provided by the app. 
https://developer.apple.com/library/archive/qa/qa1828/_index.html?utm_source=chatgpt.com https://developer.apple.com/documentation/foundation/locale/preferredlanguages?changes=_11&utm_source=chatgpt.com I’m specifically asking about Apple's own iOS system UI, not localization of a third-party application. Expected: Selecting Albanian or Macedonian as the iPhone language should make the iOS system UI appear in that language, if the language is supported. Actual: Albanian and Macedonian cannot be selected as the iPhone's system/display language. Could someone from Apple confirm whether this is expected behavior and whether these languages are currently unsupported as full iOS system languages? Thank you.
3
0
103
4d
Title: Security-scoped folder bookmarks after rename or Trash: APFS vs exFAT/FAT32
I’m developing a sandboxed macOS app that needs persistent, read-only access to a user-selected folder. We are observing different behaviour between APFS and FAT32/exFAT after renaming the folder or moving it to Trash. The main problem is that the app can still track the folder while running, but cannot reliably restore the connection or identify its location after relaunch. Environment macOS 27.0.1 (26A434) Xcode 27.1 (27A9269) App Sandbox and user-selected file access enabled Folder selection through SwiftUI fileImporter Bookmark creation: .withSecurityScope and .securityScopeAllowOnlyReadAccess Bookmark resolution: .withSecurityScope The selected items are ordinary folders, not volume roots. Filesystem comparison APFS: the tested workflows appear to work as expected, including restoration after relaunch. exFAT: we have reproduced both bookmark renewal failure after a rename and loss of the “in Trash” classification after relaunch. FAT32: we have observed automatic bookmark renewal failures after a rename. The detailed debugger trace and Trash reproduction below were collected specifically on exFAT. Rename reproduction Select a folder through the system picker. Create and persist a read-only security-scoped bookmark. Resolve the bookmark and start accessing the resolved URL. Retain that URL and keep its security scope active throughout monitoring. Rename the folder in Finder while the app remains running. Attempt to create an updated bookmark for the same folder. The monitor retains an O_EVTONLY directory descriptor. After the rename, F_GETPATH returns the correct new pathname, and runtime identity checks still match the monitored folder. However, creating a bookmark using a URL reconstructed from that new pathname fails. Calling startAccessingSecurityScopedResource() on the reconstructed URL returns false, while the original resolved URL’s scope remains active. The bookmark creation call uses: url.bookmarkData(options: [.withSecurityScope, .securityScopeAllowOnlyReadAccess], includingResourceValuesForKeys: nil, relativeTo: nil) Exact failure measured on exFAT LLDB shows that Foundation’s internal open(): Receives the correct new pathname. Uses flags 0, meaning O_RDONLY. Immediately returns -1. Sets errno to 1, EPERM, read immediately on the same thread. The correlated Foundation error reports: NSCocoaErrorDomain Code 256 Could not open() the item: [1: Operation not permitted] This is a failed read-only open during bookmark creation. We have not established which policy causes the EPERM. A log stream filtered for com.apple.sandbox.reporting / violation produced no report during reproduction. We understand that this does not exclude sandbox involvement. We also tested a native CFURL file reference retained from before the rename. It continued to follow the folder and match its identity, but security-scoped bookmark creation from that reference also failed. Reselection works, but requires user intervention Selecting the same renamed folder again through fileImporter allows creation of a new bookmark. That bookmark resolves, is not stale, and restores access after relaunch. Without reselection before quitting, the previously saved bookmark does not restore access to the renamed folder on the next launch. The app reports it as unavailable. Separate Trash reproduction on exFAT Move the monitored folder to Trash using Finder while the app is running. The app correctly identifies the folder as being in Trash. Quit the app, leaving the folder in Trash. Relaunch: the app reports the folder as unavailable. The folder remains in Trash on the same exFAT volume. It has not been restored or permanently deleted. We also encountered failures when inspecting the Trash relationship using FileManager.getRelationship(_:of:in:toItemAt:) with .trashDirectory. We have not established whether these observations share the cause of the rename failure. Questions What is the supported public-API approach to preserve security-scoped folder access across an external rename on exFAT/FAT32, including after relaunch? What should bookmark resolution return for a folder moved to Trash, and how should a sandboxed app distinguish that condition from an unavailable resource after relaunch? Are these expected filesystem limitations, problems in our API usage, or behaviours that should be reported as macOS bugs? What additional diagnostics would help distinguish them? Ideally, the solution would preserve the original folder authorization without requiring repeated reselection or access to the parent directory or entire volume. I have read Accessing files from the macOS App Sandbox. I also found this discussion of bookmark failures involving exFAT, but it concerns volume roots and an earlier macOS release, so I’m not assuming it explains our case.
4
0
206
1w
APFS worse than HFS for SSD file enumeration
A user of my app reported that it is slower when enumerating a large number of files on APFS compared to HFS+. Online I can only find information that this is expected for rotational hard disks, but apparently APFS should be optimized for SSDs and hence the observed performance doesn't make sense. I used the code below to enumerate a folder hierarchy with about 100'000 files. I ran it several times on both APFS and HFS+ to minimize differences due to caching. On APFS the last runs took about 4.5 seconds, while on HFS+ the last runs took about 1.3 seconds. How can this big difference be explained? Is APFS really slower than HFS+ when enumerating files on SSDs? let openPanel = NSOpenPanel() openPanel.canChooseDirectories = true openPanel.canChooseFiles = false if openPanel.runModal() == .cancel { return } let resourceKeys: [URLResourceKey] = [.isDirectoryKey, .fileSizeKey, .creationDateKey, .contentModificationDateKey, .fileIdentifierKey, .isSymbolicLinkKey, .isHiddenKey, .isUserImmutableKey, .attributeModificationDateKey] let enumerator = FileManager.default.enumerator(at: openPanel.urls[0], includingPropertiesForKeys: resourceKeys) { url, error in print(error) return true }! let date = Date() var i = 0 for case let url as URL in enumerator { let _ = try? url.resourceValues(forKeys: Set(resourceKeys)) i += 1 if i % 10000 == 0 { print(i) } } print(-date.timeIntervalSinceNow)
0
0
135
1w
Inconsistent caseInsensitiveCompare behavior
(lldb) p [@"ΗΙzzz" caseInsensitiveCompare:@"ᾚabc"] (long long) -1 (lldb) p [@"ᾚabc" caseInsensitiveCompare:@"ΗΙzzz"] (long long) -1 Note the unicode char in the second string. The results can't be both -1, afaik, if one is -1 the other one should be +1. This causes inconsistent indexing in a sorted array resulting in obscure crashes of my app. Am I doing something wrong? Tested on iOS 27 and macOS 26.6.
6
0
231
1w
NSURL appends '..' path component on returned url from URLByDeletingLastPathComponent which seems to contradict the documentation
The documentation for URLByDeletingLastPathComponent states the following: If the receiver’s URL represents the root path, this property contains a copy of the original URL. Otherwise, if the original URL has only one path component, this property contains the empty string. So maybe this is new in Foundation with the Golden Gate or maybe I just noticed this but the documentation above doesn't seem to be true. This will create an infinite loop: NSURL *fileURL = [NSURL fileURLWithPath:@"/Users/MyUsername/Desktop/AFolder" isDirectory:YES]; NSLog(@"%@",fileURL); NSURL *ancestorURL = fileURL.URLByDeletingLastPathComponent; while (ancestorURL != nil) { NSURL *nextAncestor = ancestorURL.URLByDeletingLastPathComponent; NSLog(@"Next: %@",nextAncestor); if ([nextAncestor isEqual:ancestorURL]) { NSLog(@"Hit the root - got a copy of the same url"); break; } else if ([nextAncestor.absoluteString isEqualToString:@""] || [nextAncestor.path isEqualToString:@""]) { NSLog(@"Empty string means we had only 1 path component."); break; } else if (nextAncestor == nil) { NSLog(@"Got nil"); break; } ancestorURL = nextAncestor; } The infinite loop can be avoided by adding the following condition: else if (nextAncestor.pathComponents.count == 1) { // One path component. NSURL *sneakPeak = nextAncestor.URLByDeletingLastPathComponent; NSLog(@"%lu",sneakPeak.pathComponents.count); // Logs 2. break; } When you get to one path component URLByDeletingLastPathComponent appends a .. path component rather than deleting a path component or returning a copy of the receiver or a url with an empty string.. If this sounds like a bug let me know. When I call URLByDeletingLastPathComponent on a url with only one path component I'd like to get nil. I think that would be a cleaner design.
5
0
567
2w
Does identifierForVendor (IDFV) change after transferring an app to another Apple Developer account?
Title: Does identifierForVendor (IDFV) change after transferring an app to another Apple Developer account? We are planning to transfer an existing App Store app from one Apple Developer account/team to another using App Transfer. The app currently uses: UIDevice.current.identifierForVendor as one of the identifiers sent to our backend. We would like to confirm the exact behavior of identifierForVendor after the app is transferred to the recipient developer account. Our scenario is: The app is currently published under Developer Team A. Existing users already have the app installed on their devices. We transfer the app to Developer Team B through App Store Connect. Developer Team B creates new certificates/provisioning profiles and publishes a new version of the same app. Existing users update the app normally from the App Store, without uninstalling it. Questions: After an existing user updates from the last version published by Team A to the first version published by Team B, will UIDevice.current.identifierForVendor remain the same, or will it be regenerated? Is the vendor used to calculate IDFV associated with: the App Store app record, the Bundle ID, the Team ID, the App ID Prefix, the developer organization/vendor, or some other value? Does App Transfer itself cause IDFV to change, or does the value only change under specific conditions such as changing the organization name or uninstalling all apps from the same vendor? If IDFV changes after App Transfer, does Apple provide any official migration or mapping mechanism that allows the backend to associate the old IDFV with the new IDFV? For example, Sign in with Apple provides a user migration mechanism when transferring an app between developer teams. Is there any equivalent mechanism for identifierForVendor? Is there any difference between: users who update the app directly after the transfer, and users who uninstall the old version and reinstall the app after the transfer? We have reviewed the documentation for identifierForVendor and App Transfer, but we could not find an explicit statement describing the IDFV behavior specifically for an App Transfer between two different developer teams. Our main concern is maintaining backend device associations for existing users after the transfer. We would appreciate an official clarification on whether IDFV continuity is guaranteed across App Transfer, and if not, what migration strategy Apple recommends.
1
0
323
3w
How does font caching / resources for each app work?
I'm a font developer. In the development process, I will revise a font and overwrite the OTF file that is currently enabled (registered) with macOS. If I then launch an app, it will immediately use the revised version of the font; while apps that are already loaded will continue to use the old version. This suggests that each app is loading new and separate font data, rather than getting it from some existing cache in memory. Yet macOS does have a "font cache" of some sort. Some apps, like TextEdit, seem to only load the fonts that they need to use. However, other apps, like Pages, load every enabled (registered) font on the OS!! (According to the Open Files list in Activity Monitor.) Given that /System/Library/Fonts/ is 625 Mb, and we can't disable any of it, isn't that a lot of data to be repeating? How many fonts is too many fonts? I can't find much documentation about the process.
7
0
2.0k
3w
Xcode Version 27 Localised strings not recognised
Hello When compiling a project containing localised file strings for dictionaries with the new release Xcode version 27, I receive an error as the compiler expect a plist instead of the string! validation failed: Couldn't parse property list because the input data was in an invalid format The Xcode version 26… did work fine I did file a Feedback Assistant FB24806196 Using a MacBook Air Apple silicon
1
0
166
3w
NSMetaDataQuery and MD-Spotlight Backed APIs Suddenly Stop Working
I'm testing code that uses NSMetadataQuery and I noticed some odd behavior. I run a query where the search scope is set to my Desktop directory. The predicate is set to search for a file name that contains 'we' (display name to be precise: kMDItemDisplayName). And I get no results. So I stop the app from Xcode then I create a new folder on the Desktop and name it we exactly. Then I rerun my app and start the query again - still no results. Unfortunately none of the Spotlight based APIs I'm using report errors. There is no delegate method -queryDidFailWithError: or anything like that. So in another place my app uses the lower level MD prefixed APIs in Core Services to read file metadata and I notice that those APIs are failing as well. Specifically I try to load metadata for a PNG image. I create an MDItemRef via MDItemCreateWithURL (and I do get an MDItemRef). Then I call MDItemCopyAttributes with the MDItemRef and an array of metadata attribute names: CFDictionaryRef fetchedData = MDItemCopyAttributes(mdItem, attributeNames); I step through it in the debugger and fetchedData is NULL. Since there is no error handling APIs available for any of this my app just silently fails. I have Console.app open when I step through MDItemCopyAttributes call in the debugger and this logs out every time: com.apple.spotlightserver Bad checksum on fetch attributes reply from store, 0x123ea456.... FWIW I do not have Spotlight indexing turned off on my system. Also jumping to Finder I'm experiencing the same failures (metadata isn't populating and the Desktop search for we produces no results). Actually on further inspection it looks like all searches are producing no results. Spotlight appears to be in a broken state system wide. I'm pretty sure a system restart will 'fix' it - until it starts occurring again. But for obvious reasons I'd like to avoid releasing a feature in my app that results in this kind of experience. Is there anything I can do on my end to workaround or avoid this issue? And tips or advice would be greatly appreciated.
2
0
439
3w
Loading User Installed VST3 Plugins While Remaining Sandboxed on MacOS
Hi, I’m developing a native macOS music app intended for the Mac App Store. We already support Audio Units and are investigating VST3 instrument and effect hosting on Apple Silicon. Users would install plugins themselves, typically in: /Library/Audio/Plug-Ins/VST3 ~/Library/Audio/Plug-Ins/VST3 The app would load these third-party plugin bundles using public APIs, such as CFBundleLoadExecutableAndReturnError. Plugins may be signed by developers with different Team IDs. Our app would not download or install them. Is there a supported way to load and execute these bundles while the hosting process remains sandboxed throughout? If so, which APIs and entitlements should we use? Specifically, I’m trying to distinguish permission to read a plugin bundle from permission to load its executable code. Would user selected folder access and security scoped bookmarks cover the sandbox access requirements, or is another mechanism needed? I understand that com.apple.security.cs.disable-library-validation addresses loading code signed by other developers, but does not itself grant sandbox file access. We cannot rely on an Audio Unit compatibility exception that disables the host’s sandbox. App Review Guideline 3.1.1 (https://developer.apple.com/app-store/review/guidelines/#in-app-purchase) explicitly allows Mac App Store apps to host plugins enabled outside the App Store. I’m looking for the supported technical approach under App Sandbox, rather than preapproval for our app. We’re checking this before implementation, so we don’t yet have a failing reproducer. Any relevant documentation, sample code or existing discussion would be appreciated. Thanks, Ben
1
0
487
3w
Is there an API for detecting if NSMetadataQuery is unavailable for a given URL (as a search scope)?
If the user prohibits Spotlight in System Settings for a given directory and I set that URL as one of the search scopes on an NSMetadataQuery- I believe the query will return no results. Is there an API for detecting Spotlight unavailability? Ideally I would like to display something in the UI for this kind of situation to explain why a feature built on top of this API is not working.
0
0
278
Sep ’26
iOS 26 AX: _UITabButtonAccessibility accessibilityValue → safeSwiftValueForKey → swift_abortRetainUnowned on cold launch (app frames: main only)
We are seeing a hard main-thread abort on iOS 26 during cold launch when VoiceOver (or another accessibility client) is active. about 1–7 seconds after process start. The crashing thread essentially shows only main from the app; the fatal path is entirely in system frameworks. What happens is that UIAccessibility asks for an accessibility value, UIKit.axbundle handles it (on iOS 26.5 we exact-match-symbolicate this to -[_UITabButtonAccessibility accessibilityValue] + 120), then AXCoreUtilities safeSwiftValueForKey reflects a Swift object via Mirror / AttributeGraph. While copying an unowned field, the referent is already gone, so libswiftCore calls swift_abortRetainUnowned and the process dies. Not finding unowned in app source does not contradict this: the reflected object can live in system or SDK Swift state. OS versions in the corpus: iOS 26.5 (23F77), 26.6 (23G71), and 26.6.1 (23G83). All reports load UIKit.axbundle. Launch-to-crash gaps range from roughly 1.4s to 7.3s. Most 26.6 samples share UIKit.axbundle binary UUID 387c6473…; we did not have matching Device Support for that build locally. One iOS 26.5 sample has UIKit.axbundle binary UUID dca69975… and AXCoreUtilities 78a7c163…, both exactly matching local Device Support, so atos on that sample is trustworthy. On that iOS 26.5 sample (filename redacted), the symbolicated path is: VoiceOver / AX → UIAccessibility (_iosAccessibilityAttributeValue → _accessibilityAXAttributedValue → _accessibilityPotentiallyAttributedValueForNonAttributedSelector) → UIKit.axbundle -[_UITabButtonAccessibility accessibilityValue] + 120 → AXCoreUtilities (_AXSafeSwiftValueForKeyTm → safeSwiftValueForKey → _visitValueWithReflection) → AttributeGraph (AGTypeApplyFields2::Visitor::visit_field) → libswiftCore (swift_reflectionMirror_subscript → copyUnownedFieldContents → swift_unknownObjectUnownedLoadStrong → swift_abortRetainUnowned) → App: main only Frame 32 math: runtime 0x2be49b130, slide base 0x2be3cf000, offset 0xCC130 → _UITabButtonAccessibility accessibilityValue + 120. Questions for anyone hitting the same stack: 1.Is there already an Apple Feedback / radar for safeSwiftValueForKey + swift_abortRetainUnowned on iOS 26? crash_ios265_redacted.txt
0
0
641
Aug ’26
Can't get a scoped resource URL from drag and drop
Hi, My Mac app allows a customer to drag and drop a file package onto a SwiftUI view. I can't seem to find a way to successfully call .startAccessingSecurityScopedResource() with the file/dir that was dropped into the view. I put together a simple test app. Here is the code: struct ContentView: View { @State var isTargetedForDrop: Bool = false var body: some View { VStack { Image(systemName: "globe") .imageScale(.large) .foregroundStyle(.tint) Text("Hello, world!") Rectangle() .stroke(Color.gray) .onDrop(of: [UTType.fileURL], isTargeted: $isTargetedForDrop) { providers in guard let provider = providers.first(where: { $0.hasItemConformingToTypeIdentifier(UTType.fileURL.identifier) }) else { return false } provider.loadItem(forTypeIdentifier: UTType.fileURL.identifier, options: nil) { item, error in if let error = error { print("Drop load error: \(error)") return } if let url = item as? URL { print("Dropped file URL: \(url)") } else if let data = item as? Data, let url = URL(dataRepresentation: data, relativeTo: nil) { print("Dropped file URL (from data): \(url)") let access = url.startAccessingSecurityScopedResource() if access { print("Successfully accessed file at URL: \(url)") } else { print("Failed to access file at URL: \(url)") } url.stopAccessingSecurityScopedResource() } else { print("Unsupported dropped item: \(String(describing: item))") } } return true } } .padding() } } When I drop a file package into this view I see, "Failed to access file at URL: <the_full_file_path>" I'm running Xcode 26 on macOS 26.
3
1
946
Aug ’26
Concurrent upload tasks over HTTP/2: request bodies sent strictly sequentially (no stream interleaving) — starved tasks fail behind slow-POST protection
We maintain a large file-sync app. After our upload endpoint moved to HTTP/2, we found that when multiple NSURLSessionUploadTasks run concurrently, all tasks send their request headers immediately (multiplexed on a single connection — confirmed identical localPort via URLSessionTaskMetrics), but request bodies are transmitted essentially one task at a time: while one task's body saturates the uplink, the other tasks send zero body bytes for the entire duration (countOfBytesSent == 0). This reproduces with both background sessions (BackgroundUploadTask) and default sessions (LocalUploadTask), on Wi-Fi and cellular. iOS 26.5, Xcode 26.3, tasks created with uploadTask(with:fromFile:), multipart POST. This becomes a hard failure behind a load balancer with slow-POST (RUDY) protection: requests whose first body KB doesn't arrive within 5s are rejected with 408. The starved tasks fail even though the network is healthy. For comparison, OkHttp on Android writes bodies in interleaved 16KB DATA frames under identical conditions, so all streams pass the first-KB check. Metrics excerpt (4 concurrent uploads, one h2 connection): task 1: duration 18.7s, sent 180MB (full line rate) task 2: duration 22.8s, sent 43MB (transmitted only after task 1 finished) task 3: duration 46.0s, sent 247MB (after task 2) task 4: duration 5.2s, sent 0 bytes → 408 from the gateway In one run a starved stream sent exactly 65,536 bytes (the default initial stream window) and then stalled. Questions: Is this sender-side scheduling (no round-robin between streams' DATA frames) the expected CFNetwork behavior? Does URLSessionTask.priority influence HTTP/2 stream weighting for upload bodies? Is there any other way to influence bandwidth sharing between concurrent uploads? Is there any supported way to opt out of HTTP/2 (constrain ALPN to HTTP/1.1) or cap concurrent streams per connection from the client side? We believe there isn't, but would like to confirm. What is the recommended pattern for concurrent large uploads in this situation? Filed as FB24062619 with full sanitized metrics attached. Happy to provide more data.
3
0
1.2k
Aug ’26
Networking Resources
General: Forums subtopic: App & System Services > Networking TN3151 Choosing the right networking API Networking Overview document — Despite the fact that this is in the archive, this is still really useful. TLS for App Developers forums post Choosing a Network Debugging Tool documentation WWDC 2019 Session 712 Advances in Networking, Part 1 — This explains the concept of constrained networking, which is Apple’s preferred solution to questions like How do I check whether I’m on Wi-Fi? TN3135 Low-level networking on watchOS TN3179 Understanding local network privacy Adapt to changing network conditions tech talk TCP and UDP ports used by Apple software products support article Understanding Also-Ran Connections forums post Extra-ordinary Networking forums post Foundation networking: Forums tags: Foundation, CFNetwork URL Loading System documentation — NSURLSession, or URLSession in Swift, is the recommended API for HTTP[S] on Apple platforms. Moving to Fewer, Larger Transfers forums post Testing Background Session Code forums post Network framework: Forums tag: Network Network framework documentation — Network framework is the recommended API for TCP, UDP, and QUIC on Apple platforms. WWDC 2025 Session 250 Use structured concurrency with Network framework — This is a great introduction to the new Network framework API introduced in appleOS 2026. Building a custom peer-to-peer protocol sample code (aka TicTacToe) Implementing netcat with Network Framework sample code (aka nwcat) Configuring a Wi-Fi accessory to join a network sample code Moving from Multipeer Connectivity to Network Framework forums post NWEndpoint History and Advice forums post Wi-Fi (general): How to modernize your captive network developer news post Wi-Fi Fundamentals forums post Filing a Wi-Fi Bug Report forums post Working with a Wi-Fi Accessory forums post — This is part of the Extra-ordinary Networking series. Wi-Fi (iOS): TN3111 iOS Wi-Fi API overview technote Wi-Fi Aware framework documentation Building peer-to-peer apps sample code WirelessInsights framework documentation iOS Network Signal Strength forums post Network Extension Resources Wi-Fi on macOS: Forums tag: Core WLAN Core WLAN framework documentation Secure networking: Forums tags: Security Apple Platform Security support document Preventing Insecure Network Connections documentation — This is all about App Transport Security (ATS). WWDC 2017 Session 701 Your Apps and Evolving Network Security Standards [1] — This is generally interesting, but the section starting at 17:40 is, AFAIK, the best information from Apple about how certificate revocation works on modern systems. WWDC 2025 Session 314 Get ahead with quantum-secure cryptography Available trusted root certificates for Apple operating systems support article Requirements for trusted certificates in iOS 13 and macOS 10.15 support article About upcoming limits on trusted certificates support article Apple’s Certificate Transparency policy support article What’s new for enterprise in iOS 18 support article — This discusses new key usage requirements. Prepare your network environment for stricter security requirements support article — This is primarily of interest to folks developing management software, for example, an MDM server. Technote 2232 HTTPS Server Trust Evaluation Technote 2326 Creating Certificates for TLS Testing QA1948 HTTPS and Test Servers Miscellaneous: More network-related forums tags: 5G, QUIC, Bonjour On FTP forums post Using the Multicast Networking Additional Capability forums post Investigating Network Latency Problems forums post Share and Enjoy — Quinn “The Eskimo!” @ Developer Technical Support @ Apple let myEmail = "eskimo" + "1" + "@" + "apple.com" [1] This video is no longer available from Apple, but the URL should help you locate other sources of this info.
Replies
0
Boosts
0
Views
6.6k
Activity
Sep ’26
I need a iOS dev team for
A Apple Music application model that I submitted for this project account, was accepted, but I’m not a developer or designer. I am a musician/ producer. This will be an exclusive Apple ONLY app. due to the actual features. IOS, MacOS drivers, DAW, wallet, graphics, NFT’s. designer developers, if you love building master code LETS GO….
Replies
1
Boosts
0
Views
39
Activity
8h
Apple Developer Account verification
It has been a week now since subscribing for the Apple developer account, but my account is still pending. I sent emails to Apple developer support, but no replies. Please, I need help
Replies
0
Boosts
0
Views
51
Activity
9h
Has the iOS system adapted to the time zone policy of British Columbia, Canada?
Has the iOS system adapted to the time zone policy of British Columbia, Canada? If the iPhone's system time zone is set to America/Edmonton, what result should the code below return after adapting? [[NSTimeZone systemTimeZone] isDaylightSavingTime] [[NSTimeZone systemTimeZone] secondsFromGMT] [[NSTimeZone systemTimeZone] daylightSavingTimeOffset]
Replies
1
Boosts
0
Views
56
Activity
17h
iOS System Language does not change to Albanian or Macedonian
Hello, I’m trying to determine whether Albanian (sq) and Macedonian (mk) are supported as full system display languages on iOS. When I go to: Settings → General → Language & Region → iPhone Language Albanian and Macedonian are not available as system languages. However, both languages appear to have support in other parts of iOS. For example, Apple currently lists Albanian and Macedonian among the supported QuickType keyboard languages. 
https://www.apple.com/in/ios/feature-availability/?utm_source=chatgpt.com I have tested this behavior on: - iOS 16.7 - iOS 17.5 - iOS 26.6.1 - iOS 27.0.1 In all tested versions, I cannot change the iPhone system/display language to Albanian or Macedonian. I would like to clarify: 1. Are Albanian (sq) and Macedonian (mk) officially supported as iOS system/display languages? 2. If they are not supported, is there an official Apple documentation page listing the supported iOS system languages? 3. Is there any API or mechanism available to an app to determine whether a language is supported as a system UI language, as opposed to being supported only for keyboards or other language features? 4. Are there plans to add Albanian and Macedonian as full iOS system languages? I understand that app localization is separate from the iOS system language. Apple documentation explains that an app's localization is determined from the user's preferred languages and the localizations provided by the app. 
https://developer.apple.com/library/archive/qa/qa1828/_index.html?utm_source=chatgpt.com https://developer.apple.com/documentation/foundation/locale/preferredlanguages?changes=_11&utm_source=chatgpt.com I’m specifically asking about Apple's own iOS system UI, not localization of a third-party application. Expected: Selecting Albanian or Macedonian as the iPhone language should make the iOS system UI appear in that language, if the language is supported. Actual: Albanian and Macedonian cannot be selected as the iPhone's system/display language. Could someone from Apple confirm whether this is expected behavior and whether these languages are currently unsupported as full iOS system languages? Thank you.
Replies
3
Boosts
0
Views
103
Activity
4d
Title: Security-scoped folder bookmarks after rename or Trash: APFS vs exFAT/FAT32
I’m developing a sandboxed macOS app that needs persistent, read-only access to a user-selected folder. We are observing different behaviour between APFS and FAT32/exFAT after renaming the folder or moving it to Trash. The main problem is that the app can still track the folder while running, but cannot reliably restore the connection or identify its location after relaunch. Environment macOS 27.0.1 (26A434) Xcode 27.1 (27A9269) App Sandbox and user-selected file access enabled Folder selection through SwiftUI fileImporter Bookmark creation: .withSecurityScope and .securityScopeAllowOnlyReadAccess Bookmark resolution: .withSecurityScope The selected items are ordinary folders, not volume roots. Filesystem comparison APFS: the tested workflows appear to work as expected, including restoration after relaunch. exFAT: we have reproduced both bookmark renewal failure after a rename and loss of the “in Trash” classification after relaunch. FAT32: we have observed automatic bookmark renewal failures after a rename. The detailed debugger trace and Trash reproduction below were collected specifically on exFAT. Rename reproduction Select a folder through the system picker. Create and persist a read-only security-scoped bookmark. Resolve the bookmark and start accessing the resolved URL. Retain that URL and keep its security scope active throughout monitoring. Rename the folder in Finder while the app remains running. Attempt to create an updated bookmark for the same folder. The monitor retains an O_EVTONLY directory descriptor. After the rename, F_GETPATH returns the correct new pathname, and runtime identity checks still match the monitored folder. However, creating a bookmark using a URL reconstructed from that new pathname fails. Calling startAccessingSecurityScopedResource() on the reconstructed URL returns false, while the original resolved URL’s scope remains active. The bookmark creation call uses: url.bookmarkData(options: [.withSecurityScope, .securityScopeAllowOnlyReadAccess], includingResourceValuesForKeys: nil, relativeTo: nil) Exact failure measured on exFAT LLDB shows that Foundation’s internal open(): Receives the correct new pathname. Uses flags 0, meaning O_RDONLY. Immediately returns -1. Sets errno to 1, EPERM, read immediately on the same thread. The correlated Foundation error reports: NSCocoaErrorDomain Code 256 Could not open() the item: [1: Operation not permitted] This is a failed read-only open during bookmark creation. We have not established which policy causes the EPERM. A log stream filtered for com.apple.sandbox.reporting / violation produced no report during reproduction. We understand that this does not exclude sandbox involvement. We also tested a native CFURL file reference retained from before the rename. It continued to follow the folder and match its identity, but security-scoped bookmark creation from that reference also failed. Reselection works, but requires user intervention Selecting the same renamed folder again through fileImporter allows creation of a new bookmark. That bookmark resolves, is not stale, and restores access after relaunch. Without reselection before quitting, the previously saved bookmark does not restore access to the renamed folder on the next launch. The app reports it as unavailable. Separate Trash reproduction on exFAT Move the monitored folder to Trash using Finder while the app is running. The app correctly identifies the folder as being in Trash. Quit the app, leaving the folder in Trash. Relaunch: the app reports the folder as unavailable. The folder remains in Trash on the same exFAT volume. It has not been restored or permanently deleted. We also encountered failures when inspecting the Trash relationship using FileManager.getRelationship(_:of:in:toItemAt:) with .trashDirectory. We have not established whether these observations share the cause of the rename failure. Questions What is the supported public-API approach to preserve security-scoped folder access across an external rename on exFAT/FAT32, including after relaunch? What should bookmark resolution return for a folder moved to Trash, and how should a sandboxed app distinguish that condition from an unavailable resource after relaunch? Are these expected filesystem limitations, problems in our API usage, or behaviours that should be reported as macOS bugs? What additional diagnostics would help distinguish them? Ideally, the solution would preserve the original folder authorization without requiring repeated reselection or access to the parent directory or entire volume. I have read Accessing files from the macOS App Sandbox. I also found this discussion of bookmark failures involving exFAT, but it concerns volume roots and an earlier macOS release, so I’m not assuming it explains our case.
Replies
4
Boosts
0
Views
206
Activity
1w
APFS worse than HFS for SSD file enumeration
A user of my app reported that it is slower when enumerating a large number of files on APFS compared to HFS+. Online I can only find information that this is expected for rotational hard disks, but apparently APFS should be optimized for SSDs and hence the observed performance doesn't make sense. I used the code below to enumerate a folder hierarchy with about 100'000 files. I ran it several times on both APFS and HFS+ to minimize differences due to caching. On APFS the last runs took about 4.5 seconds, while on HFS+ the last runs took about 1.3 seconds. How can this big difference be explained? Is APFS really slower than HFS+ when enumerating files on SSDs? let openPanel = NSOpenPanel() openPanel.canChooseDirectories = true openPanel.canChooseFiles = false if openPanel.runModal() == .cancel { return } let resourceKeys: [URLResourceKey] = [.isDirectoryKey, .fileSizeKey, .creationDateKey, .contentModificationDateKey, .fileIdentifierKey, .isSymbolicLinkKey, .isHiddenKey, .isUserImmutableKey, .attributeModificationDateKey] let enumerator = FileManager.default.enumerator(at: openPanel.urls[0], includingPropertiesForKeys: resourceKeys) { url, error in print(error) return true }! let date = Date() var i = 0 for case let url as URL in enumerator { let _ = try? url.resourceValues(forKeys: Set(resourceKeys)) i += 1 if i % 10000 == 0 { print(i) } } print(-date.timeIntervalSinceNow)
Replies
0
Boosts
0
Views
135
Activity
1w
Inconsistent caseInsensitiveCompare behavior
(lldb) p [@"ΗΙzzz" caseInsensitiveCompare:@"ᾚabc"] (long long) -1 (lldb) p [@"ᾚabc" caseInsensitiveCompare:@"ΗΙzzz"] (long long) -1 Note the unicode char in the second string. The results can't be both -1, afaik, if one is -1 the other one should be +1. This causes inconsistent indexing in a sorted array resulting in obscure crashes of my app. Am I doing something wrong? Tested on iOS 27 and macOS 26.6.
Replies
6
Boosts
0
Views
231
Activity
1w
NSURL appends '..' path component on returned url from URLByDeletingLastPathComponent which seems to contradict the documentation
The documentation for URLByDeletingLastPathComponent states the following: If the receiver’s URL represents the root path, this property contains a copy of the original URL. Otherwise, if the original URL has only one path component, this property contains the empty string. So maybe this is new in Foundation with the Golden Gate or maybe I just noticed this but the documentation above doesn't seem to be true. This will create an infinite loop: NSURL *fileURL = [NSURL fileURLWithPath:@"/Users/MyUsername/Desktop/AFolder" isDirectory:YES]; NSLog(@"%@",fileURL); NSURL *ancestorURL = fileURL.URLByDeletingLastPathComponent; while (ancestorURL != nil) { NSURL *nextAncestor = ancestorURL.URLByDeletingLastPathComponent; NSLog(@"Next: %@",nextAncestor); if ([nextAncestor isEqual:ancestorURL]) { NSLog(@"Hit the root - got a copy of the same url"); break; } else if ([nextAncestor.absoluteString isEqualToString:@""] || [nextAncestor.path isEqualToString:@""]) { NSLog(@"Empty string means we had only 1 path component."); break; } else if (nextAncestor == nil) { NSLog(@"Got nil"); break; } ancestorURL = nextAncestor; } The infinite loop can be avoided by adding the following condition: else if (nextAncestor.pathComponents.count == 1) { // One path component. NSURL *sneakPeak = nextAncestor.URLByDeletingLastPathComponent; NSLog(@"%lu",sneakPeak.pathComponents.count); // Logs 2. break; } When you get to one path component URLByDeletingLastPathComponent appends a .. path component rather than deleting a path component or returning a copy of the receiver or a url with an empty string.. If this sounds like a bug let me know. When I call URLByDeletingLastPathComponent on a url with only one path component I'd like to get nil. I think that would be a cleaner design.
Replies
5
Boosts
0
Views
567
Activity
2w
Does identifierForVendor (IDFV) change after transferring an app to another Apple Developer account?
Title: Does identifierForVendor (IDFV) change after transferring an app to another Apple Developer account? We are planning to transfer an existing App Store app from one Apple Developer account/team to another using App Transfer. The app currently uses: UIDevice.current.identifierForVendor as one of the identifiers sent to our backend. We would like to confirm the exact behavior of identifierForVendor after the app is transferred to the recipient developer account. Our scenario is: The app is currently published under Developer Team A. Existing users already have the app installed on their devices. We transfer the app to Developer Team B through App Store Connect. Developer Team B creates new certificates/provisioning profiles and publishes a new version of the same app. Existing users update the app normally from the App Store, without uninstalling it. Questions: After an existing user updates from the last version published by Team A to the first version published by Team B, will UIDevice.current.identifierForVendor remain the same, or will it be regenerated? Is the vendor used to calculate IDFV associated with: the App Store app record, the Bundle ID, the Team ID, the App ID Prefix, the developer organization/vendor, or some other value? Does App Transfer itself cause IDFV to change, or does the value only change under specific conditions such as changing the organization name or uninstalling all apps from the same vendor? If IDFV changes after App Transfer, does Apple provide any official migration or mapping mechanism that allows the backend to associate the old IDFV with the new IDFV? For example, Sign in with Apple provides a user migration mechanism when transferring an app between developer teams. Is there any equivalent mechanism for identifierForVendor? Is there any difference between: users who update the app directly after the transfer, and users who uninstall the old version and reinstall the app after the transfer? We have reviewed the documentation for identifierForVendor and App Transfer, but we could not find an explicit statement describing the IDFV behavior specifically for an App Transfer between two different developer teams. Our main concern is maintaining backend device associations for existing users after the transfer. We would appreciate an official clarification on whether IDFV continuity is guaranteed across App Transfer, and if not, what migration strategy Apple recommends.
Replies
1
Boosts
0
Views
323
Activity
3w
How does font caching / resources for each app work?
I'm a font developer. In the development process, I will revise a font and overwrite the OTF file that is currently enabled (registered) with macOS. If I then launch an app, it will immediately use the revised version of the font; while apps that are already loaded will continue to use the old version. This suggests that each app is loading new and separate font data, rather than getting it from some existing cache in memory. Yet macOS does have a "font cache" of some sort. Some apps, like TextEdit, seem to only load the fonts that they need to use. However, other apps, like Pages, load every enabled (registered) font on the OS!! (According to the Open Files list in Activity Monitor.) Given that /System/Library/Fonts/ is 625 Mb, and we can't disable any of it, isn't that a lot of data to be repeating? How many fonts is too many fonts? I can't find much documentation about the process.
Replies
7
Boosts
0
Views
2.0k
Activity
3w
Xcode Version 27 Localised strings not recognised
Hello When compiling a project containing localised file strings for dictionaries with the new release Xcode version 27, I receive an error as the compiler expect a plist instead of the string! validation failed: Couldn't parse property list because the input data was in an invalid format The Xcode version 26… did work fine I did file a Feedback Assistant FB24806196 Using a MacBook Air Apple silicon
Replies
1
Boosts
0
Views
166
Activity
3w
NSMetaDataQuery and MD-Spotlight Backed APIs Suddenly Stop Working
I'm testing code that uses NSMetadataQuery and I noticed some odd behavior. I run a query where the search scope is set to my Desktop directory. The predicate is set to search for a file name that contains 'we' (display name to be precise: kMDItemDisplayName). And I get no results. So I stop the app from Xcode then I create a new folder on the Desktop and name it we exactly. Then I rerun my app and start the query again - still no results. Unfortunately none of the Spotlight based APIs I'm using report errors. There is no delegate method -queryDidFailWithError: or anything like that. So in another place my app uses the lower level MD prefixed APIs in Core Services to read file metadata and I notice that those APIs are failing as well. Specifically I try to load metadata for a PNG image. I create an MDItemRef via MDItemCreateWithURL (and I do get an MDItemRef). Then I call MDItemCopyAttributes with the MDItemRef and an array of metadata attribute names: CFDictionaryRef fetchedData = MDItemCopyAttributes(mdItem, attributeNames); I step through it in the debugger and fetchedData is NULL. Since there is no error handling APIs available for any of this my app just silently fails. I have Console.app open when I step through MDItemCopyAttributes call in the debugger and this logs out every time: com.apple.spotlightserver Bad checksum on fetch attributes reply from store, 0x123ea456.... FWIW I do not have Spotlight indexing turned off on my system. Also jumping to Finder I'm experiencing the same failures (metadata isn't populating and the Desktop search for we produces no results). Actually on further inspection it looks like all searches are producing no results. Spotlight appears to be in a broken state system wide. I'm pretty sure a system restart will 'fix' it - until it starts occurring again. But for obvious reasons I'd like to avoid releasing a feature in my app that results in this kind of experience. Is there anything I can do on my end to workaround or avoid this issue? And tips or advice would be greatly appreciated.
Replies
2
Boosts
0
Views
439
Activity
3w
Loading User Installed VST3 Plugins While Remaining Sandboxed on MacOS
Hi, I’m developing a native macOS music app intended for the Mac App Store. We already support Audio Units and are investigating VST3 instrument and effect hosting on Apple Silicon. Users would install plugins themselves, typically in: /Library/Audio/Plug-Ins/VST3 ~/Library/Audio/Plug-Ins/VST3 The app would load these third-party plugin bundles using public APIs, such as CFBundleLoadExecutableAndReturnError. Plugins may be signed by developers with different Team IDs. Our app would not download or install them. Is there a supported way to load and execute these bundles while the hosting process remains sandboxed throughout? If so, which APIs and entitlements should we use? Specifically, I’m trying to distinguish permission to read a plugin bundle from permission to load its executable code. Would user selected folder access and security scoped bookmarks cover the sandbox access requirements, or is another mechanism needed? I understand that com.apple.security.cs.disable-library-validation addresses loading code signed by other developers, but does not itself grant sandbox file access. We cannot rely on an Audio Unit compatibility exception that disables the host’s sandbox. App Review Guideline 3.1.1 (https://developer.apple.com/app-store/review/guidelines/#in-app-purchase) explicitly allows Mac App Store apps to host plugins enabled outside the App Store. I’m looking for the supported technical approach under App Sandbox, rather than preapproval for our app. We’re checking this before implementation, so we don’t yet have a failing reproducer. Any relevant documentation, sample code or existing discussion would be appreciated. Thanks, Ben
Replies
1
Boosts
0
Views
487
Activity
3w
Is there an API for detecting if NSMetadataQuery is unavailable for a given URL (as a search scope)?
If the user prohibits Spotlight in System Settings for a given directory and I set that URL as one of the search scopes on an NSMetadataQuery- I believe the query will return no results. Is there an API for detecting Spotlight unavailability? Ideally I would like to display something in the UI for this kind of situation to explain why a feature built on top of this API is not working.
Replies
0
Boosts
0
Views
278
Activity
Sep ’26
iOS 26 AX: _UITabButtonAccessibility accessibilityValue → safeSwiftValueForKey → swift_abortRetainUnowned on cold launch (app frames: main only)
We are seeing a hard main-thread abort on iOS 26 during cold launch when VoiceOver (or another accessibility client) is active. about 1–7 seconds after process start. The crashing thread essentially shows only main from the app; the fatal path is entirely in system frameworks. What happens is that UIAccessibility asks for an accessibility value, UIKit.axbundle handles it (on iOS 26.5 we exact-match-symbolicate this to -[_UITabButtonAccessibility accessibilityValue] + 120), then AXCoreUtilities safeSwiftValueForKey reflects a Swift object via Mirror / AttributeGraph. While copying an unowned field, the referent is already gone, so libswiftCore calls swift_abortRetainUnowned and the process dies. Not finding unowned in app source does not contradict this: the reflected object can live in system or SDK Swift state. OS versions in the corpus: iOS 26.5 (23F77), 26.6 (23G71), and 26.6.1 (23G83). All reports load UIKit.axbundle. Launch-to-crash gaps range from roughly 1.4s to 7.3s. Most 26.6 samples share UIKit.axbundle binary UUID 387c6473…; we did not have matching Device Support for that build locally. One iOS 26.5 sample has UIKit.axbundle binary UUID dca69975… and AXCoreUtilities 78a7c163…, both exactly matching local Device Support, so atos on that sample is trustworthy. On that iOS 26.5 sample (filename redacted), the symbolicated path is: VoiceOver / AX → UIAccessibility (_iosAccessibilityAttributeValue → _accessibilityAXAttributedValue → _accessibilityPotentiallyAttributedValueForNonAttributedSelector) → UIKit.axbundle -[_UITabButtonAccessibility accessibilityValue] + 120 → AXCoreUtilities (_AXSafeSwiftValueForKeyTm → safeSwiftValueForKey → _visitValueWithReflection) → AttributeGraph (AGTypeApplyFields2::Visitor::visit_field) → libswiftCore (swift_reflectionMirror_subscript → copyUnownedFieldContents → swift_unknownObjectUnownedLoadStrong → swift_abortRetainUnowned) → App: main only Frame 32 math: runtime 0x2be49b130, slide base 0x2be3cf000, offset 0xCC130 → _UITabButtonAccessibility accessibilityValue + 120. Questions for anyone hitting the same stack: 1.Is there already an Apple Feedback / radar for safeSwiftValueForKey + swift_abortRetainUnowned on iOS 26? crash_ios265_redacted.txt
Replies
0
Boosts
0
Views
641
Activity
Aug ’26
Access to user’s application usage
Does anybody know if Apple allows for apps to access a user’s applicationa’ usage data? As a part of an app idea I have I need to see What is the screen time of each user on each app (Not only mine). Is it possible?
Replies
2
Boosts
0
Views
366
Activity
Aug ’26
Can't get a scoped resource URL from drag and drop
Hi, My Mac app allows a customer to drag and drop a file package onto a SwiftUI view. I can't seem to find a way to successfully call .startAccessingSecurityScopedResource() with the file/dir that was dropped into the view. I put together a simple test app. Here is the code: struct ContentView: View { @State var isTargetedForDrop: Bool = false var body: some View { VStack { Image(systemName: "globe") .imageScale(.large) .foregroundStyle(.tint) Text("Hello, world!") Rectangle() .stroke(Color.gray) .onDrop(of: [UTType.fileURL], isTargeted: $isTargetedForDrop) { providers in guard let provider = providers.first(where: { $0.hasItemConformingToTypeIdentifier(UTType.fileURL.identifier) }) else { return false } provider.loadItem(forTypeIdentifier: UTType.fileURL.identifier, options: nil) { item, error in if let error = error { print("Drop load error: \(error)") return } if let url = item as? URL { print("Dropped file URL: \(url)") } else if let data = item as? Data, let url = URL(dataRepresentation: data, relativeTo: nil) { print("Dropped file URL (from data): \(url)") let access = url.startAccessingSecurityScopedResource() if access { print("Successfully accessed file at URL: \(url)") } else { print("Failed to access file at URL: \(url)") } url.stopAccessingSecurityScopedResource() } else { print("Unsupported dropped item: \(String(describing: item))") } } return true } } .padding() } } When I drop a file package into this view I see, "Failed to access file at URL: <the_full_file_path>" I'm running Xcode 26 on macOS 26.
Replies
3
Boosts
1
Views
946
Activity
Aug ’26
Concurrent upload tasks over HTTP/2: request bodies sent strictly sequentially (no stream interleaving) — starved tasks fail behind slow-POST protection
We maintain a large file-sync app. After our upload endpoint moved to HTTP/2, we found that when multiple NSURLSessionUploadTasks run concurrently, all tasks send their request headers immediately (multiplexed on a single connection — confirmed identical localPort via URLSessionTaskMetrics), but request bodies are transmitted essentially one task at a time: while one task's body saturates the uplink, the other tasks send zero body bytes for the entire duration (countOfBytesSent == 0). This reproduces with both background sessions (BackgroundUploadTask) and default sessions (LocalUploadTask), on Wi-Fi and cellular. iOS 26.5, Xcode 26.3, tasks created with uploadTask(with:fromFile:), multipart POST. This becomes a hard failure behind a load balancer with slow-POST (RUDY) protection: requests whose first body KB doesn't arrive within 5s are rejected with 408. The starved tasks fail even though the network is healthy. For comparison, OkHttp on Android writes bodies in interleaved 16KB DATA frames under identical conditions, so all streams pass the first-KB check. Metrics excerpt (4 concurrent uploads, one h2 connection): task 1: duration 18.7s, sent 180MB (full line rate) task 2: duration 22.8s, sent 43MB (transmitted only after task 1 finished) task 3: duration 46.0s, sent 247MB (after task 2) task 4: duration 5.2s, sent 0 bytes → 408 from the gateway In one run a starved stream sent exactly 65,536 bytes (the default initial stream window) and then stalled. Questions: Is this sender-side scheduling (no round-robin between streams' DATA frames) the expected CFNetwork behavior? Does URLSessionTask.priority influence HTTP/2 stream weighting for upload bodies? Is there any other way to influence bandwidth sharing between concurrent uploads? Is there any supported way to opt out of HTTP/2 (constrain ALPN to HTTP/1.1) or cap concurrent streams per connection from the client side? We believe there isn't, but would like to confirm. What is the recommended pattern for concurrent large uploads in this situation? Filed as FB24062619 with full sanitized metrics attached. Happy to provide more data.
Replies
3
Boosts
0
Views
1.2k
Activity
Aug ’26