reddit / emacs

I can not find where this error comes from: invalid read syntax # 1 0

fmou67 · 2022-10-25 06:00
Hi everyone, I get this error when loading my emacs (vanilla based on [nano-emacs](https://github.com/rougier/nano-emacs)): \`\`\``Debugger entered--Lisp error: (invalid-read-syntax: # 1 0)` `read(#<buffer *load*>)` `eval-buffer(#<buffer *load*> nil "/home/fred/.emacs.d/init.el" nil t) ; Reading at buffer position 109684` `load-with-code-conversion("/home/fred/.emacs.d/init.el" "/home/fred/.emacs.d/init.el" t t)` `load("/home/fred/.emacs.d/init" noerror nomessage)` `startup--load-user-init-file(#f(compiled-function () #<bytecode 0xe5cd7db3b14149d>) #f(compiled-function () #<bytecode -0x1f3c686ddc0cdc35>) t)` `command-line()` `normal-top-level()` I have browsed and search for this error, I found one occurence, without any explanation or solution. Where is the error? Please help, and thanks in advance!!!
fmou67 · 2022-10-25 06:04
I am looking for the error with `M-x goto-char`... let's see if something comes up
7890yuiop · 2022-10-25 06:55
> Where is the error? Where is the code? ---- Also: The only code block formatting method which [works for all users](https://reddithelp.com/hc/en-us/articles/360043033952-Formatting-Guide#wiki_code_blocks_and_inline_code) of reddit is to switch the reddit editor to markdown mode* and indent the code by 4 spaces (you can use `M-4 C-x C-i` on a region followed by `M-x untabify` to achieve this in Emacs); and you need to use empty lines to separate the indented lines from the other text. Otherwise for lots of readers your message looks like this: https://old.reddit.com/r/emacs/comments/ycxdo5/i_can_not_find_where_this_error_comes_from/ Be sure to remove any different syntax intended for formatting (such as triple backticks) at the same time. (*) Switching to the markdown editor may or may not still be necessary. At one time it prevented problems.
howardthegeek · 2022-10-25 15:14
What I often do is move my init file out of the way, then start to add the parts back... Another approach is to split your init file into different files, then you can load them in one at a time... And if you have it under source control, it is easier to see what you changed recently.
ieure · 2022-10-25 18:42
The message tells you the issue is at position 109684 in `init.el`, so, check there.
fmou67 · 2022-10-26 06:22
I did and found the culprit... I mistyped ```end_src```... and the following # was no longer interpreted as part of a lisp command