Search results for

“file uri scheme”

81,750 results found

Post

Replies

Boosts

Views

Activity

Reply to AppIntent search schema opens app as only option
I presume you looked at implementing code like this, from the documentation: @AppIntent(schema: .system.search) struct ExampleSearchIntent: ShowInAppSearchResultsIntent { static var searchScopes: [StringSearchScope] = [.general] var criteria: StringSearchCriteria func perform() async throws -> some IntentResult { let searchString = criteria.term print(Searching for (searchString)) // ... // Code that navigates to your app's search and enters the search string into a search field. // ... return .result() } } The key type here, ShowInAppSearchResultsIntent, is a clear indication of the intended behavior of showing search results inside of the app. Also, testing your intent in the Shortcuts app is an excellent way to test. Do I need to do AppIntents without the schema and wait until there is a search schema that does not open the app, or should I be using a different schema? What am I missing? It's worth considering the larger picture of what someone does with your intent after the search — in many cases, the
3w
Reply to New project with new AppIntent throws build error
To see what happened here, I used Xcode 26.4 beta 3 to create a new multi-platform app. I added a new file, added an import statement for App Intents, and then copied in the snippet of getting started code from the documentation. Indeed, this fails to compile. That new project's default build setting configuration is: Swift Langage Version: Swift 5 Approachable Concurrency: Yes Default Actor Isolation: MainActor To allow this to compile, I change the Default Actor Isolation build setting to nonisolated instead. This is worth a bug report — please use Feedback Assistant to report it, and post the FB number here so I can follow up on it. — Ed Ford,  DTS Engineer
3w
Current wisdom on multiple XPC services in a System Extension?
I'm following up on a couple of forum threads from 2020 to get more clarity on the current guidance for supporting multiple XPC services in system extensions. For context, I'm trying to create a system extension that contains both an Endpoint Security client and a Network Extension filter, and I'm seeing indications that the system may not expect this and doesn't handle it smoothly. First: Previous guidance indicated that the system would automatically provide a Mach service named ..xpc to use for communicating with the system extension. However, the SystemExtension man page currently documents an Info.plist key called NSEndpointSecurityMachServiceName and suggests that the default service name is deprecated; and in fact if this key is not set, I find a message in the Console: The extension from () is using the deprecated default mach service name. Please update the extension to set the NSEndpointSecurityMachServiceName key in the Info.plist file. I have accordingly set this key, but I wanted to conf
4
0
227
3w
Reply to How to upload large videos with PHAssetResourceUploadJobChangeRequest?
Thanks for the post. I'm not an expert on that API, not even close to that, so I'm inviting other engineers to jump into this thread and provide their options on the 3 questions. This is a PhotoKit upload asset for background process. As noted the extension processes uploads only while enabled. Disable the extension when a person signs out or disables cloud sync in your app. https://developer.apple.com/documentation/PhotoKit/uploading-asset-resources-in-the-background The PHAssetResourceUploadJobChangeRequest.createJob(destination:resource:) API is designed to hand off the entire upload process to a system daemon. Because the system daemon manages the network connection out-of-process (to preserve battery and allow the extension to be suspended or terminated), it imposes specific architectural constraints on how your backend must receive the data. Here is the limitations are documented https://developer.apple.com/documentation/photos/phphotoserror-swift.struct/limitexceeded Are you hitting any? I believe the
3w
Reply to Clarification on clonefile / copyfile support of clone directories?
The ‘strongly discouraged’ guidance only applies to directly using the clonefile function on directories, because it ties up the filesystem in ways that can be detrimental to the overall system health. On the other hand cloning directories recursively with copyfile is perfectly fine, because copyfile internally only calls clonefile on each file separately. Hope that helps clarify things.
Topic: App & System Services SubTopic: Core OS Tags:
3w
Reply to MacOS 26.4 beta “Failed to prepare software update”
Thanks for the post. This is extremely interesting, but I'm sure is frustrating as well. Are you able to complete the installation if you boot to safe mode? It seems it is almost certainly a corrupted OTA (Over-The-Air) delta update file cached on your system? The process terminates with Failed to prepare the software update or An error occurred while downloading the selected updates.”? When a beta update fails halfway or downloads a corrupted delta package, macOS will continuously try to use that broken file every time you hit Update, resulting in the same error. Can I ask you both to please create a bug for this issue? Once you open the bug report, please post the FB number here for my reference. If you have any questions about filing a bug report, take a look at Bug Reporting: How and Why? Thanks!! Albert Pascual
  Worldwide Developer Relations.
Topic: Community SubTopic: Apple Developers Tags:
3w
How to upload large videos with PHAssetResourceUploadJobChangeRequest?
I'm implementing a PHBackgroundResourceUploadExtension to back up photos and videos from the user's library to our cloud storage service. Our existing upload infrastructure uses chunked uploads for large files (splitting videos into smaller byte ranges and uploading each chunk separately). This approach: Allows resumable uploads if interrupted Stays within server-side request size limits Provides granular progress tracking Looking at the PHAssetResourceUploadJobChangeRequest.createJob(destination:resource:) API, I don't see a way to specify byte ranges or create multiple jobs for chunks of the same resource. Questions: Does the system handle large files (1GB+) automatically under the hood, or is there a recommended maximum file size for a single upload job? Is there a supported pattern for chunked/resumable uploads, or should the destination URL endpoint handle the entire file in one request? If our server requires chunked uploads (e.g., BITS protocol with CreateSession → F
4
0
534
3w
Reply to Apple CDN Returning HTML Instead of JSON for AASA File – Invalid Character '<' Error (Universal Links)
Thanks for the post and sorry that I have missed it, somehow went over all my filters, no excuses for me, thanks for your patience. Doing a simple request returns correct JSON with curl -v https://app.myloft-stage.com/.well-known/apple-app-site-association But with a simple user-agent we get a security issue: curl -I -A AASA-Bot/1.0 https://app.myloft-stage.com/.well-known/apple-app-site-association So the servers can’t not access the file. When you test the URL in your browser or via cURL, you are using a standard User-Agent. When Apple's CDN fetches the file, it uses a specific bot User-Agent and originates from Apple's IP subnets. Check your server/WAF access logs for requests to the /.well-known/apple-app-site-association path. Look for blocked requests or requests returning a 403/Challenge status for the AASA-Bot User-Agent. Whitelist all User-Agent and IPs in your firewall rules for that specific path. When all that is done, everything will start working in a few hours. Albert Pascual

Topic: App & System Services SubTopic: General Tags:
3w
Reply to _MPRemoteCommandEventDispatch crashes on iOS 26.x devices.
Hello @Highmore and @John24, Could you please attach a JSON version of any crash reports (.ips) to your thread? Please see Acquiring crash reports and diagnostic logs for details. Alternatively, you could also open a Bug Report via Feedback Assistant and attach a sysdiagnose log there. Bug Reports allow you to upload artifacts with private information if necessary, and provide you with feedback status updates as progress is made on issues. Once you open the bug report, please post the FB number here for my reference. If you have any questions about filing a bug report, take a look at Bug Reporting: How and Why? Let me know if you'd like to know more, Richard Yeh  Developer Technical Support
Topic: Media Technologies SubTopic: Audio Tags:
3w
Reply to iOS 27 feature suggestion
It seems like this is an enhancement request. If you'd like us to consider adding the necessary functionality, please file an enhancement request using Feedback Assistant. Once you file the request, please post the FB number here. If you're not familiar with how to file enhancement requests, take a look at Bug Reporting: How and Why? Albert Pascual
  Worldwide Developer Relations.
Topic: Design SubTopic: General Tags:
3w
Reply to XProtect makes app hang when running an AppleScript
Quinn- A user was reporting the crash which I could not reproduce locally. We are both running macOS 26.3 right after it came out (I upgraded to macOS 26 mostly because of this- rounded corners are annoying/wasteful, just saying). Code is on GitHub (https://github.com/com-entonos/Desktop-Icon-Manager) in particular ViewController.swift, line 114. This works for the user. The previous version of that file crashes at start for the user. The way the code crashed I could not explain (it was in a routine it should not be possible to reach at startup) unless there was UserDefaults value that changed. I had the user use 'defaults delete ...' to delete the relevant plist file, so I really don't know what the state of his machine was. If he had 'Automatically restore at start' checked, it would explain it. Default is not checked. He was at an university so who knows what IT does... Good luck.
Topic: Privacy & Security SubTopic: General Tags:
3w
Reply to WKWebView could not access local javascript files
here is error signature: start setting access permission file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/CM_chat_view_base.html with accessURL file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/ 0x12c0d40c0 - [PID=1514] WebProcessProxy::hasAssumedReadAccessToURL(3198190): no access complete setting access permission file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/CM_chat_view_base.html with accessURL file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/
Topic: Safari & Web SubTopic: General Tags:
3w
WKWebView could not access local javascript files
We are experiencing an issue after Xcode 26.0 to load local javascript files to WKWebView to render our own design. it used to work well, however after Xcode 26.0, when [self.webView loadFileURL:fileURL allowingReadAccessToURL:accessURL]; it returns [PID=1514] WebProcessProxy::hasAssumedReadAccessToURL(3198190): no access self.webRootPath = [[NSHomeDirectory() stringByAppendingPathComponent:@Documents] stringByAppendingPathComponent:CHAT_VIEW_WEB_ROOT]; NSFileManager *fileManager = [NSFileManager defaultManager]; NSError *error = nil; if (! [fileManager fileExistsAtPath:self.webRootPath]){ [fileManager createDirectoryAtPath:self.webRootPath withIntermediateDirectories:NO attributes:nil error:&error]; } NSURL *accessURL = [NSURL fileURLWithPath:self.webRootPath]; Not sure how to assign access permission to WKWebView. Any help much appreciated.
Topic: Safari & Web SubTopic: General Tags:
5
0
1.6k
3w
Reply to Instruments Crash using swiftui instrument
@HolgerGrauslund Thank you for your post. Unfortunately, I am unable to discuss other individuals’ bugs or timelines regarding an issue publicly. Additionally, I am uncertain if you are experiencing the same issue. I recommend creating a new thread and providing as much information as possible, including crash files, sysdiagnose results, and a focused project that reproduces the issue. This information will assist engineers in identifying the issue you are encountering. Thank you for your understanding. Albert Pascual
  Worldwide Developer Relations.
3w
Reply to AppIntent search schema opens app as only option
I presume you looked at implementing code like this, from the documentation: @AppIntent(schema: .system.search) struct ExampleSearchIntent: ShowInAppSearchResultsIntent { static var searchScopes: [StringSearchScope] = [.general] var criteria: StringSearchCriteria func perform() async throws -> some IntentResult { let searchString = criteria.term print(Searching for (searchString)) // ... // Code that navigates to your app's search and enters the search string into a search field. // ... return .result() } } The key type here, ShowInAppSearchResultsIntent, is a clear indication of the intended behavior of showing search results inside of the app. Also, testing your intent in the Shortcuts app is an excellent way to test. Do I need to do AppIntents without the schema and wait until there is a search schema that does not open the app, or should I be using a different schema? What am I missing? It's worth considering the larger picture of what someone does with your intent after the search — in many cases, the
Replies
Boosts
Views
Activity
3w
Reply to New project with new AppIntent throws build error
To see what happened here, I used Xcode 26.4 beta 3 to create a new multi-platform app. I added a new file, added an import statement for App Intents, and then copied in the snippet of getting started code from the documentation. Indeed, this fails to compile. That new project's default build setting configuration is: Swift Langage Version: Swift 5 Approachable Concurrency: Yes Default Actor Isolation: MainActor To allow this to compile, I change the Default Actor Isolation build setting to nonisolated instead. This is worth a bug report — please use Feedback Assistant to report it, and post the FB number here so I can follow up on it. — Ed Ford,  DTS Engineer
Replies
Boosts
Views
Activity
3w
Current wisdom on multiple XPC services in a System Extension?
I'm following up on a couple of forum threads from 2020 to get more clarity on the current guidance for supporting multiple XPC services in system extensions. For context, I'm trying to create a system extension that contains both an Endpoint Security client and a Network Extension filter, and I'm seeing indications that the system may not expect this and doesn't handle it smoothly. First: Previous guidance indicated that the system would automatically provide a Mach service named ..xpc to use for communicating with the system extension. However, the SystemExtension man page currently documents an Info.plist key called NSEndpointSecurityMachServiceName and suggests that the default service name is deprecated; and in fact if this key is not set, I find a message in the Console: The extension from () is using the deprecated default mach service name. Please update the extension to set the NSEndpointSecurityMachServiceName key in the Info.plist file. I have accordingly set this key, but I wanted to conf
Replies
4
Boosts
0
Views
227
Activity
3w
Reply to How to upload large videos with PHAssetResourceUploadJobChangeRequest?
Thanks for the post. I'm not an expert on that API, not even close to that, so I'm inviting other engineers to jump into this thread and provide their options on the 3 questions. This is a PhotoKit upload asset for background process. As noted the extension processes uploads only while enabled. Disable the extension when a person signs out or disables cloud sync in your app. https://developer.apple.com/documentation/PhotoKit/uploading-asset-resources-in-the-background The PHAssetResourceUploadJobChangeRequest.createJob(destination:resource:) API is designed to hand off the entire upload process to a system daemon. Because the system daemon manages the network connection out-of-process (to preserve battery and allow the extension to be suspended or terminated), it imposes specific architectural constraints on how your backend must receive the data. Here is the limitations are documented https://developer.apple.com/documentation/photos/phphotoserror-swift.struct/limitexceeded Are you hitting any? I believe the
Replies
Boosts
Views
Activity
3w
Reply to Clarification on clonefile / copyfile support of clone directories?
The ‘strongly discouraged’ guidance only applies to directly using the clonefile function on directories, because it ties up the filesystem in ways that can be detrimental to the overall system health. On the other hand cloning directories recursively with copyfile is perfectly fine, because copyfile internally only calls clonefile on each file separately. Hope that helps clarify things.
Topic: App & System Services SubTopic: Core OS Tags:
Replies
Boosts
Views
Activity
3w
Reply to MacOS 26.4 beta “Failed to prepare software update”
Thanks for the post. This is extremely interesting, but I'm sure is frustrating as well. Are you able to complete the installation if you boot to safe mode? It seems it is almost certainly a corrupted OTA (Over-The-Air) delta update file cached on your system? The process terminates with Failed to prepare the software update or An error occurred while downloading the selected updates.”? When a beta update fails halfway or downloads a corrupted delta package, macOS will continuously try to use that broken file every time you hit Update, resulting in the same error. Can I ask you both to please create a bug for this issue? Once you open the bug report, please post the FB number here for my reference. If you have any questions about filing a bug report, take a look at Bug Reporting: How and Why? Thanks!! Albert Pascual
  Worldwide Developer Relations.
Topic: Community SubTopic: Apple Developers Tags:
Replies
Boosts
Views
Activity
3w
How to upload large videos with PHAssetResourceUploadJobChangeRequest?
I'm implementing a PHBackgroundResourceUploadExtension to back up photos and videos from the user's library to our cloud storage service. Our existing upload infrastructure uses chunked uploads for large files (splitting videos into smaller byte ranges and uploading each chunk separately). This approach: Allows resumable uploads if interrupted Stays within server-side request size limits Provides granular progress tracking Looking at the PHAssetResourceUploadJobChangeRequest.createJob(destination:resource:) API, I don't see a way to specify byte ranges or create multiple jobs for chunks of the same resource. Questions: Does the system handle large files (1GB+) automatically under the hood, or is there a recommended maximum file size for a single upload job? Is there a supported pattern for chunked/resumable uploads, or should the destination URL endpoint handle the entire file in one request? If our server requires chunked uploads (e.g., BITS protocol with CreateSession → F
Replies
4
Boosts
0
Views
534
Activity
3w
Reply to Apple CDN Returning HTML Instead of JSON for AASA File – Invalid Character '<' Error (Universal Links)
Thanks for the post and sorry that I have missed it, somehow went over all my filters, no excuses for me, thanks for your patience. Doing a simple request returns correct JSON with curl -v https://app.myloft-stage.com/.well-known/apple-app-site-association But with a simple user-agent we get a security issue: curl -I -A AASA-Bot/1.0 https://app.myloft-stage.com/.well-known/apple-app-site-association So the servers can’t not access the file. When you test the URL in your browser or via cURL, you are using a standard User-Agent. When Apple's CDN fetches the file, it uses a specific bot User-Agent and originates from Apple's IP subnets. Check your server/WAF access logs for requests to the /.well-known/apple-app-site-association path. Look for blocked requests or requests returning a 403/Challenge status for the AASA-Bot User-Agent. Whitelist all User-Agent and IPs in your firewall rules for that specific path. When all that is done, everything will start working in a few hours. Albert Pascual

Topic: App & System Services SubTopic: General Tags:
Replies
Boosts
Views
Activity
3w
Reply to _MPRemoteCommandEventDispatch crashes on iOS 26.x devices.
Hello @Highmore and @John24, Could you please attach a JSON version of any crash reports (.ips) to your thread? Please see Acquiring crash reports and diagnostic logs for details. Alternatively, you could also open a Bug Report via Feedback Assistant and attach a sysdiagnose log there. Bug Reports allow you to upload artifacts with private information if necessary, and provide you with feedback status updates as progress is made on issues. Once you open the bug report, please post the FB number here for my reference. If you have any questions about filing a bug report, take a look at Bug Reporting: How and Why? Let me know if you'd like to know more, Richard Yeh  Developer Technical Support
Topic: Media Technologies SubTopic: Audio Tags:
Replies
Boosts
Views
Activity
3w
Reply to iOS 27 feature suggestion
It seems like this is an enhancement request. If you'd like us to consider adding the necessary functionality, please file an enhancement request using Feedback Assistant. Once you file the request, please post the FB number here. If you're not familiar with how to file enhancement requests, take a look at Bug Reporting: How and Why? Albert Pascual
  Worldwide Developer Relations.
Topic: Design SubTopic: General Tags:
Replies
Boosts
Views
Activity
3w
Reply to XProtect makes app hang when running an AppleScript
Quinn- A user was reporting the crash which I could not reproduce locally. We are both running macOS 26.3 right after it came out (I upgraded to macOS 26 mostly because of this- rounded corners are annoying/wasteful, just saying). Code is on GitHub (https://github.com/com-entonos/Desktop-Icon-Manager) in particular ViewController.swift, line 114. This works for the user. The previous version of that file crashes at start for the user. The way the code crashed I could not explain (it was in a routine it should not be possible to reach at startup) unless there was UserDefaults value that changed. I had the user use 'defaults delete ...' to delete the relevant plist file, so I really don't know what the state of his machine was. If he had 'Automatically restore at start' checked, it would explain it. Default is not checked. He was at an university so who knows what IT does... Good luck.
Topic: Privacy & Security SubTopic: General Tags:
Replies
Boosts
Views
Activity
3w
Reply to WKWebView could not access local javascript files
here is error signature: start setting access permission file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/CM_chat_view_base.html with accessURL file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/ 0x12c0d40c0 - [PID=1514] WebProcessProxy::hasAssumedReadAccessToURL(3198190): no access complete setting access permission file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/CM_chat_view_base.html with accessURL file:///var/mobile/Containers/Data/Application/9044BAAF-5152-4C71-A3BA-5292C6FEED70/Documents/cv_webroot/
Topic: Safari & Web SubTopic: General Tags:
Replies
Boosts
Views
Activity
3w
WKWebView could not access local javascript files
We are experiencing an issue after Xcode 26.0 to load local javascript files to WKWebView to render our own design. it used to work well, however after Xcode 26.0, when [self.webView loadFileURL:fileURL allowingReadAccessToURL:accessURL]; it returns [PID=1514] WebProcessProxy::hasAssumedReadAccessToURL(3198190): no access self.webRootPath = [[NSHomeDirectory() stringByAppendingPathComponent:@Documents] stringByAppendingPathComponent:CHAT_VIEW_WEB_ROOT]; NSFileManager *fileManager = [NSFileManager defaultManager]; NSError *error = nil; if (! [fileManager fileExistsAtPath:self.webRootPath]){ [fileManager createDirectoryAtPath:self.webRootPath withIntermediateDirectories:NO attributes:nil error:&error]; } NSURL *accessURL = [NSURL fileURLWithPath:self.webRootPath]; Not sure how to assign access permission to WKWebView. Any help much appreciated.
Topic: Safari & Web SubTopic: General Tags:
Replies
5
Boosts
0
Views
1.6k
Activity
3w
Reply to Instruments Crash using swiftui instrument
@HolgerGrauslund Thank you for your post. Unfortunately, I am unable to discuss other individuals’ bugs or timelines regarding an issue publicly. Additionally, I am uncertain if you are experiencing the same issue. I recommend creating a new thread and providing as much information as possible, including crash files, sysdiagnose results, and a focused project that reproduces the issue. This information will assist engineers in identifying the issue you are encountering. Thank you for your understanding. Albert Pascual
  Worldwide Developer Relations.
Replies
Boosts
Views
Activity
3w
Reply to SwiftUI Instruments tool error: "Time Profiler: Time Profiler does not support the iOS platform"
Hi there! That is certainly not expected – could you please file a feedback with us, including model, OS version and sysdiagnose from your iOS device? Thanks, Kacper
Replies
Boosts
Views
Activity
3w