从0.57.0 => 0.59.10升级了本地项目后,我在用xcode打开项目时遇到了问题。
react-native run-ios --verbose
上的完整堆栈跟踪
➜ react-native run-ios --verbose
info Found Xcode project Hub.xcodeproj
info Building using "xcodebuild -project Hub.xcodeproj -configuration Debug -scheme Hub -destination id=983F7ABF-6770-4DB6-B13C-2606DA4BF6C1 -derivedDataPath build/Hub"
info User defaults from command line:
IDEDerivedDataPathOverride = /Users/petarpilipovic/Documents/Project/hub-family-mobile/ios/build/Hub
error Failed to build iOS project. We ran "xcodebuild" command but it exited with error code null. To debug build logs further, consider building your app with Xcode.app, by opening Hub.xcodeproj
2019-07-26 19:20:15.011 xcodebuild[79690:6745260] [MT] DVTAssertions: ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-14492.1/Xcode3Core/LegacyProjects/Frameworks/DevToolsCore/DevToolsCore/ProjectModel/DataModel/Containers/PBXContainerItemProxy.m:136
Details: _containerPortal is NULL
Object: <PBXContainerItemProxy: 0x7fe8897ad3a0>
Method: -remoteContainer
Thread: <NSThread: 0x7fe886c058f0>{number = 1, name = main}
Hints:
Backtrace:
0 -[DVTAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in DVTFoundation)
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)
14 -[PBXReferenceProxy sourceTree] (in DevToolsCore)
15 -[PBXReference addNotifications] (in DevToolsCore)
16 -[PBXReference awakeFromPListUnarchiver:] (in DevToolsCore)
17 -[PBXReferenceProxy awakeFromPListUnarchiver:] (in DevToolsCore)
18 -[PBXPListUnarchiver decodeRootObject] (in DevToolsCore)
19 +[PBXProject projectWithFile:errorHandler:readOnly:] (in DevToolsCore)
20 -[Xcode3Project initWithFilePath:extension:workspace:options:error:] (in DevToolsCore)
21 __82+[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:]_block_invoke_2 (in IDEFoundation)
22 _dispatch_client_callout (in libdispatch.dylib)
23 _dispatch_lane_barrier_sync_invoke_and_complete (in libdispatch.dylib)
24 DVTDispatchBarrierSync (in DVTFoundation)
25 -[DVTDispatchLock performLockedBlock:] (in DVTFoundation)
26 __82+[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:]_block_invoke (in IDEFoundation)
27 __58-[DVTModelObjectGraph performBlockCoalescingModelChanges:]_block_invoke (in DVTFoundation)
28 -[DVTModelGraphTransactionScope performTransaction:] (in DVTFoundation)
29 -[DVTModelObjectGraph performBlockCoalescingModelChanges:] (in DVTFoundation)
30 +[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:] (in IDEFoundation)
31 +[IDEContainer retainedContainerAtFilePath:fileDataType:workspace:error:] (in IDEFoundation)
32 -[IDEWorkspace _configureWrappedWorkspaceWithError:] (in IDEFoundation)
33 __82+[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:]_block_invoke (in IDEFoundation)
34 +[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:] (in IDEFoundation)
35 +[IDEContainer retainedWrappedWorkspaceForContainerAtFilePath:fileDataType:error:] (in IDEFoundation)
36 -[Xcode3CommandLineBuildTool _resolveInputOptionsWithTimingSection:] (in Xcode3Core)
37 -[Xcode3CommandLineBuildTool run] (in Xcode3Core)
38 main (in xcodebuild)
39 start (in libdyld.dylib)
debug Error: Failed to build iOS project. We ran "xcodebuild" command but it exited with error code null. To debug build logs further, consider building your app with Xcode.app, by opening Hub.xcodeproj
2019-07-26 19:20:15.011 xcodebuild[79690:6745260] [MT] DVTAssertions: ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEXcode3ProjectSupport/IDEXcode3ProjectSupport-14492.1/Xcode3Core/LegacyProjects/Frameworks/DevToolsCore/DevToolsCore/ProjectModel/DataModel/Containers/PBXContainerItemProxy.m:136
Details: _containerPortal is NULL
Object: <PBXContainerItemProxy: 0x7fe8897ad3a0>
Method: -remoteContainer
Thread: <NSThread: 0x7fe886c058f0>{number = 1, name = main}
Hints:
Backtrace:
0 -[DVTAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in DVTFoundation)
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)
14 -[PBXReferenceProxy sourceTree] (in DevToolsCore)
15 -[PBXReference addNotifications] (in DevToolsCore)
16 -[PBXReference awakeFromPListUnarchiver:] (in DevToolsCore)
17 -[PBXReferenceProxy awakeFromPListUnarchiver:] (in DevToolsCore)
18 -[PBXPListUnarchiver decodeRootObject] (in DevToolsCore)
19 +[PBXProject projectWithFile:errorHandler:readOnly:] (in DevToolsCore)
20 -[Xcode3Project initWithFilePath:extension:workspace:options:error:] (in DevToolsCore)
21 __82+[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:]_block_invoke_2 (in IDEFoundation)
22 _dispatch_client_callout (in libdispatch.dylib)
23 _dispatch_lane_barrier_sync_invoke_and_complete (in libdispatch.dylib)
24 DVTDispatchBarrierSync (in DVTFoundation)
25 -[DVTDispatchLock performLockedBlock:] (in DVTFoundation)
26 __82+[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:]_block_invoke (in IDEFoundation)
27 __58-[DVTModelObjectGraph performBlockCoalescingModelChanges:]_block_invoke (in DVTFoundation)
28 -[DVTModelGraphTransactionScope performTransaction:] (in DVTFoundation)
29 -[DVTModelObjectGraph performBlockCoalescingModelChanges:] (in DVTFoundation)
30 +[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:] (in IDEFoundation)
31 +[IDEContainer retainedContainerAtFilePath:fileDataType:workspace:error:] (in IDEFoundation)
32 -[IDEWorkspace _configureWrappedWorkspaceWithError:] (in IDEFoundation)
33 __82+[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:]_block_invoke (in IDEFoundation)
34 +[IDEContainer _retainedContainerAtFilePath:fileDataType:workspace:options:error:] (in IDEFoundation)
35 +[IDEContainer retainedWrappedWorkspaceForContainerAtFilePath:fileDataType:error:] (in IDEFoundation)
36 -[Xcode3CommandLineBuildTool _resolveInputOptionsWithTimingSection:] (in Xcode3Core)
37 -[Xcode3CommandLineBuildTool run] (in Xcode3Core)
38 main (in xcodebuild)
39 start (in libdyld.dylib)
at ChildProcess.buildProcess.on.code (/Users/petarpilipovic/Documents/Project/hub-family-mobile/node_modules/@react-native-community/cli/build/commands/runIOS/runIOS.js:231:16)
at ChildProcess.emit (events.js:198:13)
at maybeClose (internal/child_process.js:982:16)
at Socket.stream.socket.on (internal/child_process.js:389:11)
at Socket.emit (events.js:198:13)
at Pipe._handle.close (net.js:606:12).
我发现here可能缺少门户密钥,因此我在project.pbxproj
部分检查了/* Begin PBXContainerItemProxy section */
,密钥在那里,一切似乎还可以。我也removed
xcode提供了数据缓存,一点也不高兴。我还能做什么?