* bug#66149: Mistyping a search breaks keyboard macro @ 2023-09-22 8:09 Konstantin Kharlamov 2023-09-22 11:29 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Konstantin Kharlamov @ 2023-09-22 8:09 UTC (permalink / raw) To: 66149 If a user recorded a keyboard macro, upon replaying they expect the actions will be executed exactly as performed during recording. Unfortunately that doesn't hold for searches, which is unfortunate, because search is very useful during keyboard-macros. If a user mistypes a search, they usually just remove the offending letters and it just works. However replaying such record fails with `Keyboard macro terminated by a command ringing the bell` # Steps to reproduce 1. `emacs -Q` 2. Press `F3` to start recording a macro 3. Press `C-s` to start search and type `bufg`. The letter `g` will get highlighted in red because there's no such word 4. Press Backspace to remove `g` letter 5. Press `f` so the word is `buff` 6. Finish the macro by pressing `F4` 7. Execute the macro by pressing `F4` ## Expected Search succeeds ## Actual Search fails with `After 0 kbd macro iterations: isearch-search: Keyboard macro terminated by a command ringing the bell` # Additional information Emacs build from git as of commit 04710bd01b2 ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-22 8:09 bug#66149: Mistyping a search breaks keyboard macro Konstantin Kharlamov @ 2023-09-22 11:29 ` Eli Zaretskii 2023-09-22 11:40 ` Konstantin Kharlamov 2023-09-22 15:41 ` Juri Linkov 0 siblings, 2 replies; 11+ messages in thread From: Eli Zaretskii @ 2023-09-22 11:29 UTC (permalink / raw) To: Konstantin Kharlamov; +Cc: 66149 severity 66149 wishlist thanks > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > Date: Fri, 22 Sep 2023 11:09:59 +0300 > > If a user recorded a keyboard macro, upon replaying they expect the actions will be executed exactly as performed during recording. > > Unfortunately that doesn't hold for searches, which is unfortunate, because search is very useful during keyboard-macros. If a user mistypes a search, they usually just remove the offending letters and it just works. However replaying such record fails with `Keyboard macro terminated by a command ringing the bell` > > # Steps to reproduce > > 1. `emacs -Q` > 2. Press `F3` to start recording a macro > 3. Press `C-s` to start search and type `bufg`. The letter `g` will get highlighted in red because there's no such word > 4. Press Backspace to remove `g` letter > 5. Press `f` so the word is `buff` > 6. Finish the macro by pressing `F4` > 7. Execute the macro by pressing `F4` > > ## Expected > > Search succeeds > > ## Actual > > Search fails with `After 0 kbd macro iterations: isearch-search: Keyboard macro terminated by a command ringing the bell` IMNSHO, your expectations are unreasonable. Keyboard macros are not supposed to allow this; if you want something like that, you will need to write a special-purpose command. I've changed the severity of the bug to "wishlist" in cases someone thinks it is feasible to extend the macro facilities to support such expectations. But my personal tendency is to close this bug as notabug. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-22 11:29 ` Eli Zaretskii @ 2023-09-22 11:40 ` Konstantin Kharlamov 2023-09-22 15:41 ` Juri Linkov 1 sibling, 0 replies; 11+ messages in thread From: Konstantin Kharlamov @ 2023-09-22 11:40 UTC (permalink / raw) To: Eli Zaretskii; +Cc: 66149 On Fri, 2023-09-22 at 14:29 +0300, Eli Zaretskii wrote: > severity 66149 wishlist > thanks > > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > > Date: Fri, 22 Sep 2023 11:09:59 +0300 > > > > If a user recorded a keyboard macro, upon replaying they expect the > > actions will be executed exactly as performed during recording. > > > > Unfortunately that doesn't hold for searches, which is unfortunate, > > because search is very useful during keyboard-macros. If a user > > mistypes a search, they usually just remove the offending letters > > and it just works. However replaying such record fails with > > `Keyboard macro terminated by a command ringing the bell` > > > > # Steps to reproduce > > > > 1. `emacs -Q` > > 2. Press `F3` to start recording a macro > > 3. Press `C-s` to start search and type `bufg`. The letter `g` will > > get highlighted in red because there's no such word > > 4. Press Backspace to remove `g` letter > > 5. Press `f` so the word is `buff` > > 6. Finish the macro by pressing `F4` > > 7. Execute the macro by pressing `F4` > > > > ## Expected > > > > Search succeeds > > > > ## Actual > > > > Search fails with `After 0 kbd macro iterations: isearch-search: > > Keyboard macro terminated by a command ringing the bell` > > IMNSHO, your expectations are unreasonable. Keyboard macros are not > supposed to allow this; if you want something like that, you will > need > to write a special-purpose command. Well, I'm not sure why you say it's unreasonable, but for the record, the related emacs stackexchange question has 2k hits at the moment¹. So… at least there is demand for this to work. 1: https://emacs.stackexchange.com/q/10599/2671#ringing-bell-in-macro-with-search ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-22 11:29 ` Eli Zaretskii 2023-09-22 11:40 ` Konstantin Kharlamov @ 2023-09-22 15:41 ` Juri Linkov 2023-09-23 7:14 ` Konstantin Kharlamov 1 sibling, 1 reply; 11+ messages in thread From: Juri Linkov @ 2023-09-22 15:41 UTC (permalink / raw) To: Eli Zaretskii; +Cc: 66149, Konstantin Kharlamov >> Search fails with `After 0 kbd macro iterations: isearch-search: >> Keyboard macro terminated by a command ringing the bell` > > IMNSHO, your expectations are unreasonable. Keyboard macros are not > supposed to allow this; if you want something like that, you will need > to write a special-purpose command. > > I've changed the severity of the bug to "wishlist" in cases someone > thinks it is feasible to extend the macro facilities to support such > expectations. But my personal tendency is to close this bug as > notabug. I have no opinion whether 'ding' should terminate kbd macro or not. But it's possible to customize 'isearch-wrap-pause' to 'no-ding' to not ding on isearch failure, then kbd macro is not terminated. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-22 15:41 ` Juri Linkov @ 2023-09-23 7:14 ` Konstantin Kharlamov 2023-09-23 8:00 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Konstantin Kharlamov @ 2023-09-23 7:14 UTC (permalink / raw) To: Juri Linkov, Eli Zaretskii; +Cc: 66149 On Fri, 2023-09-22 at 18:41 +0300, Juri Linkov wrote: > > > I have no opinion whether 'ding' should terminate kbd macro or not. > But it's possible to customize 'isearch-wrap-pause' to 'no-ding' > to not ding on isearch failure, then kbd macro is not terminated. Oh, thank you! So for example, having the following code in the init file works around the problem: (defadvice kmacro-call-macro (around align-regexp-with-spaces activate) (let ((isearch-wrap-pause 'no-ding)) ad-do-it)) I'll post an answer about that on the emacs.stackexchange then. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-23 7:14 ` Konstantin Kharlamov @ 2023-09-23 8:00 ` Eli Zaretskii 2023-09-23 8:01 ` Konstantin Kharlamov 0 siblings, 1 reply; 11+ messages in thread From: Eli Zaretskii @ 2023-09-23 8:00 UTC (permalink / raw) To: Konstantin Kharlamov; +Cc: 66149-done, juri > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > Cc: 66149@debbugs.gnu.org > Date: Sat, 23 Sep 2023 10:14:59 +0300 > > On Fri, 2023-09-22 at 18:41 +0300, Juri Linkov wrote: > > > > > I have no opinion whether 'ding' should terminate kbd macro or not. > > But it's possible to customize 'isearch-wrap-pause' to 'no-ding' > > to not ding on isearch failure, then kbd macro is not terminated. > > Oh, thank you! So for example, having the following code in the init > file works around the problem: > > (defadvice kmacro-call-macro (around align-regexp-with-spaces activate) > (let ((isearch-wrap-pause 'no-ding)) > ad-do-it)) > > I'll post an answer about that on the emacs.stackexchange then. And I'm closing the bug. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-23 8:00 ` Eli Zaretskii @ 2023-09-23 8:01 ` Konstantin Kharlamov 2023-09-23 8:36 ` Eli Zaretskii 0 siblings, 1 reply; 11+ messages in thread From: Konstantin Kharlamov @ 2023-09-23 8:01 UTC (permalink / raw) To: Eli Zaretskii; +Cc: 66149-done, juri On Sat, 2023-09-23 at 11:00 +0300, Eli Zaretskii wrote: > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > > Cc: 66149@debbugs.gnu.org > > Date: Sat, 23 Sep 2023 10:14:59 +0300 > > > > On Fri, 2023-09-22 at 18:41 +0300, Juri Linkov wrote: > > > > > > > I have no opinion whether 'ding' should terminate kbd macro or > > > not. > > > But it's possible to customize 'isearch-wrap-pause' to 'no-ding' > > > to not ding on isearch failure, then kbd macro is not terminated. > > > > Oh, thank you! So for example, having the following code in the > > init > > file works around the problem: > > > > (defadvice kmacro-call-macro (around align-regexp-with-spaces > > activate) > > (let ((isearch-wrap-pause 'no-ding)) > > ad-do-it)) > > > > I'll post an answer about that on the emacs.stackexchange then. > > And I'm closing the bug. Why? The problem is still relevant. A workaround is not a fix. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-23 8:01 ` Konstantin Kharlamov @ 2023-09-23 8:36 ` Eli Zaretskii 2023-09-23 8:43 ` Konstantin Kharlamov 2023-09-23 12:56 ` Stefan Kangas 0 siblings, 2 replies; 11+ messages in thread From: Eli Zaretskii @ 2023-09-23 8:36 UTC (permalink / raw) To: Konstantin Kharlamov, Stefan Kangas; +Cc: 66149, juri > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > Cc: juri@linkov.net, 66149-done@debbugs.gnu.org > Date: Sat, 23 Sep 2023 11:01:32 +0300 > > On Sat, 2023-09-23 at 11:00 +0300, Eli Zaretskii wrote: > > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > > > Cc: 66149@debbugs.gnu.org > > > Date: Sat, 23 Sep 2023 10:14:59 +0300 > > > > > > On Fri, 2023-09-22 at 18:41 +0300, Juri Linkov wrote: > > > > > > > > > I have no opinion whether 'ding' should terminate kbd macro or > > > > not. > > > > But it's possible to customize 'isearch-wrap-pause' to 'no-ding' > > > > to not ding on isearch failure, then kbd macro is not terminated. > > > > > > Oh, thank you! So for example, having the following code in the > > > init > > > file works around the problem: > > > > > > (defadvice kmacro-call-macro (around align-regexp-with-spaces > > > activate) > > > (let ((isearch-wrap-pause 'no-ding)) > > > ad-do-it)) > > > > > > I'll post an answer about that on the emacs.stackexchange then. > > > > And I'm closing the bug. > > Why? The problem is still relevant. A workaround is not a fix. because the motivation to make any such changes is now even lower than it was before, and I don't want to keep bugs open when nothing is being done for them, nor ever will be. I'm okay with reopening for some limited time, but we should then say in advance when it will be closed if no progress is made. But maybe Stefan (CC'ed) thinks differently? ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-23 8:36 ` Eli Zaretskii @ 2023-09-23 8:43 ` Konstantin Kharlamov 2023-09-23 8:58 ` Eli Zaretskii 2023-09-23 12:56 ` Stefan Kangas 1 sibling, 1 reply; 11+ messages in thread From: Konstantin Kharlamov @ 2023-09-23 8:43 UTC (permalink / raw) To: Eli Zaretskii, Stefan Kangas; +Cc: 66149, juri On Sat, 2023-09-23 at 11:36 +0300, Eli Zaretskii wrote: > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > > Cc: juri@linkov.net, 66149-done@debbugs.gnu.org > > Date: Sat, 23 Sep 2023 11:01:32 +0300 > > > > On Sat, 2023-09-23 at 11:00 +0300, Eli Zaretskii wrote: > > > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > > > > Cc: 66149@debbugs.gnu.org > > > > Date: Sat, 23 Sep 2023 10:14:59 +0300 > > > > > > > > On Fri, 2023-09-22 at 18:41 +0300, Juri Linkov wrote: > > > > > > > > > > > I have no opinion whether 'ding' should terminate kbd macro > > > > > or > > > > > not. > > > > > But it's possible to customize 'isearch-wrap-pause' to 'no- > > > > > ding' > > > > > to not ding on isearch failure, then kbd macro is not > > > > > terminated. > > > > > > > > Oh, thank you! So for example, having the following code in the > > > > init > > > > file works around the problem: > > > > > > > > (defadvice kmacro-call-macro (around align-regexp-with- > > > > spaces > > > > activate) > > > > (let ((isearch-wrap-pause 'no-ding)) > > > > ad-do-it)) > > > > > > > > I'll post an answer about that on the emacs.stackexchange then. > > > > > > And I'm closing the bug. > > > > Why? The problem is still relevant. A workaround is not a fix. > > because the motivation to make any such changes is now even lower > than > it was before, and I don't want to keep bugs open when nothing is > being done for them, nor ever will be. Oh, okay, so, a fix for this closed bug will still be accepted? I was thinking of making a fix at some point in the future. Not right now I as I don't have resources ATM, but the problem overall seems to be easy to fix. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-23 8:43 ` Konstantin Kharlamov @ 2023-09-23 8:58 ` Eli Zaretskii 0 siblings, 0 replies; 11+ messages in thread From: Eli Zaretskii @ 2023-09-23 8:58 UTC (permalink / raw) To: Konstantin Kharlamov; +Cc: 66149, stefankangas, juri > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > Cc: juri@linkov.net, 66149@debbugs.gnu.org > Date: Sat, 23 Sep 2023 11:43:56 +0300 > > On Sat, 2023-09-23 at 11:36 +0300, Eli Zaretskii wrote: > > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > > > Cc: juri@linkov.net, 66149-done@debbugs.gnu.org > > > Date: Sat, 23 Sep 2023 11:01:32 +0300 > > > > > > On Sat, 2023-09-23 at 11:00 +0300, Eli Zaretskii wrote: > > > > > From: Konstantin Kharlamov <Hi-Angel@yandex.ru> > > > > > Cc: 66149@debbugs.gnu.org > > > > > Date: Sat, 23 Sep 2023 10:14:59 +0300 > > > > > > > > > > On Fri, 2023-09-22 at 18:41 +0300, Juri Linkov wrote: > > > > > > > > > > > > > I have no opinion whether 'ding' should terminate kbd macro > > > > > > or > > > > > > not. > > > > > > But it's possible to customize 'isearch-wrap-pause' to 'no- > > > > > > ding' > > > > > > to not ding on isearch failure, then kbd macro is not > > > > > > terminated. > > > > > > > > > > Oh, thank you! So for example, having the following code in the > > > > > init > > > > > file works around the problem: > > > > > > > > > > (defadvice kmacro-call-macro (around align-regexp-with- > > > > > spaces > > > > > activate) > > > > > (let ((isearch-wrap-pause 'no-ding)) > > > > > ad-do-it)) > > > > > > > > > > I'll post an answer about that on the emacs.stackexchange then. > > > > > > > > And I'm closing the bug. > > > > > > Why? The problem is still relevant. A workaround is not a fix. > > > > because the motivation to make any such changes is now even lower > > than > > it was before, and I don't want to keep bugs open when nothing is > > being done for them, nor ever will be. > > Oh, okay, so, a fix for this closed bug will still be accepted? We accept worthy improvements even if there's no bug at all for them, so yes, of course. The important thing is that the change is clean and doesn't bring any problems with it. ^ permalink raw reply [flat|nested] 11+ messages in thread
* bug#66149: Mistyping a search breaks keyboard macro 2023-09-23 8:36 ` Eli Zaretskii 2023-09-23 8:43 ` Konstantin Kharlamov @ 2023-09-23 12:56 ` Stefan Kangas 1 sibling, 0 replies; 11+ messages in thread From: Stefan Kangas @ 2023-09-23 12:56 UTC (permalink / raw) To: Eli Zaretskii, Konstantin Kharlamov; +Cc: 66149, juri Eli Zaretskii <eliz@gnu.org> writes: > I'm okay with reopening for some limited time, but we should then say > in advance when it will be closed if no progress is made. > > But maybe Stefan (CC'ed) thinks differently? No, I agree with you. Keeping bugs open when there's no expected progress typically leads to us forgetting about it, and then one of us have to come back to close it later anyways. I think it makes sense to revisit this if/when someone comes up with a patch, either by reopening this bug, or in a new bug report. ^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2023-09-23 12:56 UTC | newest] Thread overview: 11+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2023-09-22 8:09 bug#66149: Mistyping a search breaks keyboard macro Konstantin Kharlamov 2023-09-22 11:29 ` Eli Zaretskii 2023-09-22 11:40 ` Konstantin Kharlamov 2023-09-22 15:41 ` Juri Linkov 2023-09-23 7:14 ` Konstantin Kharlamov 2023-09-23 8:00 ` Eli Zaretskii 2023-09-23 8:01 ` Konstantin Kharlamov 2023-09-23 8:36 ` Eli Zaretskii 2023-09-23 8:43 ` Konstantin Kharlamov 2023-09-23 8:58 ` Eli Zaretskii 2023-09-23 12:56 ` Stefan Kangas
Code repositories for project(s) associated with this external index https://git.savannah.gnu.org/cgit/emacs.git https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.