Post

Replies

Boosts

Views

Activity

Reply to fileImporter download progress from files in iCloud Drive
It seems like you can read the download progress from the NSMetadataUbiquitousItemPercentDownloadedKey file metadata key. You could probably initialize an NSMetadataItem using a URL object, then use the value(forAttribute:) function to fetch the download progress from 0.0 to 1.0. NSMetadataUbiquitousItemPercentDownloadedKey: https://developer.apple.com/documentation/foundation/nsmetadataubiquitousitempercentdownloadedkey NSMetadataItem: https://developer.apple.com/documentation/foundation/nsmetadataitem
Topic: UI Frameworks SubTopic: AppKit Tags:
Oct ’23
Reply to Xcode 15 archive failed - file name too long
Just an update: If you are using the #Predicate macro in any part of your SwiftUI's body, move it out to its own function and call the function from within your body. That seems to have fixed it for me. e.g. Instead of: var body: some View { HStack { ... let predicate = #Predicate<Item> { ... } ... } } Do: var body: some View { HStack { ... findItems() ... } } func findItems() { let predicate = #Predicate<Item> { ... } ... }
Oct ’23
Reply to Changing the live activity without push notification
Having the same issue here for my app. The unfortunate thing is that the timer starts counting up (mine works like a countdown), which makes it incredibly confusing for the user. As a workaround, I have to put the time the countdown ends. Using an if conditional (check if the date < current date) doesn't work as well. Seems like the UI is only updated once. Seems like there's no reliable way to do it now other than through a server-side push notification...
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Mar ’23
Reply to Icon composer icon contains alpha channel upload error
Getting the same issue 'ITMS-90717: Invalid large app icon' when building my app on Xcode Cloud using the latest beta versions. The versions listed in the workflow are as follows: Xcode Version: Xcode 26 beta 6 (17A5305f) macOS Version: macOS Tahoe 26 beta 7 (25A5346a) Hoping for some updates to this issue soon!
Replies
Boosts
Views
Activity
Aug ’25
Reply to fileImporter download progress from files in iCloud Drive
It seems like you can read the download progress from the NSMetadataUbiquitousItemPercentDownloadedKey file metadata key. You could probably initialize an NSMetadataItem using a URL object, then use the value(forAttribute:) function to fetch the download progress from 0.0 to 1.0. NSMetadataUbiquitousItemPercentDownloadedKey: https://developer.apple.com/documentation/foundation/nsmetadataubiquitousitempercentdownloadedkey NSMetadataItem: https://developer.apple.com/documentation/foundation/nsmetadataitem
Topic: UI Frameworks SubTopic: AppKit Tags:
Replies
Boosts
Views
Activity
Oct ’23
Reply to Xcode 15 archive failed - file name too long
Just an update: If you are using the #Predicate macro in any part of your SwiftUI's body, move it out to its own function and call the function from within your body. That seems to have fixed it for me. e.g. Instead of: var body: some View { HStack { ... let predicate = #Predicate<Item> { ... } ... } } Do: var body: some View { HStack { ... findItems() ... } } func findItems() { let predicate = #Predicate<Item> { ... } ... }
Replies
Boosts
Views
Activity
Oct ’23
Reply to Xcode 15 archive failed - file name too long
Seeing this too for a project that uses SwiftData (unsure if related). It might be worth noting that it does not affect building for running, only archiving. Running in the iOS Simulator and a real device works, but archiving will throw the 'file name too long' error.
Replies
Boosts
Views
Activity
Oct ’23
Reply to SwiftData inverse Relationship stop working in XCode 15 beta 7
You might want to try something like this: @Model final class Note { var name: String var item: Item? init(name: String = "Note name") { self.name = name } // Move this out of init func setItem(_ item: Item) { self.item = item } } And call setItem after init. I had some luck with this when I tried to initialize another Model in a Model too.
Replies
Boosts
Views
Activity
Sep ’23
Reply to Changing the live activity without push notification
Having the same issue here for my app. The unfortunate thing is that the timer starts counting up (mine works like a countdown), which makes it incredibly confusing for the user. As a workaround, I have to put the time the countdown ends. Using an if conditional (check if the date < current date) doesn't work as well. Seems like the UI is only updated once. Seems like there's no reliable way to do it now other than through a server-side push notification...
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Mar ’23