I have a mechanize function to log me out of a site but on very rare occasions it times me out. The function involves going to a specific page, and then clicking on a logout
Using mechanize 1.0.0 I got this problem from a different source of error.
In my case I was blocked by proxy and then SSL. This worked for me:
ag = Mechanize.new ag.set_proxy('yourproxy', yourport) ag.agent.http.verify_mode = OpenSSL::SSL::VERIFY_NONE ag.get( url )