SeleniumServer.py isn't incrementing "waiting" variable inside start_server()
Closed this issue · 1 comments
Lines 64-75 of /Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/py.saunter-0.5-py2.7.egg/saunter/SeleniumServer.py use a variable named "waiting" inside the start_server function. However, it's never getting incremented which allows one to experience a totally silent infinite loop if the Selenium server process doesn't start up earlier in the function. Here are the problematic lines:
make sure the server is actually up
server_up = False
waiting = 0
while server_up == False and waiting < 60:
try:
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect(("localhost", 4444))
s.close()
server_up = True
except socket.error:
time.sleep(1)
server_up = False
return server_up
In my case, I was having problems getting my own tests (which are based on the original python-selenium-pageobjects) to run in py.saunter so I backed up to trying the ebay example from github. The test was not working with Firefox 6.0, so I figured I'd try updating the .jar file in third_party/selenium to the latest version. At that point, since SeleniumServer.py expects to start up selenium-server-standalone-2.0b2.jar (which I had deleted before putting the latest version in third_party/selenium), I got an infinite silent loop.
Already fixed. Will be in 0.6