Sauce Labs ‘Not Found’

2009 July 13
by mattc

Saucelabs is a cunning idea. Running Selenium RC (the Selenium HTTP API) off some EC2 instances means I don’t need to build and maintain my own functional test boxes.

It cost me about $0.02 to run my first simple test and when I have a 50 tests running each night of various complexity I guess is going to cost perhaps $3 or $4 a day, which isn’t a lot for the hassle of avoiding purchase/maintenance of a little farm of selenium boxes. It’s peanuts compared to developer time, who I’d rather pay to write tests than maintain infrastructure.

The only problem I found was an unhelpful error message sent from the RC server when my Selenium client supplied it bad credentials.

Not Found
com.thoughtworks.selenium.HttpCommandProcessor.getCommandResponse(HttpCommandProcessor.java:124)

The problem in my case was twofold. Firstly I’d cut and pasted the Saucelabs access-key incorrectly causing an authentication error (my fault) and secondly, for some reason, I quoted the browser string in my Ant properties file with single quotes which caused ResourcesBundle to read and pass the complete string (quotes intact) to the RC server, ie.

selenum.server=saucelabs
selenum.port=4444
selenium.browser='{"username": "bbc_labuk", "access-key": "xxx", "os": ... }'
...

Why did I do that? My fault again I suppose. Or maybe ResourceBundle should strip quoted properties?

Either way, when Saucelabs RC server doesn’t like the smell of your browser string it will give you a ‘Not Found’ error and it confused me for the best part of an afternoon - ‘Not Found’ being very synonymous with a certain other class of HTTP error.

Updated.

John from Saucelabs has been in touch. Error messages is something they are ‘investing more attention’ too in the near future, so stay tuned!

Comments are closed.