                   ;; Add full path of user-dir.
                   (setq plist (plist-put plist :executable executable))
                   (setq plist (plist-put plist :user-dir temp-dir))))
-         (program (let ((print-level nil)
-                        (print-length nil))
-                    (pp-to-string
-                     ;; The top-level `let' is an intentional local
-                     ;; variable binding. We want users of
-                     ;; `straight-bug-report' to have access to their
-                     ;; args within :pre/:post-bootstrap programs. Since
-                     ;; we are binding with the package namespace, this
-                     ;; should not overwrite other user bindings.
-                     (append `(let ((straight-bug-report-args ',pargs)))
-                             `((setq user-emacs-directory ,temp-dir))
-                             straight-bug-report--setup
-                             (alist-get :pre-bootstrap keywords)
-                             straight-bug-report--bootstrap
-                             (alist-get :post-bootstrap keywords))))))
+         (program
+          (let ((print-level nil)
+                (print-length nil))
+            (pp-to-string
+             ;; The top-level `let' is an intentional local
+             ;; variable binding. We want users of
+             ;; `straight-bug-report' to have access to their
+             ;; args within :pre/:post-bootstrap programs. Since
+             ;; we are binding with the package namespace, this
+             ;; should not overwrite other user bindings.
+             (append
+              '(with-demoted-errors "Error: %S")
+              `(,(append
+                  `(let ((straight-bug-report-args ',pargs)))
+                  `((setq user-emacs-directory ,temp-dir))
+                  straight-bug-report--setup
+                  (alist-get :pre-bootstrap keywords)
+                  straight-bug-report--bootstrap
+                  `(,(append
+                      '(unwind-protect)
+                      `((progn ,@(alist-get :post-bootstrap keywords)))
+                      '((message
+                         "Packages:\n%s\n"
+                         (straight-bug-report--format-package-info
+                          (straight-bug-report-package-info)))))))))))))
     `(let* ((,preserve-files    ,(car (alist-get :preserve keywords)))
             (,interactive       ,(car (alist-get :interactive keywords)))
             (,emacs-executable  ,executable)

        (setq recipes (nconc recipes (straight-recipes
                                      'list source cause)))))))

;;;;;; Org
(defcustom straight-byte-compilation-buffer "*straight-byte-compilation*"
  "Name of the byte compilation log buffer.

  1)

;;;;; Recipe conversion

(defvar straight--build-keywords '(:build
                                   :files
