Closed Apteryks closed 4 years ago
Can you not enter an empty string via C-M-j
(ivy-immediate-done
)?
This occurs on GNU Guix with Emacs 27.1 and ivy 0.13.1.
That's funny, GNU ELPA says Ivy 0.13.1, but the Ivy sources only go as far as 0.13.0. :)
@basil-conto C-M-j indeed works around the problem, thank you! But it is not intuitive for a newcomer, and the fact that https://github.com/abo-abo/swiper/blob/master/ivy.el#L161 exists points to a problem that Ivy meant to handle but failed.
C-M-j indeed works around the problem, thank you!
You're welcome. Does that mean this issue can be closed?
But it is not intuitive for a newcomer
It is documented in the Ivy user manual under (info "(ivy) Key bindings for single selection action then exit minibuffer")
.
and the fact that https://github.com/abo-abo/swiper/blob/master/ivy.el#L161 exists points to a problem that Ivy meant to handle but failed.
It's more an artefact of Ivy's design, which unfortunately did not prioritise seamless interoperability with built-in completion.
OK, thanks for explaining. Since it's documented and a product of Ivy's design, I'm closing this issue. Thank you!
I use enable counsel-mode, which defines counsel-M-x as my primary M-x keybinding.
Upon attempting to use
bbdb-create
, I can proceed with the name, organization, and email address, but it then blocks on the snail mail (address) because the completion won't let me enter an empty string, which bbdb uses to interrupt prompting for a new address line entry.I've edebug'd it, and it seems the problem has to do with the completion handler not being set to
ivy-completing-read-with-empty-string-def
, as it was apparently intended here https://github.com/abo-abo/swiper/blob/master/ivy.el#L161.In
ivy-completing-read
, at the time it does(assq this-command ivy-completing-read-handlers-alist)
, the value ofthis-command
is exit-minibuffer instead ofbbdb-create
. This occurs on GNU Guix with Emacs 27.1 and ivy 0.13.1.