diff --git a/lisp/gnus/gnus-util.el b/lisp/gnus/gnus-util.el index a777157f89..58edc55877 100644 --- a/lisp/gnus/gnus-util.el +++ b/lisp/gnus/gnus-util.el @@ -511,15 +511,10 @@ gnus-final-warning (mapconcat #'identity gnus-action-message-log "; ")))) (defun gnus-error (level &rest args) - "Beep an error if LEVEL is equal to or less than `gnus-verbose'. + "Log an error if LEVEL is equal to or less than `gnus-verbose'. ARGS are passed to `message'." (when (<= (floor level) gnus-verbose) - (apply #'message args) - (ding) - (let (duration) - (when (and (floatp level) - (not (zerop (setq duration (* 10 (- level (floor level))))))) - (sit-for duration)))) + (delay-warning '(gnus) (apply #'message args) :warning "*Gnus Log*")) nil) (defun gnus-split-references (references) @@ -1252,6 +1247,16 @@ gnus-create-info-command (setq gnus-info-buffer (current-buffer)) (gnus-configure-windows 'info))) +(defun gnus-display-log () + "Pop up a window displaying the *Gnus Log* buffer." + (interactive) + ;; We just use plain `display-buffer' here. If the user wants to + ;; compose the log buffer as part of a Gnus window configuration, + ;; they can do that in `gnus-buffer-configuration'. If they want to + ;; control how this display works, they can configure + ;; `display-buffer-alist'. + (display-buffer "*Gnus Log*")) + (defun gnus-not-ignore (&rest _args) t) diff --git a/lisp/gnus/gnus-win.el b/lisp/gnus/gnus-win.el index 8ac4e39fa5..9fafe88bcf 100644 --- a/lisp/gnus/gnus-win.el +++ b/lisp/gnus/gnus-win.el @@ -188,6 +188,7 @@ gnus-window-to-buffer (score-trace . "*Score Trace*") (split-trace . "*Split Trace*") (info . gnus-info-buffer) + (log . "*Gnus Log*") (category . gnus-category-buffer) (article-copy . gnus-article-copy) (draft . gnus-draft-buffer) diff --git a/lisp/gnus/gnus.el b/lisp/gnus/gnus.el index 6644cc4d81..c162b58d22 100644 --- a/lisp/gnus/gnus.el +++ b/lisp/gnus/gnus.el @@ -48,6 +48,11 @@ gnus-spam-resend-to (defvar gnus-ham-resend-to) (defvar gnus-spam-process-newsgroups) +;; We suppress the display of all Gnus warnings: they go to a separate +;; buffer, and should only be displayed as part of Gnus' own window +;; display routines (or explicitly with `gnus-display-log'). + +(cl-pushnew 'gnus warning-suppress-types) (defgroup gnus nil "The coffee-brewing, all singing, all dancing, kitchen sink newsreader." diff --git a/lisp/gnus/mail-source.el b/lisp/gnus/mail-source.el index af0a198376..c2ec48cc86 100644 --- a/lisp/gnus/mail-source.el +++ b/lisp/gnus/mail-source.el @@ -554,18 +554,15 @@ mail-source-fetch (condition-case err (funcall function source callback) (error - (if (and (not mail-source-ignore-errors) - (not - (yes-or-no-p - (format "Mail source %s error (%s). Continue? " - (if (memq ':password source) - (let ((s (copy-sequence source))) - (setcar (cdr (memq ':password s)) - "********") - s) - source) - (cadr err))))) - (error "Cannot get new mail")) + (unless mail-source-ignore-errors + (error "Mail source %s error (%s)" + (if (memq ':password source) + (let ((s (copy-sequence source))) + (setcar (cdr (memq ':password s)) + "********") + s) + source) + (cadr err))) 0))))))))) (declare-function gnus-message "gnus-util" (level &rest args)) diff --git a/lisp/gnus/nnmail.el b/lisp/gnus/nnmail.el index bcf01cfa9e..a9a778f458 100644 --- a/lisp/gnus/nnmail.el +++ b/lisp/gnus/nnmail.el @@ -1842,7 +1842,7 @@ nnmail-get-new-mail-1 src))) ansym)))) ((error quit) - (message "Mail source %s failed: %s" source cond) + (gnus-error 5 cond) 0))) (cl-incf total new) (cl-incf i)))