Thursday, November 16, 2023
HomeiOS Developmentios - SwiftData crashes app on get worth: Thread 1: EXC_BREAKPOINT (code=1,...

ios – SwiftData crashes app on get worth: Thread 1: EXC_BREAKPOINT (code=1, subcode=0x101e8303c)


I am using SwiftData in my app, and I’ve a Tracker mannequin with two variables: title of sort String and trackerType of sort TrackerType, which is one other mannequin. Retrieving title information from the Tracker works high-quality, however making an attempt to learn trackerType leads to a crash with the error:

EXC_BREAKPOINT (code=1, subcode=0x101e8303c).

This is my Tracker Mannequin:

@Mannequin
class Tracker {
    var title: String
    var trackerType: [TrackerType]

    init(title: String, trackerType: [TrackerType]) {
        self.title = title
        self.trackerType = trackerType
    }
}

@Mannequin
class TrackerType {
    var sort: String
    var standing: Bool

    init(sort: String, standing: Bool) {
        self.sort = sort
        self.standing = standing
    }
}

And the crash outcome snippest:
Crash

I do not perceive what could possibly be the difficulty. I tried to create the mannequin with dummy information domestically in my utility.



Supply hyperlink

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

- Advertisment -
Google search engine

Most Popular

Recent Comments