From: Ben Vishny on 7 Feb 2010 17:36 Hi all, I am using a begin.. rescue.. else block to catch a timeout and try again until it succeeds. Despite the rescue block, the program still crashes due to a timeout error. Don't rescue blocks catch everything? success = false while success == false begin output2 = exportForm.click_button(exportForm.buttons[3]) rescue Timeout::Error output "Timeout.. waiting 5s then trying again" sleep(5) else success = true end end Thanks, Ben -- Posted via http://www.ruby-forum.com/.
|
Pages: 1 Prev: Monkeybars dead? Next: Issue during multiple calls to C embedded Ruby with dlopen |