Can't Add Reference to xcdatamodelId - ios

I have an xcdatamodel file in a static library. To reference the file in my main app, I dragged the file into the main app through xcode. This worked great. I added a version to the xcdatamodel file. This created an xcdatamodelid file. If I try to drag the xcdatamodelid to my main project, xcode crashes. I can't drag the xcdatamodel files anymore.
How can I add a reference to my data model?
I'm using xcode 4.6.3.
The top of the xcode stack trace:
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 4H1503
ASSERTION FAILURE in /SourceCache/DVTFoundation/DVTFoundation-2091/Framework/Classes/FilePaths/DVTFilePath.m:461
Details: str should be an instance inheriting from NSString, but it is nil
Object: <DVTFilePath>
Method: +filePathForPathString:
Thread: <NSThread: 0x40030a220>{name = (null), num = 1}
Hints: None
Backtrace:
0 0x0000000106670a2a -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:messageFormat:arguments:] (in IDEKit)
1 0x000000010591f4e4 _DVTAssertionFailureHandler (in DVTFoundation)
2 0x00000001058a1c9f +[DVTFilePath filePathForPathString:] (in DVTFoundation)
3 0x0000000109a5b8d5 -[XCVersionGroup saveCurrentVersion] (in DevToolsCore)
4 0x0000000109935b53 -[PBXGroup insertItems:atIndex:] (in DevToolsCore)
5 0x0000000109ab2b83 -[Xcode3Group insertGroupSubitems:atIndexes:] (in DevToolsCore)

I upgraded to xcode 5 and I it works fine now. As an aside, when I dragged the file to my project, the window didn't give me the option to copy or add reference. I think this is was a bug with xcode 4. Now that xcode 5 is out, this is no longer relevant.

Related

Xcode 11 Can't Open Project/ Crashes

I downloaded xcode 11 today because my phone somehow downloaded iOS13 and I needed to upgrade to hook it up. Unfortunately, now when I try to open xcode on this project it crashes.
I feel like I have tried everything I have read- delete derived data, delete xcode and redownload (have even tried again with 10 and it won't open), delete xcshareddata, also tried turning off icloud.
No idea what else to try
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Application Specific Information:
ProductBuildVersion: 10B61
ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-14460.26/Xcode3Core/LegacyProjects/Frameworks/DevToolsCore/DevToolsCore/ProjectModel/DataModel/Containers/PBXContainerItemProxy.m:135
Details: _containerPortal is NULL
Object: <PBXContainerItemProxy: 0x7fe7a3309b00>
Method: -remoteContainer
Thread: <NSThread: 0x7fe79ef019d0>{number = 1, name = main}
Hints:
Backtrace:
0 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in IDEKit)
1 _DVTAssertionHandler (in DVTFoundation)
2 _DVTAssertionFailureHandler (in DVTFoundation)
3 -[PBXContainerItemProxy remoteContainer] (in DevToolsCore)
4 -[PBXContainerItemProxy remoteContainerItem] (in DevToolsCore)
5 -[PBXReferenceProxy sourceTree] (in DevToolsCore)
6 -[PBXReference addNotifications] (in DevToolsCore)
7 -[PBXReference awakeFromPListUnarchiver:] (in DevToolsCore)
8 -[PBXReferenceProxy awakeFromPListUnarchiver:] (in DevToolsCore)
9 -[PBXPListUnarchiver decodeRootObject] (in DevToolsCore)
10 +[PBXProject projectWithFile:errorHandler:readOnly:] (in DevToolsCore)
11 -[PBXFileReference loadedContainer] (in DevToolsCore)
12 -[PBXContainerItemProxy remoteContainer] (in DevToolsCore)
13 -[PBXContainerItemProxy remoteContainerItem] (in DevToolsCore)

XCode 9 crash on label localizer comment edition

