新手区 Appium,iOS 真机启动 Inspector 起不来,卡在 Creating iDevice object with udid...那一段时间不往下执行,然后就弹报错框了

朱泉 · 2016年03月10日 · 最后由 小灰 回复于 2016年04月27日 · 2109 次阅读

Appium 1.4.13,真机 iPhone6 iOS9.2.1 已安装测试 App,Appium 上启动 Inspector 起不来,卡在 Creating iDevice object with udid...那一段时间不往下执行,然后就弹报错框了,求帮忙解决,谢谢


目前情况:Xcode 使用的是自己的 AppleID(非开发账号)build 到真机上的,且已用 Instruments->UI Automation 真机运行过的。

iOS Settings 如下图:

启动 Inspector 报错截图:

info: [debug] App is an iOS bundle, will attempt to run as pre-existing
info: [debug] Creating new appium session cec429dd-f477-4dbb-bcc3-0f06f21ce88a
info: [debug] Removing any remaining instruments sockets
info: [debug] Cleaned up instruments socket /tmp/instruments_sock
info: [debug] Auto-detecting iOS udid...
info: [debug] Not auto-detecting udid, running on sim
info: [debug] Could not parse plist file (as binary) at /Applications/Appium.app/Contents/Resources/node_modules/appium/com.chaomo.app/en.lproj/Localizable.strings
info: Will try to parse the plist file as XML
info: [debug] Could not parse plist file (as XML) at /Applications/Appium.app/Contents/Resources/node_modules/appium/com.chaomo.app/en.lproj/Localizable.strings
warn: Could not parse app Localizable.strings assuming it doesn't exist
info: [debug] Creating instruments
info: [debug] Preparing uiauto bootstrap
info: [debug] Dynamic bootstrap dir: /Users/zhuquan/Library/Application Support/appium/bootstrap
info: [debug] Dynamic env: {"nodePath":"/Applications/Appium.app/Contents/Resources/node/bin/node","commandProxyClientPath":"/Applications/Appium.app/Contents/Resources/node_modules/appium/submodules/appium-uiauto/bin/command-proxy-client.js","instrumentsSock":"/tmp/instruments_sock","interKeyDelay":null,"justLoopInfinitely":false,"autoAcceptAlerts":false,"autoDismissAlerts":false,"sendKeyStrategy":"grouped"}

info: [debug] Dynamic bootstrap code: // This file is automatically generated. Do not manually modify!
...
info: [debug] Dynamic bootstrap path: /Users/zhuquan/Library/Application Support/appium/bootstrap/bootstrap-5923cadea0343e3f.js
info: [debug] Reusing dynamic bootstrap: /Users/zhuquan/Library/Application Support/appium/bootstrap/bootstrap-5923cadea0343e3f.js
info: [debug] Attempting iOS device log capture via libimobiledevice idevicesyslog

info: [debug] Creating iDevice object with udid 7f5d1c1cb5e7ea8046052b0c52d371e24fa0a8c3

共收到 11 条回复 时间 点赞

请使用 markdown。

新人请阅读:https://testerhome.com/topics/982
学会如何合理提问,请阅读:https://testerhome.com/topics/587

@monkey 现在可以吗,谢谢

@lihuazhang 能帮忙解决下吗,谢谢

#3 楼 @zhuquan0814 解决不了,从日志来看,没有任何错误。

晕啊

@zhuquan0814
沒在 Max 上玩過 GUI,不過英文大致上是找不到真機,然後啟動虛擬,然後找不到該 APP。我想用「appium ios 實機操作」去 google 一下,應該可以找到解答吧。

启动服务后稍等一会,等应用起来了,再启动 inspector。

可能的解决办法: 拔掉连接 Mac 的 USB 线,重启 Appium,再插上手机数据线,再跑脚本看看。

#8 楼 @b_88 他不是为了跑脚本 是为了启动 inspector

自己装下 libimobiledevice 试试,

brew install libimobiledevice

若还有问题, 尝试将 Appium (app) 中 iOS setting > Advanced > "Use Native Instrument Library" 挑上

请问最后解决了吗

需要 登录 后方可回复, 如果你还没有账号请点击这里 注册