Current time: 12-15-2017, 04:58 AM Hello There, Guest! (LoginRegister)

Post Reply 
 
Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
To test IOS devices
09-16-2015, 03:11 AM
Post: #11
RE: To test IOS devices
Oh yeah, you're not going to have a good time if you try to use Windows. Not only the ssh but also the ios_webkit_debug_proxy doesn't work on Windows. Linux and Mac OSX are the only supported platforms and only Mac OSX can be used if you want video capture.
Visit this user's website Find all posts by this user
Quote this message in a reply
09-17-2015, 05:38 AM (This post was last modified: 09-17-2015 05:53 AM by matthew.)
Post: #12
RE: To test IOS devices
(09-16-2015 03:11 AM)pmeenan Wrote:  Oh yeah, you're not going to have a good time if you try to use Windows. Not only the ssh but also the ios_webkit_debug_proxy doesn't work on Windows. Linux and Mac OSX are the only supported platforms and only Mac OSX can be used if you want video capture.

Thanks for your advise.
I set up a Mac host today following the documentation. It looks everything work fine, except a timeout debug information.
My web server is able to list my iPad in the location dropdownlist, and saying my test is on the front of the queue, but can't proceed the test.
I can't see the browser being opened on the iPad.

Here is the output from my Terminal on Mac:
Quote:node --max-old-space-size=4096 --expose-gc src/agent_main --serverUrl http://myurl.net --location Ipad --browser browser_ios.BrowserIos --deviceSerial 395d0d4e30d832a2b94c0fb6fac9cd6999064698 --captureDir /Users/c_liu/webpagetest/agent/js/lib/capture --iosIDeviceDir /Users/c_liu/webpagetest/agent/js/lib/ios/idevice/Darwin x86_64 --iosDevImageDir /Users/c_liu/webpagetest/agent/js/lib/ios/DeviceSupport --iosSshProxyDir /Users/c_liu/webpagetest/agent/js/lib/ios/usbmux_python_client --iosVideoDir /Users/c_liu/webpagetest/agent/js/lib/ios/video --iosUrlOpenerApp /Users/c_liu/webpagetest/agent/js/lib/ios/openURL/openURL*.ipa --processvideo yes
D Sep_16_15:10:02.432 browser_base.js:141 createBrowser : Creating browser browser_ios.BrowserIos
I Sep_16_15:10:02.453 browser_ios.js:58 new BrowserIos : BrowserIos({"flags":{"serverUrl":"http://myurl.net","location":"Ipad","browser":"browser_ios.BrowserIos","deviceSerial":"395d0d4e30d832a2b94c0fb6fac9cd6999064698","captureDir":"/Users/c_liu/webpagetest/agent/js/lib/capture","iosIDeviceDir":"/Users/c_liu/webpagetest/agent/js/lib/ios/idevice/Darwin x86_64","iosDevImageDir":"/Users/c_liu/webpagetest/agent/js/lib/ios/DeviceSupport","iosSshProxyDir":"/Users/c_liu/webpagetest/agent/js/lib/ios/usbmux_python_client","iosVideoDir":"/Users/c_liu/webpagetest/agent/js/lib/ios/video","iosUrlOpenerApp":"/Users/c_liu/webpagetest/agent/js/lib/ios/openURL/openURL*.ipa","processvideo":"yes"},"task":{}})
D Sep_16_15:10:02.481 process_utils.js:487 unknown : Calling Make dirs
D Sep_16_15:10:02.483 process_utils.js:481 cb : Callback for Make dirs
D Sep_16_15:10:02.495 process_utils.js:487 unknown : Calling Work read
D Sep_16_15:10:02.497 process_utils.js:481 cb : Callback for Work read
D Sep_16_15:10:02.550 process_utils.js:263 unknown : Exec with timeout(10000): ssh -F /dev/null -i /Users/c_liu/.ssh/id_dsa_ios -o 'ProxyCommand="/Users/c_liu/webpagetest/agent/js/lib/ios/usbmux_python_client/sshproxy.py" -u %h' -o 'User=root' 395d0d4e30d832a2b94c0fb6fac9cd6999064698 'echo show State:/Network/Interface/en0/IPv4|scutil'
D Sep_16_15:10:02.893 process_utils.js:327 ChildProcess.<anonymous> : stdout[177] <dictionary> {
Addresses : <array> {
0 : 10.100.40.54
}
BroadcastAddresses : <array> {
0 : 10.100.43.255
}
SubnetMasks : <array> {
0 : 255.255.252.0
}
}
, stderr[161] Connecting to device <MuxDevice: ID 1 ProdID 0x12ab Serial '395d0d4e30d832a2b94c0fb6fac9cd6999064698' Location 0x1d110000>
Connection established, relaying data
D Sep_16_15:10:02.900 process_utils.js:263 unknown : Exec with timeout(10000): ssh -F /dev/null -i /Users/c_liu/.ssh/id_dsa_ios -o 'ProxyCommand="/Users/c_liu/webpagetest/agent/js/lib/ios/usbmux_python_client/sshproxy.py" -u %h' -o 'User=root' 395d0d4e30d832a2b94c0fb6fac9cd6999064698 killall MobileSafari
I Sep_16_15:10:03.236 wpt_client.js:490 Client.<anonymous> : Get work: http://myurl.net/work/getwork.php?locati...698&f=json

