1

Usually, when I get a backtrace, there is a line number.

Right now, I know where to fix this problem, but I don't understand why there is no line number I can jump to;)

Debugger entered--Lisp error: (invalid-function "L")
  ("L" "Protocol Link" entry (file+headline ,(file "~/agenda/org-protocol.org") "Inbox") "* %? [[%:link][%:description]] \nCaptured On: %U")
  (add-to-list 'org-capture-templates '("P" "Protocol" entry (file+headline ,(file "~/agenda/org-protocol.org") "Inbox") "* %^{Title}\nSource: %u, %c\n #+BEGIN_QUOTE\n%i\n#+END_QUOTE\n\n\n%?") ("L" "Protocol Link" entry (file+headline ,(file "~/agenda/org-protocol.org") "Inbox") "* %? [[%:link][%:description]] \nCaptured On: %U"))
  load-with-code-conversion("/home/b0ef/.emacs.d/emacsen.el" "/home/b0ef/.emacs.d/emacsen.el" nil nil)
  load-file("/home/b0ef/.emacs.d/emacsen.el")
  load-with-code-conversion("/home/b0ef/.emacs.d/init.el" "/home/b0ef/.emacs.d/init.el" t t)
  load("/home/b0ef/.emacs.d/init" noerror nomessage)
  startup--load-user-init-file(#f(compiled-function () #<bytecode -0xd44be122a7a0180>) #f(compiled-function () #<bytecode -0x1f3c61addc0b8a75>) t)
  command-line()
  normal-top-level()

5
  • 3
    Does this answer your question? Show line number on error
    – lawlist
    Commented Nov 26, 2023 at 2:19
  • In /home/b0ef/.emacs.d/emacsen.el, you are adding to org-capture-templates two items (which is wrong in itself: the function can only add a single element to the list), but the second item is not quoted, so Emacs tries to evaluate it as a function call and fails.
    – NickD
    Commented Nov 26, 2023 at 3:37
  • Why you don't get a buffer position (not a line number), I don't know. I tried the equivalent experiment and I get Debugger entered--Lisp error: (void-function b) (b) (add-to-list 'foo '(a) (b)) eval-buffer(#<buffer *load*> nil "/tmp/foo.el" nil t) ; Reading at buffer position 70 load-with-code-conversion("/tmp/foo.el" "/tmp/foo.el" nil t) so I do get the buffer position. Maybe it's version dependent (although I think it's been around since 2017 or so).
    – NickD
    Commented Nov 26, 2023 at 3:38
  • How exactly are you loading the emacsen.el file from init.el? Your backtrace is missing the eval-buffer line which is where the Reading at buffer position message is attached. I don't understand why it's missing.
    – NickD
    Commented Nov 26, 2023 at 4:56
  • It would help if the OP followed up with more details, so we can figure out the problem, but in the absence of that, the duplicate question is useful, whereas this one is not.
    – NickD
    Commented Nov 27, 2023 at 10:12

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.