Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix Xcode 10 error 'Multiple commands produce..' after generating Core Data subclasses

I have created a brand new core data model for my project and I want to create some NSManagedObject Subclasses for it. After generating subclasses XCode throws some errors that reference a path to the /DerivedData folder. See my steps below and image of the error:

enter image description here enter image description here enter image description here

I have already tried clean building, clearing the DerivedData folder, all that hoo-haa. I've also tried creating the generated files manually but I still get the same errors. Has anybody managed to get around this?

like image 901
rednaxela Avatar asked Feb 12 '19 22:02

rednaxela


People also ask

How do I set up NSManagedObject?

From the Xcode menu bar, choose Editor > Create NSManagedObject Subclass. Select your data model, then the appropriate entity, and choose where to save the files. Xcode places both a class and a properties file into your project.


1 Answers

Here is a solution of your issue related to coredata

As per your first screenshot, right hand side you can see field named Codegen under Class, open that dropdown and select Manual/None and generate files again from Editor - > Create NSManageObject Subclass, issue will be solve.

See this image

like image 157
Hardik Thakkar Avatar answered Oct 06 '22 23:10

Hardik Thakkar