Context : Xcode 9.0 (9A235)
When I try to edit my storyboard label's note for localizers (inserting Barty Crouch tag #bc-ignore!), XCode 9 crashes.
Also, trying to edit the font does nothing.
Seems like a corrupted storyboard to me, certainly after a merge.
Does anyone face the same issue ?
EDIT, non-ambiguous question :
Is there a fix to avoid the crash or do I have to edit the storyboard by hand?
Process: Xcode [66619]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 9.0 (13247)
Build Info: IDEFrameworks-13247000000000000~26
App Item ID: 497799835
App External ID: 823595305
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: Xcode [66619]
User ID: 501
Date/Time: 2017-10-03 15:59:00.562 +0200
OS Version: Mac OS X 10.12.6 (16G29)
Report Version: 12
Anonymous UUID: 3A288ABF-30D0-A9E7-A02E-4BBD3B1BABB5
Sleep/Wake UUID: 22E57F41-2180-4AB1-AA1D-B1DCF99E683E
Time Awake Since Boot: 320000 seconds
Time Since Wake: 26000 seconds
System Integrity Protection: enabled
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Application Specific Information:
ProductBuildVersion: 9A235
ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEInterfaceBuilder/IDEInterfaceBuilder-13196/InterfaceBuilderKit/Utilities/IBAppKitSupport.m:388
Details: Unknown systemFontType: 132
Object: <NSFont: 0x7fc74354c640>
Method: -metaFont
Thread: <NSThread: 0x7fc73a40f910>{number = 1, name = main}
Hints:
Backtrace:
0 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in IDEKit)
1 _DVTAssertionHandler (in DVTFoundation)
2 _DVTAssertionFailureHandler (in DVTFoundation)
3 -[NSFont(MethodsBasedOnPrivateState) metaFont] (in IDEInterfaceBuilderKit)
4 -[NSFont(IBDocumentArchiving) archiveWithDocumentArchiver:] (in IDEInterfaceBuilderKit)
5 __51-[IBDocumentArchiver archiveObject:forOptionalKey:]_block_invoke (in IDEInterfaceBuilderKit)
6 -[IBDocumentArchiver recurseWithArchiveToken:usingBlock:] (in IDEInterfaceBuilderKit)
7 -[IBDocumentArchiver recurseWithElementNamed:forObject:kind:invokingBlock:] (in IDEInterfaceBuilderKit)
Even with a brand new empty project, it craches when editing Comment For Localizer. It is an Xcode 9 issue.
As a workaround you can edit the .storyboard file manually by adding this kind of block (directly inside your <label> block for example):
<attributedString key="userComments">
<fragment content="Here goes your comment...">
<attributes>
<font key="NSFont" metaFont="smallSystem"/>
<paragraphStyle key="NSParagraphStyle" alignment="natural" lineBreakMode="wordWrapping" baseWritingDirection="natural" tighteningFactorForTruncation="0.0"/>
</attributes>
</fragment>
</attributedString>
Clean Xcode DerivedData folder.
Re-run Xcode.

EXC_BAD_ACCESS (SIGSEGV) when launching app from .ipa

I'm using a PDF reporting library, named PDFReporter, and I've got this weird crash when trying to generate a PDF. It happens only when I'm launching the app from an .ipa archive. It runs fine when I launch the app from Xcode.
Here's some of the trace I have from Xcode's Device logs :
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Subtype: KERN_INVALID_ADDRESS at 0x0000000000000010
Triggered by Thread: 0
Filtered syslog: None found
Thread 0 name: main Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libobjc.A.dylib 0x0000000181501b90 objc_msgSend + 16
1 ExpoTouch 0x0000000100649e64 OrgOssPdfreporterEngineXmlJRXmlDigesterFactory_setComponentsInternalEntityResourcesWithOrgOssPdfreporterEngineXmlJRXmlDigester_
+ 72
2 ExpoTouch 0x000000010064a054 OrgOssPdfreporterEngineXmlJRXmlDigesterFactory_createDigester + 136
3 ExpoTouch 0x00000001006849d4 OrgOssPdfreporterEngineXmlJRXmlLoader_load__WithJavaIoInputStream_ + 140
4 ExpoTouch 0x000000010071062c +[ReportExporter loadReport:] + 72
So the question is : what's the difference between installing from Xcode and installing from an .ipa ? Am I missing a library in the .ipa ? If so, how could I know which one ?

Xcode7 localization plist file crash

