ruby-mode-hook: failed to define function inf-ruby-keys reddit / emacs ---------------------------------------------------------------------- Shirugentoo · 2022-05-05 03:11 Hello guys, Trying to edit a ruby file, an error occurred and i do not know how deal with it. I am using Doom Emacs and got the following output when opening any ruby files. Error (ruby-mode-hook): Error running hook "inf-ruby-keys" because: (error Autoloading file /home/shiru/.emacs.d/.local/straight/build-27.2/inf-ruby/inf-ruby.elc failed to define function inf-ruby-keys) Any advice? ---------------------------------------------------------------------- organic-bookworm · 2022-05-05 15:26 Looks like a stale bytecode. Try rm -r /home/shiru/.emacs.d/.local/straight/build-27.2/inf-ruby/ doom sync This should recompile `inf-ruby` and generate autoloads. ---------------------------------------------------------------------- Shirugentoo · 2022-05-05 21:15 Thanks but nothing changed. It's really weird because on my laptop, no issue at all. ---------------------------------------------------------------------- Shirugentoo · 2022-05-05 21:38 I found the solution : if you are a Gentoo user, don't install the app-emacs/ruby-mode package if you use Doom Emacs. .