获得';Posix生成失败';错误-Appium iOS

获得';Posix生成失败';错误-Appium iOS,ios,iphone,automation,ios-simulator,appium,Ios,Iphone,Automation,Ios Simulator,Appium,我正在尝试在Appium iOS中使用Java为一个应用程序运行自动化脚本 当我在模拟器上运行时,出现以下错误- info: Attempting to retry launching instruments, this is retry #1 info: Attempting to run app on iPhone Retina (4-inch) - Simulator - iOS 7.1 info: Spawning instruments with command: /Appl

我正在尝试在Appium iOS中使用Java为一个应用程序运行自动化脚本

当我在模拟器上运行时,出现以下错误-

info: Attempting to retry launching instruments, this is retry #1
info: Attempting to run app on iPhone Retina (4-inch) - Simulator - iOS 7.1

info: Spawning instruments with command:     /Applications/Xcode.app/Contents/Developer/usr/bin/instruments -t /Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/PlugIns/AutomationInstrument.bundle/Contents/Resources/Automation.tracetemplate -w iPhone Retina (4-inch) - Simulator - iOS 7.1 /Users/abc/Desktop/smriti/iPhoneSimulator/AppIOS.app -e UIASCRIPT /Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-uiauto/uiauto/bootstrap.js -e UIARESULTSPATH /tmp/appium-instruments
info: And extra without-delay env: {"DYLD_INSERT_LIBRARIES":"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-instruments/thirdparty/iwd/InstrumentsShim.dylib","LIB_PATH":"/Applications/Appium.app/Contents/Resources/node_modules/appium/node_modules/appium-instruments/thirdparty/iwd"}
info: And launch timeout: 90000ms

info: [INST STDERR] posix spawn failure; aborting launch (binary == /Users/abc/Desktop/smriti/iPhoneSimulator/AppIOS.app/AppIOS).

info: [INST STDERR] Instruments Trace Error : Error Starting Recording
然后尝试在真实设备上运行,然后出现以下错误:

info: Installing ipa found at AppIOS.ipa
info: Creating iDevice object with udid 3daa1240e495c84e8878996649301fd9759a07df
info: Couldn't find ideviceinstaller, trying built-in at /Applications/Appium.app/Contents/Resources/node_modules/appium/build/libimobiledevice-macosx/ideviceinstaller

info: Cleaning up appium session

error: Failed to start an Appium session, err was: Error: Command failed: dyld: Library not loaded: @executable_path/../lib/libimobiledevice.3.dylib
Referenced from: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/libimobiledevice-macosx/ideviceinstaller
Reason: image not found


info: Error: Command failed: dyld: Library not loaded: @executable_path/../lib/libimobiledevice.3.dylib
Referenced from: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/libimobiledevice-macosx/ideviceinstaller
Reason: image not found

at ChildProcess.exithandler (child_process.js:637:15)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:743:16)
at Socket.<anonymous> (child_process.js:956:11)
at Socket.EventEmitter.emit (events.js:95:17)
at Pipe.close (net.js:465:12)

info: Responding to client with error: {"status":33,"value":{"message":"A new session could not be created. (Original error: Command failed: dyld: Library not loaded: @executable_path/../lib/libimobiledevice.3.dylib\n  Referenced from: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/libimobiledevice-macosx/ideviceinstaller\n  Reason: image not found\n)","killed":false,"code":null,"signal":"SIGTRAP","origValue":"Command failed: dyld: Library not loaded: @executable_path/../lib/libimobiledevice.3.dylib\n  Referenced from: /Applications/Appium.app/Contents/Resources/node_modules/appium/build/libimobiledevice-macosx/ideviceinstaller\n  Reason: image not found\n"},"sessionId":null}
POST /wd/hub/session 500 4286ms - 714b
信息:安装在AppIOS.ipa上的ipa
信息:使用udid 3daa1240e495c84e8878996649301fd9759a07df创建iDevice对象
信息:找不到ideviceinstaller,正在尝试内置的/Applications/Appium.app/Contents/Resources/node_modules/Appium/build/libimobiledevice-macosx/ideviceinstaller
信息:正在清理应用程序会话
错误:无法启动Appium会话,错误为:错误:命令失败:dyld:未加载库:@executable_path/。/lib/libimobiledevice.3.dylib
引用自:/Applications/Appium.app/Contents/Resources/node_modules/Appium/build/libimobiledevice-macosx/ideviceinstaller
原因:找不到图像
信息:错误:命令失败:dyld:未加载库:@executable_path/。/lib/libimobiledevice.3.dylib
引用自:/Applications/Appium.app/Contents/Resources/node_modules/Appium/build/libimobiledevice-macosx/ideviceinstaller
原因:找不到图像
在ChildProcess.exithandler(child_process.js:637:15)
在ChildProcess.EventEmitter.emit(events.js:98:17)
在maybeClose(child_process.js:743:16)
在插座上。(child_process.js:956:11)
位于Socket.EventEmitter.emit(events.js:95:17)
at Pipe.close(net.js:465:12)
信息:响应客户端时出现错误:{“状态”:33,“值”:{“消息”:“无法创建新会话”。(原始错误:命令失败:dyld:Library未加载:@executable_path/。/lib/libimobiledevice.3.dylib\n引用自:/Applications/Appium.app/Contents/Resources/node_modules/Appium/build/libimobiledevice macosx/ideviceinstaller\n原因:找不到图像\n)”,“killed”:false,“code”:null,“SIGTRAP”,“origValue”:“命令失败:dyld:Library未加载:@executable\u path/。/lib/libimobiledevice.3.dylib\n引用自:/Applications/Appium.app/Contents/Resources/node\u modules/Appium/build/libimobiledevice macosx/ideviceinstaller\n原因:找不到映像\n”},“sessionId”:null}”
POST/wd/hub/会话500 4286ms-714b
然后,当我在真实设备上运行时,我点击“I”启动Appium inspector->它启动了我的应用程序,然后应用程序崩溃

任何帮助都将不胜感激


谢谢!

看看这两个线程中的建议

或者这个:

您不应该尝试在模拟器上安装IPA文件。
好吧,它们是为ARM处理器而设计的,只能在iOS设备上运行。

你解决了吗???以防万一,有人也在苦苦挣扎:我通过将平台版本从我想要的功能中移除,解决了这个非常烦人和令人沮丧的问题。