Catch EHOSTUNREACH as expected#79
Conversation
Signed-off-by: Kostiantyn Kostiuk <kkostiuk@redhat.com>
There was a problem hiding this comment.
Code Review
This pull request updates the handle_action_exceptions method in lib/rtoolsHCK.rb to rescue Errno::EHOSTUNREACH in addition to RToolsHCKError and Errno::ECONNREFUSED, allowing the action wrapper to retry on network issues or machine reboots. There are no review comments, and I have no feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
There was a problem hiding this comment.
Pull request overview
This PR updates the action exception wrapper in RToolsHCK to treat Errno::EHOSTUNREACH as an expected, handled failure (similar to Errno::ECONNREFUSED), allowing higher-level retry behavior to proceed without surfacing an unhandled exception.
Changes:
- Add
Errno::EHOSTUNREACHto the list of rescued exceptions inhandle_action_exceptions. - Add an explanatory inline comment describing when
EHOSTUNREACHcan occur.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| # We can have ECONNREFUSED error due to direct connection to | ||
| # clients instead of proxy through studio | ||
| # We can have EHOSTUNREACH error due to network issues or machine rebooting | ||
| # Safety catch this exception, the action wrapper will retry if needed | ||
| rescue RToolsHCKError, Errno::ECONNREFUSED => e | ||
| rescue RToolsHCKError, Errno::ECONNREFUSED, Errno::EHOSTUNREACH => e |
No description provided.