From 12039a0e63377e86fa1b5adc3d327d6e07f23a32 Mon Sep 17 00:00:00 2001 From: Aleksandr Nogikh Date: Fri, 26 Sep 2025 15:24:20 +0200 Subject: pkg/osutil: make VerboseError nest other errors After this change it fits more naturally into the Go's error functionality. --- vm/vmimpl/util.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'vm/vmimpl/util.go') diff --git a/vm/vmimpl/util.go b/vm/vmimpl/util.go index 2df514ac6..729e78de6 100644 --- a/vm/vmimpl/util.go +++ b/vm/vmimpl/util.go @@ -57,7 +57,10 @@ func WaitForSSH(timeout time.Duration, opts SSHOptions, OS string, stop chan err log.Logf(0, "ssh failed: %v", err) } if time.Since(startTime) > timeout { - return &osutil.VerboseError{Title: "can't ssh into the instance", Output: []byte(err.Error())} + return &osutil.VerboseError{ + Err: fmt.Errorf("can't ssh into the instance"), + Output: []byte(err.Error()), + } } } } -- cgit mrf-deployment