I need to localize my plist files and string files for my project. However, when I try to select other languages in file inspector for .plist files, the Xcode will crash.
Parent Process: ??? [1]
Responsible: Xcode [1981]
User ID: 501
Date/Time: 2015-09-24 11:47:52.069 +1000
OS Version: Mac OS X 10.10.4 (14E46)
Report Version: 11
Anonymous UUID: XXXXXXXXXXX
Time Awake Since Boot: 7500 seconds
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 7A220
UNCAUGHT EXCEPTION (NSInvalidArgumentException): *** -[NSPathStore2 stringByAppendingPathExtension:]: nil argument
UserInfo: (null)
Hints: None
Backtrace:
0 0x00007fff89f71024 __exceptionPreprocess (in CoreFoundation)
1 0x0000000102627744 DVTFailureHintExceptionPreprocessor (in DVTFoundation)
2 0x00007fff87bc376e objc_exception_throw (in libobjc.A.dylib)
3 0x00007fff89f70eed +[NSException raise:format:] (in CoreFoundation)
4 0x00007fff90f257e3 -[NSPathStore2 stringByAppendingPathExtension:] (in Foundation)
5 0x000000010c5ae87c -[Xcode3VariantGroup proposedFilePathForLocalization:fileType:] (in DevToolsCore)
6 0x000000011281dc8c -[Xcode3LocalizationCommands
Anyone has same issue with Xcode7??
PS: localizing .string file works fine with same approach.
Having the same issue. Xcode 7.1 beta 2 seems to have it fixed.

XCode 5 crash on loading the project

My Xcode 5 crashes each time i want to open a project.
I deleted the derived data, the cache, the preferences and reinstall xcode.
I don't know what i should do know. I can't work.
Here is the failure message. PLease help me. I looked a lot about this in the internet.
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 5A1413
ASSERTION FAILURE in /SourceCache/DVTFoundation/DVTFoundation-3532/Framework/Classes/Protocols/DVTInvalidation.m:243
Details: <IDESourceControlCredentialsValidator, 0x7f9f18c44cb0> was never invalidated.
Backtrace for allocation (if _creationBacktrace is set):
(null)
Object: <IDESourceControlCredentialsValidator: 0x7f9f18c44cb0>
Method: -dealloc
Thread: <NSThread: 0x7f9f12c14bc0>{name = (null), num = 1}
Hints: None
Backtrace:
0 0x00000001108fb188 -[IDEAssertionHandler handleFailureInMethod:object:fileName:lineNumber:messageFormat:arguments:] (in IDEKit)
1 0x000000010f68d655 _DVTAssertionHandler (in DVTFoundation)
2 0x000000010f68d984 _DVTAssertionFailureHandler (in DVTFoundation)
3 0x000000010f7626a6 _DVTInvalidation_DeallocSuper (in DVTFoundation)
4 0x00000001108982a3 -[IDESourceControlSSLAuthenticationWindowController .cxx_destruct] (in IDEKit)
5 0x00007fff8703ffcc object_cxxDestructFromClass(objc_object*, objc_class*) (in libobjc.A.dylib)
6 0x00007fff87039922 objc_destructInstance (in libobjc.A.dylib)
7 0x00007fff87039fa0 object_dispose (in libobjc.A.dylib)
8 0x000000010f6b7995 __DVTSetupKVODeallocAssertions_block_invoke_371 (in DVTFoundation)
9 0x00007fff82d347fa -[NSResponder dealloc] (in AppKit)
10 0x00007fff82c6a162 -[NSWindowController dealloc] (in AppKit)
11 0x00007fff82dde901 -[NSWindowController release] (in AppKit)
12 0x00007fff82f145b0 -[NSAutounbinder dealloc] (in AppKit)
13 0x00007fff8703a230 (anonymous namespace)::AutoreleasePoolPage::pop(void*) (in libobjc.A.dylib)
14 0x00007fff80818d72 _CFAutoreleasePoolPop (in CoreFoundation)
15 0x00007fff811cd47a -[NSAutoreleasePool drain] (in Foundation)
16 0x00007fff82d3527e -[NSApplication run] (in AppKit)
17 0x00007fff82cd9bd6 NSApplicationMain (in AppKit)
18 0x00007fff82bb27e1 start (in libdyld.dylib)
19 0x0000000000000002
Status update:
I started Xcode without loading the opened projects Alt + Shift.
After that i unchecked Enabled Source Control in Preferences. Since now i can work with Xcode. That's not a fix, but for now it is ok. I look for an answer in future. For now I have no problems ;)
This Devforums post seems to have a possible solution.
For anybody else reading this before a fix is found. My specific issue was resolved by using the correct hostname for the cert on the server. Our internal DNS could direct a more logical hostname to the svn server but it was not the same hostname that was in our cert. Using the correct hostname in the cert did away with the crashing.
This Problem can be solved by
Right click on xCode show package contents
Navigate to
/Applications/Xcode.app/Contents/PlugIns/
Rename the "IDESubversion.ideplugin.hold" to Some thing else
I tried disabling the "Source control" - but Xcode would crash when I select "Source Control" tab in "Preferences". I tried some of the other things - deleting the ~/.subversion/auth/svn..... files/directories. NONE of that worked.
Finally what worked was renaming IDESubversion.ideplugin inside of Xcode.App to IDESubversion.ideplugin.old.
To do this - open "Application" on Finder. Click on Xcode.App and then "Control-click" on it. Select "Show Package Contents". Next find "IDESubversion.ideplugin". Click on it - it would change to edit name mode - change name by adding .old to the end.
After this XCode will allow you to select "Source Control" tab in "Xcode->Preferences". Deselect "Enable Source Control" and then open Xcode again and select the project you want to open. It should work. However, if you enable source control again or rename the IDESubversion.ideplugin.old to IDESubversion.ideplugin - the project/Xcode crashes again. So these two seems to be essential changes to make this work.
BTW, this is with OS X Mavericks update and to latest version of XCode (5A2053).
Hope this helps.
The only solution for me was to rename
/Applications/Xcode.app/Contents/PlugIns/IDESubversion.ideplugin
as muthukumar mentioned.
XCode crashed even if I clicked on Source Control in perferences...
#muthukumar thanks for that.

Resources