smartparens
smartparens copied to clipboard
Ruby `def` no longer completes `end` for me
Using ruby-mode, typing def SPC
no longer inserts end
for me.
I'm at a loss as to why this happened. I tried going back N months back per Git history.
My smartparens setup is vanilla/minimalistic; I've been a user for some 5 years (as I've hacked on Emacs for 10+).
What are some measures to debug this? Can I trigger the completion by hand? Or otherwise inspect the ruby- / smartparens-related environment?
Maybe there's some sort of cross-package interference?
Steps to reproduce the problem
May be provided on request
Environment & version information
-
smartparens
version: 20231024.1804 - Active
major-mode
:ruby-mode
- Smartparens strict mode: nil
- Emacs version (
M-x emacs-version
): GNU Emacs 27.2 (build 1, x86_64-apple-darwin20.6.0, NS appkit-2022.60 Version 11.6 (Build 20G165)) of 2023-09-26 - Starterkit/Distribution: Vanilla
- OS: darwin
Thanks - V
...I use Emacs 27 (as it's good enough, and some packages I use break on 28). I see that the CI has:
- '25.1'
- '25.2'
- '25.3'
- '26.1'
- '26.2'
- '26.3'
- 'snapshot'
which surely means that 27 is getting skipped.
Update: I went back to 26, made no difference.
I also started seeing this recently. I tried the following steps:
- Started Emacs with the
-Q
option. - Opened a new buffer.
-
M-x
ruby-mode
-
M-x
smartparens-mode
- Typed
def
.
No end
was inserted.
Not only that, but sexp-based motion commands have stopped working properly, probably at the same time. For example, when point is after the end
at the end of a function and I invoke sp-backward-sexp
, point used to move to start of the corresponding def
. Now it just moves to the start of the end
. sp-backward-up-sexp
does nothing at all anymore, as far as I can tell.
FWIW, I never got to diagnose this and am using https://github.com/rejeep/ruby-end.el for now
I updated to from Emacs 27 to Emacs 29 and this functionality now works as I'm used to. Emacs 28 didn't cut it.
It probably got broken in this commit 4e3ca735aadc570a5b4b456519000d6048785bf4 . I reverted some changes and made the config load in the legacy mode as well.
Thanks much!
Looking forward to revert ruby-end.el out of my config :) it worked but obviously it's far less capable.