I get this error, i have my own DIKit, and i want to use swiftdata for showing info from persisten model. It works all over the app, but i get this error with my .sheet.
// JobCreationView.swift // Features // // Created by Jens Vik on 26/03/2025. // import SwiftUI import DesignKit import DIKit import PresentationKit import CoreKit import DomainKit import SwiftData public struct JobCreationView: View { @Binding var isPresented: Bool // Inject view model using DIKit's property wrapper @Injected((any JobCreationViewModelProtocol).self) private var viewModel // Form state @Injected(ModelContext.self) private var modelContext @State private var date = Date() @State private var isASAP = false @State private var price = "" @State private var jobType = "Fiks" @State private var description = "" // Available job types private let jobTypes = ["Fiks", "Fiksit"] @Query private var userContexts: [UserContextModel] public init(isPresented: Binding<Bool>) { self._isPresented = isPresented print("DEBUG: JobCreationView initialized") } public var body: some View { let city = userContexts.first?.city ?? "Loading..." NavigationView { Form { Section(header: Text("Location")) { Text(city) } Section(header: Text("Details")) { TextField("Price", text: $price) .keyboardType(.numberPad) Picker("Job Type", selection: $jobType) { ForEach(jobTypes, id: \.self) { type in Text(type).tag(type) } } .pickerStyle(SegmentedPickerStyle()) TextEditor(text: $description) .frame(minHeight: 100) .overlay( RoundedRectangle(cornerRadius: 8) .stroke(Color.gray.opacity(0.2), lineWidth: 1) ) } } .navigationBarTitle("Create Job", displayMode: .inline) .navigationBarItems( leading: Button("Cancel") { isPresented = false }, trailing: Button("Post") { // Post functionality will be added later isPresented = false } .disabled( (!isASAP && date < Date()) || price.isEmpty || description.isEmpty) ) } } }
How bad is this macro error? error: the replacement path doesn't exist: "/var/folders/dn/x3x4wwkd335_rl91by3tqx5w0000gn/T/swift-generated-sources/@_swiftmacro_10FeatureKit15JobCreationViewV12userContexts33_CDDE5BE156468A2E8CC9B6A7E34B1006LL5QueryfMa.swift" error: the replacement path doesn't exist: "/var/folders/dn/x3x4wwkd335_rl91by3tqx5w0000gn/T/swift-generated-sources/@_swiftmacro_10FeatureKit15JobCreationViewV12userContexts33_CDDE5BE156468A2E8CC9B6A7E34B1006LL5QueryfMa.swift" error: the replacement path doesn't exist: "/var/folders/dn/x3x4wwkd335_rl91by3tqx5w0000gn/T/swift-generated-sources/@_swiftmacro_10FeatureKit15JobCreationViewV12userContexts33_CDDE5BE156468A2E8CC9B6A7E34B1006LL5QueryfMa.swift" error: the replacement path doesn't exist: "/var/folders/dn/x3x4wwkd335_rl91by3tqx5w0000gn/T/swift-generated-sources/@_swiftmacro_10FeatureKit15JobCreationViewV12userContexts33_CDDE5BE156468A2E8CC9B6A7E34B1006LL5QueryfMa.swift" error: the replacement path doesn't exist: "/var/folders/dn/x3x4wwkd335_rl91by3tqx5w0000gn/T/swift-generated-sources/@_swiftmacro_10FeatureKit15JobCreationViewV12userContexts33_CDDE5BE156468A2E8CC9B6A7E34B1006LL5QueryfMa.swift"