Ich starte meine iOS-App auf dem Gerät (nicht Simulator) mit dem folgenden Befehl (App ist bereits installiert).Starten der App mit iOS-Geräten ist unzuverlässig
instruments \
-w c717fa22472d7b691ae5763af90e1e44244ad85a \
-t /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate \
-D "/Users/mj/Desktop/apps/trace" \
LPSimpleExample-cal \
-e UIARESULTSPATH /Users/mj/Desktop/apps \
-e UIASCRIPT /Users/mj/Desktop/apps/_run_loop.js
6 von 10 Zeiten funktioniert es. Im Falle eines Fehlers erhalte ich die folgende Meldung:
2013-10-07 16:45:51.553 instruments[9891:1207] unable to locate CFBundleIdentifier for path: LPSimpleExample-cal
2013-10-07 16:45:51.555 instruments[9891:1207] Recording cancelled : At least one target failed to launch; aborting run
Instruments Trace Error : Error Domain=com.apple.instruments Code=1 "Error Starting Recording" UserInfo=0x7faccbef8fa0 {NSLocalizedDescription=Error Starting Recording, NSLocalizedRecoverySuggestion=At least one target failed to launch; aborting run}
Instruments Trace Error : Failed to start trace.
Für mich sieht es aus, dass die Instrumente hier einen Fehler hat. Ich habe versucht, die App über 100 Mal in verschiedenen Szenarien zu starten, und ich kann ein Fehlermuster nicht analysieren. Das Gerät Crashlog sagt:
Process: DTMobileIS [34956]
Path: /Developer/Library/Daemons/DTMobileIS
Identifier: DTMobileIS
Version: ??? (???)
Code Type: ARM (Native)
Parent Process: lockbot [34938]
Date/Time: 2013-10-07 15:29:05.474 -0700
OS Version: iOS 6.1.3 (10B329)
Report Version: 104
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x00000000
Ausnahmetyp EXC_BAD_ACCESS (SIGSEGV)
zeigt an, dass ein Objekt, das zugegriffen wird immer bereits freigegeben wurde. A SIGSEGV
ist ein Segmentierungsfehler, dh Sie versuchen, auf eine ungültige Speicheradresse zuzugreifen. Referenz: Exception Types in iOS crash logs
Statt die bundleIdentifier die Verwendung Ich habe auch versuchte den vollen App Pfad oder den vollständigen bundleIdentifier angeben:
# with full app path
instruments \
-w c717fa22472d7b691ae5763af90e1e44244ad85a \
-t /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate \
-D "/Users/mj/Desktop/apps/trace" \
/Users/mj/Desktop/apps/LPSimpleExample-cal.app \
-e UIARESULTSPATH /Users/mj/Desktop/apps \
-e UIASCRIPT /Users/mj/Desktop/apps/_run_loop.js
# with full bundleIdentifier
instruments \
-w c717fa22472d7b691ae5763af90e1e44244ad85a \
-t /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate \
-D "/Users/mj/Desktop/apps/trace" \
/Users/mj/Desktop/apps/LPSimpleExample-cal.app \
-e UIARESULTSPATH /Users/mj/Desktop/apps \
-e UIASCRIPT /Users/mj/Desktop/apps/_run_loop.js
Konfigurationsdetails
- Instruments Version: 5.0 (51166)
- XCode-Version: 5.0 (5A1413)
- Gerätetypen: iPhon e 5 - 6.1.3, iPhone 5C - 7,02, iPhone 5S - 7.0.2
Hat Informationen mehr jemand in welchen Fällen Instrumente nicht eine App auf dem Gerät starten können oder wenn Sie erhalten die Fehlermeldung unable to locate CFBundleIdentifier for path: LPSimpleExample-cal
?
Ich habe ein ähnliches Problem, lassen Sie mich wissen, wenn Sie irgendwo http://stackoverflow.com/questions/19234031/launching-xcode-4-instruments-not-the-xcode-5-version-for-uiautomation – Jules
Ich halte dich auf dem Laufenden. Ihr stackoverflow-Post ist nicht mehr öffentlich. –