Webdriver connect timeout

I am assuming that since there is no documented timeout when making the call to the webdriver (I’m using python bindings), that some sensible default timeout is used or that the newCommandTimeout capability gets used instead?

It’s like I’m missing some obvious documentation or that the defaults are obfuscated or I have managed to get the driver into a unusual state?

I am starting the server on 127.0.0.1 on port 4743,
When I open the driver connection, it starts the xcode build, but 10 minutes later xcode is still running in background, it’s not really running, but the process is still present. The build literally takes a minute, so something in the logic that spins up xcode is borked? if I kill xcode, the logs come back with “build success” , and the driver gives an error message , so something is causing a hang? why is the build not timing out? Oh this code was working fine on Thursday for some reason after rebooting, I’m hitting a knowledge gap.

Sounds like an environmental issue. What version of Xcode? Also, in Xcode make sure the command line utilities are set correctly.

1 Like

Sorted for now.
I have now hard-coded the --address 127.0.0.1 parameter to the server, I previously omitted that, (it defaults to bind to 0.0.0.0 , which is probably a firewalling problem as a result)
I also was previously trying to connect to the “local” 192. ip address, and changed that from the locally resolved to 127.0.0.1 as well, that seems to then time out after a few minutes instead of hanging around. Somehow it seems to me as if an xcode update and reboot has helped. It’s fun because I’m resurrecting some old code that has a lot of catching up to do, lots of fixes and lots of “unit-testing” has had to be added to stop this happening to me again.

I have to make a ticket to force the toolchain version, in our lab the machines have multiple xcode versions, good reminder to do that there.

/edit: I somehow managed to uninstall all npm packages when trying to update - brilliant. And picked up one other pointer after re-installing them all. Because I am using a sudo account to spawn the server. I had to (after reinstalling node for some reason) also add 2 lines to my sudoers file

sudo visudo

Defaults env_keep += "ANDROID_HOME"
Defaults env_keep += "JAVA_HOME"

else the server kept erroring saying I had not set the env variables in the sudo profile. Hope this helps the next person who uses a remoting agent that has sudo permissions