Is this timeout the problem?

Thanks,
Find all posts by this user
Quote this message in a reply
09-17-2015, 05:46 AM
Post: #13
RE: To test IOS devices
Is your server actually at "myurl.net"?

http://myurl.net/work/getwork.php?locati...698&f=json

If so, what does the locations.ini look like? Looks like the agent is working fine in talking to the device so now it's just making sure the config matches what is defined on the server.
Visit this user's website Find all posts by this user
Quote this message in a reply
09-17-2015, 06:12 AM (This post was last modified: 09-17-2015 07:14 AM by matthew.)
Post: #14
RE: To test IOS devices
(09-17-2015 05:46 AM)pmeenan Wrote:  Is your server actually at "myurl.net"?

http://myurl.net/work/getwork.php?locati...698&f=json

If so, what does the locations.ini look like? Looks like the agent is working fine in talking to the device so now it's just making sure the config matches what is defined on the server.

Nope, it's not my real url Tongue
But we can see it's in the good format, and my other devices are working fine Big Grin

Here is the Ipad part of my locations.ini
Quote:[locations]
11=Office

[Office]
1=Office_wpt
2=Mobile_Nexus5
3=Mobile_GalaxyS5
4=Ipad
label="Office (Chrome, Firefox, Canary, IE 11, Nexus5 - Chrome, Galaxy S5 - Chrome, Ipad)"

[Ipad]
browser="Ipad"
label="Ipad"
type="node.js,mobile"
connectivity="WiFi"

I just find my ipad safari browser can only stay open several seconds.
It's able to be closed by the script running on the host.

The bad part is the Ipad becomes to inactivated suddenly...
Office : Office (Chrome, Firefox, Canary, IE 11, Nexus5 - Chrome, Galaxy S5 - Chrome, Ipad)
Office_wpt : Office - 2 agents connected
Mobile_Nexus5 : Nexus 5 - 1 agents connected
Mobile_GalaxyS5 : Galaxy S5 - 1 agents connected
Ipad : Ipad - 274 minutes since last agent connected
Find all posts by this user
Quote this message in a reply
09-18-2015, 02:19 AM
Post: #15
RE: To test IOS devices
Do you see anything in the debug output on the terminal where the iOS agent is running to see why it may have gone offline? An unhandled exception, node crashing, etc? I run my agent in a while loop from bash to auto-restart it if it exited but there are also cases where sometimes it just gets wedged (been fixing those over the last week or two).
Visit this user's website Find all posts by this user
Quote this message in a reply
09-18-2015, 02:34 AM (This post was last modified: 09-18-2015 02:54 AM by matthew.)
Post: #16
RE: To test IOS devices
url: http://myrul.net/work/getwork.php?locati...698&f=json

I find the problem: I have key settings on my web server.
When the server get the request, the key parameter from url is null, but the key in my settings.ini is a 40 characters string.
So, my question will be how can I add key parameter into the url? I try to add --key, -key and --apiKey, but they won't work. ( apiKey works for my android devices)

(09-18-2015 02:19 AM)pmeenan Wrote:  Do you see anything in the debug output on the terminal where the iOS agent is running to see why it may have gone offline? An unhandled exception, node crashing, etc? I run my agent in a while loop from bash to auto-restart it if it exited but there are also cases where sometimes it just gets wedged (been fixing those over the last week or two).

Nothing more than a timeout message:
Quote:D Sep_16_15:10:02.900 process_utils.js:263 unknown : Exec with timeout(10000): ssh -F /dev/null -i /Users/c_liu/.ssh/id_dsa_ios -o 'ProxyCommand="/Users/c_liu/webpagetest/agent/js/lib/ios/usbmux_python_client/sshproxy.py" -u %h' -o 'User=root' 395d0d4e30d832a2b94c0fb6fac9cd6999064698 killall MobileSafari
Thanks for your advise. If something wrong happens, your loop is a good try.

