diff --git a/cmd/d2/watch.go b/cmd/d2/watch.go index 1680a2521..669a24a6e 100644 --- a/cmd/d2/watch.go +++ b/cmd/d2/watch.go @@ -332,7 +332,7 @@ func (w *watcher) compileLoop(ctx context.Context) error { if filepath.Ext(w.outputPath) == ".png" && !w.pw.Browser.IsConnected() { newPW, err := w.pw.RestartBrowser() if err != nil { - broadcastErr := fmt.Errorf("issue encountered with PNG exporter, stopping") + broadcastErr := fmt.Errorf("issue encountered with PNG exporter: %w", err) w.ms.Log.Error.Print(broadcastErr) w.broadcast(&compileResult{ Err: broadcastErr.Error(),