Debug Emacs Lisp code the hard way
I met some issue when using helm several days ago.
With the help from Michael Heerdegen, I can locate the line error message is dumped.
But the problem is I cannot get the backtrace at all.
So I insert some backtrace printing code above that line and "M-x eval-buffer":
(with-output-to-temp-buffer "backtrace-output" (let ((var 1)) (save-excursion (setq var (eval '(progn (1+ var) (list 'testing (backtrace))))))))
It turns out that some third party package I installed changes the emacs variable "display-buffer-function". I guess that's why the backtrace is blocked. Because backtrace is usually dumped into a backtrace buffer. And backtrace buffer's is actually influenced by the variable.