--apiKey does work for sending request! I guess I made a typo on last try
Quote:Office : Office (Chrome, Firefox, Canary, IE 11, Nexus5 - Chrome, Galaxy S5 - Chrome, Ipad, iPhone)
Office_wpt : Office - 2 agents connected
Mobile_Nexus5 : Nexus 5 - 1 agents connected
Mobile_GalaxyS5 : Galaxy S5 - 1 agents connected
Ipad : Ipad - 1 agents connected

The test can proceed now, however, the result is always not successful...
Quote:The test completed but there were no successful results.
Let me try to find something from the output....
Find all posts by this user
Quote this message in a reply
09-18-2015, 06:14 AM (This post was last modified: 09-18-2015 06:21 AM by matthew.)
Post: #17
RE: To test IOS devices
I believe it's not a good experience to read the whole output Big Grin

I just take some suspicious parts from it:

Quote:...
D Sep_17_15:34:38.965 process_utils.js:263 unknown : Exec with timeout(10000): ./ipfw_config clear --device 395d0d4e30d832a2b94c0fb6ddd9cd6999064698
D Sep_17_15:34:39.010 process_utils.js:327 ChildProcess.<anonymous> : stderr[116] +++ /sbin/ipfw list
ipfw: socket: Operation not permitted
+++ /sbin/ipfw list
ipfw: socket: Operation not permitted
D Sep_17_15:34:39.665 browser_base.js:141 createBrowser : Creating browser browser_ios.BrowserIos
...
Connection established, relaying data
D Sep_17_15:34:40.083 process_utils.js:263 unknown : Exec with timeout(10000): '/Users/c_liu/webpagetest/agent/js/lib/ios/idevice/Darwin x86_64/ideviceinfo' -k ProductVersion -u 395d0d4e30d832a2b94c0fb6ddd9cd6999064698
D Sep_17_15:34:40.410 process_utils.js:327 ChildProcess.<anonymous> : stdout[4] 8.3
E Sep_17_15:34:40.426 wd_server.js:204 WebDriverServer.<anonymous> : Exception from "Run test": Error: Missing Xcode image: /Users/c_liu/webpagetest/agent/js/lib/ios/DeviceSupport/8.3/DeveloperDiskImage.dmg{,.signature}
D Sep_17_15:34:40.427 wd_server.js:205 WebDriverServer.<anonymous> : Error: Missing Xcode image: /Users/c_liu/webpagetest/agent/js/lib/ios/DeviceSupport/8.3/DeveloperDiskImage.dmg{,.signature}
at reject (/Users/c_liu/webpagetest/agent/js/src/browser_ios.js:138:46)
at BrowserIos.<anonymous> (/Users/c_liu/webpagetest/agent/js/src/browser_ios.js:154:13)
at FSReqWrap.cb [as oncomplete] (fs.js:226:19)
...
E Sep_17_15:34:40.589 wd_server.js:204 WebDriverServer.<anonymous> : Exception from "Capture Screen Shot": Error: '/Users/c_liu/webpagetest/agent/js/lib/ios/idevice/Darwin x86_64/idevicescreenshot' -u 395d0d4e30d832a2b94c0fb6ddd9cd6999064698 failed, code 255, stdout[153] Could not start screenshotr service! Remember that you have to mount the Developer disk image on your device if you want to use the screenshotr service.
D Sep_17_15:34:40.590 wd_server.js:205 WebDriverServer.<anonymous> : Error: '/Users/c_liu/webpagetest/agent/js/lib/ios/idevice/Darwin x86_64/idevicescreenshot' -u 395d0d4e30d832a2b94c0fb6ddd9cd6999064698 failed, code 255, stdout[153] Could not start screenshotr service! Remember that you have to mount the Developer disk image on your device if you want to use the screenshotr service.

at newError (/Users/c_liu/webpagetest/agent/js/src/process_utils.js:279:17)
at ChildProcess.<anonymous> (/Users/c_liu/webpagetest/agent/js/src/process_utils.js:325:23)
at ChildProcess.emit (events.js:110:17)
at maybeClose (child_process.js:1015:16)
at Socket.<anonymous> (child_process.js:1183:11)
at Socket.emit (events.js:107:17)
at Pipe.close (net.js:485:12)
...

I have copied /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform to /DeviceSupport to webpagetest/agent/js/lib/ios/DeviceSupport
and checked the subdirectories are like :
Quote:4.2 5.1 7.0 8.1
4.3 6.0 7.1 8.2 (12D508)
5.0 6.1 8.0

Maybe I need to update my Xcode.app somewhere....
But we can see it's also complaining an ipfw problem... Could you help me on it?

Thanks,
Find all posts by this user
Quote this message in a reply
09-24-2015, 04:58 AM
Post: #18
RE: To test IOS devices
I'm so happy to anounce:

after updated Xcode.app, and copied all the DeviceSupport files. My iPad is able to work!

Thanks Patrick
Find all posts by this user
Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)