From c47f1d42abbb25af583384a3cb0ca17e8bcd61df Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Sat, 8 Nov 2025 16:58:14 -0600 Subject: refactor: debug: route all debug output to debug log instead of Messages - Remove (message ...) call from wttrin--debug-log function - Replace 9 debug message calls in wttrin.el with wttrin--debug-log - All debug output now goes to debug log for review with M-x wttrin-debug-show-log - User-facing error messages preserved (network errors, processing errors) - Updated docstring to clarify messages are stored for later review --- wttrin-debug.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'wttrin-debug.el') diff --git a/wttrin-debug.el b/wttrin-debug.el index dd08a5a..a0576a4 100644 --- a/wttrin-debug.el +++ b/wttrin-debug.el @@ -112,12 +112,12 @@ It creates the *wttrin-mode-debug* buffer with diagnostic information." (defun wttrin--debug-log (format-string &rest args) "Log a debug message if wttrin-debug is enabled. -FORMAT-STRING and ARGS are passed to `format'." +FORMAT-STRING and ARGS are passed to `format'. +Messages are stored in `wttrin--debug-log' for later review." (when wttrin-debug (let ((msg (apply #'format format-string args)) (timestamp (format-time-string "%H:%M:%S.%3N"))) - (push (cons timestamp msg) wttrin--debug-log) - (message "[wttrin-debug %s] %s" timestamp msg)))) + (push (cons timestamp msg) wttrin--debug-log)))) ;;;###autoload (defun wttrin-debug-clear-log () -- cgit v1.2.3