I have two screenshots of the threads, one under Swift 5 and one under Swift 6. I set a breakpoint in the updateView method. The Swift 5 run gets to the breakpoint. The Swift 6 run does not and crashes.
Swift 5
Swift 6
Any help would be most appreciated. Or maybe this is ripe for a bug report?
I've discovered where the crash is occurring. I have an @objc function called updateView() that is fired when the view controller detects NSPersistenStoreRemoteChange. As soon as I save an object in another view, the update fires and the app crashes.
NotificationCenter.default.addObserver(self, selector: #selector(updateView(_ :)), name: .NSPersistentStoreRemoteChange, object: nil)
The crash does not occur using Swift 5.
I now understand the the warnings go away under Swift 6 as 'InferSendableFromCaptures' has been enabled. I still have the crash. Guess I better dig in.
@DTS Engineer, here's an example of what I did.
nonisolated func locationManager(_ manager: CLLocationManager, didUpdateLocations locations: [CLLocation]) {
Task {
await changeMyLocation(locations)
}
}
func changeMyLocation(_ locations: [CLLocation]) {
myLocation = locations.last
}
I created a function to change the location and called it via a task.
I've fixed this by creating a struct for the data returned by SwiftData. I stuff the struct with the SwiftData and use the struct in my UICollectionViewDiffableDataSource. I am using SwiftData with UIKit.
I use the @Model class in my UICollectionViewDiffableDataSource as the ItemIdentifierType, which I now see is required to be Sendable. I have a ton of errors relating to this. This is a big deal. Do I need to create Sendable structs which reads the @Model parameters? I will look into ModelActor to see if that can get me what I need.
Apple is selling the dongle to developers to help them when they have an application with enhance graphics. It’s not being offered except through the developers website.
You can add a visionOS Platform in App Store Connect. But then if you want to submit for that platform, you'd have to submit a visionOS binary, not one for 'visionOS (designed for iPad)'. To do that, go to your build settings and under Architectures, set Base SDK to 'visionOS'. Then you will see the Destination 'Any visionOS Device (arm64)' in Xcode. If you keep the Base SDK as 'iOS' and submit a binary, it will be sent to your iOS app Platform. It won't be seen by a visionOS Platform.
I have two screenshots of the threads, one under Swift 5 and one under Swift 6. I set a breakpoint in the updateView method. The Swift 5 run gets to the breakpoint. The Swift 6 run does not and crashes.
Swift 5
Swift 6
Any help would be most appreciated. Or maybe this is ripe for a bug report?
I've discovered where the crash is occurring. I have an @objc function called updateView() that is fired when the view controller detects NSPersistenStoreRemoteChange. As soon as I save an object in another view, the update fires and the app crashes.
NotificationCenter.default.addObserver(self, selector: #selector(updateView(_ :)), name: .NSPersistentStoreRemoteChange, object: nil)
The crash does not occur using Swift 5.
I now understand the the warnings go away under Swift 6 as 'InferSendableFromCaptures' has been enabled. I still have the crash. Guess I better dig in.
@DTS Engineer, here's an example of what I did.
nonisolated func locationManager(_ manager: CLLocationManager, didUpdateLocations locations: [CLLocation]) {
Task {
await changeMyLocation(locations)
}
}
func changeMyLocation(_ locations: [CLLocation]) {
myLocation = locations.last
}
I created a function to change the location and called it via a task.
I've fixed this by creating a struct for the data returned by SwiftData. I stuff the struct with the SwiftData and use the struct in my UICollectionViewDiffableDataSource. I am using SwiftData with UIKit.
I use the @Model class in my UICollectionViewDiffableDataSource as the ItemIdentifierType, which I now see is required to be Sendable. I have a ton of errors relating to this. This is a big deal. Do I need to create Sendable structs which reads the @Model parameters? I will look into ModelActor to see if that can get me what I need.
Apple is selling the dongle to developers to help them when they have an application with enhance graphics. It’s not being offered except through the developers website.
You can add a visionOS Platform in App Store Connect. But then if you want to submit for that platform, you'd have to submit a visionOS binary, not one for 'visionOS (designed for iPad)'. To do that, go to your build settings and under Architectures, set Base SDK to 'visionOS'. Then you will see the Destination 'Any visionOS Device (arm64)' in Xcode. If you keep the Base SDK as 'iOS' and submit a binary, it will be sent to your iOS app Platform. It won't be seen by a visionOS Platform.