Skip to content

Commit 0cc5e8c

Browse files
committed
sq
Signed-off-by: Egor Lazarchuk <[email protected]>
1 parent eca7d56 commit 0cc5e8c

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

tests/host_tools/network.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,13 @@ def __init__(self, netns, ssh_key: Path, host, user, *, on_error=None):
5858
# _init_connection loops until it can connect to the guest
5959
# dumping debug state on every iteration is not useful or wanted, so
6060
# only dump it once if _all_ iterations fail.
61-
self._init_connection()
61+
try:
62+
self._init_connection()
63+
except Exception as exc:
64+
if on_error:
65+
on_error(exc)
66+
67+
raise
6268

6369
self._on_error = on_error
6470

0 commit comments

Comments
 (0)