all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#68947: 30.0.50; Gnus article mode keybindings
@ 2024-02-06  8:29 Pranshu
  2024-02-06 15:09 ` Eric Abrahamsen
  2024-02-06 15:42 ` Andreas Schwab
  0 siblings, 2 replies; 9+ messages in thread
From: Pranshu @ 2024-02-06  8:29 UTC (permalink / raw)
  To: 68947


Recipe from emacs -q:
1. M-x gnus
2. Select any group
3. Select a random article
4. do `W C-h' or C-h m

W C-h simply does not work while C-h m works, but does not show the
bound keys.


In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
 3.24.41, cairo version 1.18.0) of 2024-02-02 built on localhost
Repository revision: d89e427852a63dbeed3d5e03d9deb2ae9a8e3e1b
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12101011
System Description: Parabola GNU/Linux-libre

Configured using:
 'configure --with-native-compilation --with-mailutils'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBOTF LIBSYSTEMD LIBXML2 M17N_FLT MODULES NATIVE_COMP NOTIFY
INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF
TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XDBE XIM XINPUT2 XPM GTK3 ZLIB

Important settings:
  value of $LC_ALL: en_US.UTF-8
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  winner-mode: t
  midnight-mode: t
  global-so-long-mode: t
  electric-pair-mode: t
  delete-selection-mode: t
  fido-vertical-mode: t
  icomplete-vertical-mode: t
  icomplete-mode: t
  fido-mode: t
  hyperbole-mode: t
  pranshu-edit-mode: t
  which-key-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  minibuffer-regexp-mode: t
  column-number-mode: t
  line-number-mode: t
  indent-tabs-mode: t
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  abbrev-mode: t

Load-path shadows:
None found.

Features:
(help-fns radix-tree cl-print shadow mail-extr emacsbug warnings
cus-start kotl-autoloads hyperbole-autoloads auto-capitalize string-edit
gnus-search eieio-opt cl-extra speedbar ezimage dframe gnus-icalendar
org-capture icalendar diary-lib diary-loaddefs smtpmail gnus-dired
skeleton oc-bibtex wdired ls-lisp mandoura solar cal-dst holidays
holiday-loaddefs proced time winner esh-mode esh-var eshell esh-cmd
esh-ext esh-opt esh-proc esh-io esh-arg esh-module esh-groups esh-util
standard-light-theme standard-themes ef-themes midnight so-long
elec-pair delsel icomplete savehist cc-mode cc-fonts cc-guess cc-menus
cc-cmds find-file cc-styles cc-align cc-engine cc-vars cc-defs
htmlfontify cus-edit cus-load hyperbole hinit hibtypes hib-doc-id klink
hib-kbd hib-debbugs hib-social hsys-www hypb-ert ert ewoc debug
backtrace hactypes bookmark pp hui-mini hui hui-mouse hmouse-key hargs
hsys-org org-element org-persist org-id org-refile avl-tree org ob
ob-tangle ob-ref ob-lob ob-table ob-exp org-macro org-src ob-comint
org-pcomplete org-list org-footnote org-faces org-entities ob-emacs-lisp
ob-core ob-eval org-cycle org-table ol org-fold org-fold-core org-keys
oc org-loaddefs org-version org-compat org-macs hmouse-tag etags
fileloop generator xref project find-func hmouse-info info hui-menu
hyrolo-menu hyrolo sort hui-jmenu hpath tramp trampver tramp-integration
files-x tramp-message tramp-compat xdg shell pcomplete format-spec
tramp-loaddefs noutline outline icons hmouse-sh hmouse-drv hui-window
pulse color hycontrol hui-select hsettings hui-em-but hbut view hbdata
hgnus gnus-msg gnus-art mm-uu mml2015 mm-view mml-smime smime gnutls dig
gnus-sum shr pixel-fill kinsoku url-file svg dom gnus-group gnus-undo
gnus-start gnus-dbus dbus comp-run comp-common rx xml gnus-cloud nnimap
nnmail mail-source utf7 nnoo parse-time iso8601 gnus-spec gnus-int
gnus-range gnus-win gnus nnheader range wid-edit hsmail message sendmail
yank-media puny rfc822 mml mml-sec epa epg rfc6068 epg-config gnus-util
time-date mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047
rfc2045 mm-util ietf-drums mail-prsvr mailabbrev mail-utils gmm-utils
mailheader hmail htz cal-julian cal-menu calendar cal-loaddefs hbmap
hmoccur help-mode browse-url url url-proxy url-privacy url-expand
url-methods url-history url-cookie generate-lisp-file url-domsuf
url-util url-parse auth-source eieio eieio-core password-cache json map
byte-opt bytecomp byte-compile url-vars mailcap hvar hypb locate hact
hhist compile text-property-search comint ansi-osc ansi-color ring set
hversion hload-path dired-preview dired dired-loaddefs vundo subr-x
derived which-key pcase easy-mmode cl-seq cl-macs gv cl-loaddefs cl-lib
rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook
vc-hooks lisp-float-type elisp-mode mwheel term/x-win x-win
term/common-win x-dnd touch-screen tool-bar dnd fontset image regexp-opt
fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode
register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select
scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors
frame minibuffer nadvice seq simple cl-generic indonesian philippine
cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese composite emoji-zwj charscript
charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure
cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp
files window text-properties overlay sha1 md5 base64 format env
code-pages mule custom widget keymap hashtable-print-readable backquote
threads dbusbind inotify lcms2 dynamic-setting system-font-setting
font-render-setting cairo gtk x-toolkit xinput2 x multi-tty move-toolbar
make-network-process native-compile emacs)

Memory information:
((conses 16 469885 55947) (symbols 48 32456 6)
 (strings 32 107154 4415) (string-bytes 1 3980293) (vectors 16 48711)
 (vector-slots 8 596940 34765) (floats 8 1009 9235)
 (intervals 56 653 0) (buffers 984 16))






^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
  2024-02-06  8:29 bug#68947: 30.0.50; Gnus article mode keybindings Pranshu
@ 2024-02-06 15:09 ` Eric Abrahamsen
       [not found]   ` <87r0hofow9.fsf@gmail.com>
  2024-02-06 15:42 ` Andreas Schwab
  1 sibling, 1 reply; 9+ messages in thread
From: Eric Abrahamsen @ 2024-02-06 15:09 UTC (permalink / raw)
  To: Pranshu; +Cc: 68947

Pranshu <pranshusharma366@gmail.com> writes:

> Recipe from emacs -q:
> 1. M-x gnus
> 2. Select any group
> 3. Select a random article
> 4. do `W C-h' or C-h m
>
> W C-h simply does not work while C-h m works, but does not show the
> bound keys.

FWIW I'm unable to reproduce this, using Emacs master. I'd be pretty
surprised if Gnus were able to break such low-level functionality, too.
Can you give us any more clues? Is this something that only started
happening recently?





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
  2024-02-06  8:29 bug#68947: 30.0.50; Gnus article mode keybindings Pranshu
  2024-02-06 15:09 ` Eric Abrahamsen
@ 2024-02-06 15:42 ` Andreas Schwab
  2024-02-06 20:33   ` Eric Abrahamsen
  1 sibling, 1 reply; 9+ messages in thread
From: Andreas Schwab @ 2024-02-06 15:42 UTC (permalink / raw)
  To: Pranshu; +Cc: 68947

On Feb 06 2024, Pranshu wrote:

> Recipe from emacs -q:
> 1. M-x gnus
> 2. Select any group
> 3. Select a random article
> 4. do `W C-h' or C-h m
>
> W C-h simply does not work while C-h m works, but does not show the
> bound keys.

In gnus-article-mode, all self-inserting keys are bound to
gnus-article-read-summary-keys, which does special things.  They are
_not_ prefix keys.

-- 
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE  1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
  2024-02-06 15:42 ` Andreas Schwab
@ 2024-02-06 20:33   ` Eric Abrahamsen
  0 siblings, 0 replies; 9+ messages in thread
From: Eric Abrahamsen @ 2024-02-06 20:33 UTC (permalink / raw)
  To: Andreas Schwab; +Cc: Pranshu, 68947

Andreas Schwab <schwab@suse.de> writes:

> On Feb 06 2024, Pranshu wrote:
>
>> Recipe from emacs -q:
>> 1. M-x gnus
>> 2. Select any group
>> 3. Select a random article
>> 4. do `W C-h' or C-h m
>>
>> W C-h simply does not work while C-h m works, but does not show the
>> bound keys.
>
> In gnus-article-mode, all self-inserting keys are bound to
> gnus-article-read-summary-keys, which does special things.  They are
> _not_ prefix keys.

(I didn't realize you meant with point in the article, sorry)





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
       [not found]   ` <87r0hofow9.fsf@gmail.com>
@ 2024-02-10 18:09     ` Eric Abrahamsen
  2024-02-10 18:15       ` Eli Zaretskii
  0 siblings, 1 reply; 9+ messages in thread
From: Eric Abrahamsen @ 2024-02-10 18:09 UTC (permalink / raw)
  To: Pranshu; +Cc: 68947


On 02/07/24 22:19 PM, Pranshu wrote:
> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
>
>> Pranshu <pranshusharma366@gmail.com> writes:
>>
>>> Recipe from emacs -q:
>>> 1. M-x gnus
>>> 2. Select any group
>>> 3. Select a random article
>>> 4. do `W C-h' or C-h m
>>>
>>> W C-h simply does not work while C-h m works, but does not show the
>>> bound keys.
>>
>> FWIW I'm unable to reproduce this, using Emacs master. I'd be pretty
>> surprised if Gnus were able to break such low-level functionality, too.
>> Can you give us any more clues? Is this something that only started
>> happening recently?
>
> With the point in article mode, are you able to reproduce it?

(Sending this back to the bug report...)

Yes, I'm able to reproduce it, and it sent me down a really awful rabbit
hole -- gnus-art.el goes to huge lengths to make summary-mode
keybindings available in article mode. It uses this:

(substitute-key-definition
 #'undefined #'gnus-article-read-summary-keys gnus-article-mode-map)

to redirect all unbound keys to the `gnus-article-read-summary-keys'
function, which manually reads keys and dispatches to tweaked versions
of summary-mode commands.

Your immediate issue is caused by the fact that
`gnus-article-describe-bindings', which theoretically should be
responsible for telling the user about all the redirections, is only
aware of the "S" keymap prefix. It doesn't know all the ways in which an
'undefined binding might get translated into a valid summary-mode
command, and can't show you those.

To be honest, I don't think I'm going to be able to fix this. If we keep
the current implementation, `gnus-article-describe-bindings' would have
to be made aware of the additional redirections, and I wouldn't even
know where to start.

It could be that Elisp has better tools for this situation by now (the
original architecture was in place before 1997), but I'm not sure what
those tools are. Perhaps someone will chime in with a helpful
suggestion...

Eric





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
  2024-02-10 18:09     ` Eric Abrahamsen
@ 2024-02-10 18:15       ` Eli Zaretskii
  2024-02-10 18:59         ` Eric Abrahamsen
  0 siblings, 1 reply; 9+ messages in thread
From: Eli Zaretskii @ 2024-02-10 18:15 UTC (permalink / raw)
  To: Eric Abrahamsen; +Cc: pranshusharma366, 68947

> Cc: 68947@debbugs.gnu.org
> From: Eric Abrahamsen <eric@ericabrahamsen.net>
> Date: Sat, 10 Feb 2024 10:09:14 -0800
> 
> Your immediate issue is caused by the fact that
> `gnus-article-describe-bindings', which theoretically should be
> responsible for telling the user about all the redirections, is only
> aware of the "S" keymap prefix. It doesn't know all the ways in which an
> 'undefined binding might get translated into a valid summary-mode
> command, and can't show you those.
> 
> To be honest, I don't think I'm going to be able to fix this. If we keep
> the current implementation, `gnus-article-describe-bindings' would have
> to be made aware of the additional redirections, and I wouldn't even
> know where to start.
> 
> It could be that Elisp has better tools for this situation by now (the
> original architecture was in place before 1997), but I'm not sure what
> those tools are. Perhaps someone will chime in with a helpful
> suggestion...

Strange as it may sound, I see no grave problem here: C-h is not
guaranteed to work after any arbitrary prefix, anyway.  So if that is
too hard to fix, we could just punt and leave it unsolved.

What about "C-h b" -- does that work in the situation described by the
recipe?





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
  2024-02-10 18:15       ` Eli Zaretskii
@ 2024-02-10 18:59         ` Eric Abrahamsen
  2024-02-17 18:13           ` Eric Abrahamsen
  0 siblings, 1 reply; 9+ messages in thread
From: Eric Abrahamsen @ 2024-02-10 18:59 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: pranshusharma366, 68947


On 02/10/24 20:15 PM, Eli Zaretskii wrote:
>> Cc: 68947@debbugs.gnu.org
>> From: Eric Abrahamsen <eric@ericabrahamsen.net>
>> Date: Sat, 10 Feb 2024 10:09:14 -0800
>> 
>> Your immediate issue is caused by the fact that
>> `gnus-article-describe-bindings', which theoretically should be
>> responsible for telling the user about all the redirections, is only
>> aware of the "S" keymap prefix. It doesn't know all the ways in which an
>> 'undefined binding might get translated into a valid summary-mode
>> command, and can't show you those.
>> 
>> To be honest, I don't think I'm going to be able to fix this. If we keep
>> the current implementation, `gnus-article-describe-bindings' would have
>> to be made aware of the additional redirections, and I wouldn't even
>> know where to start.
>> 
>> It could be that Elisp has better tools for this situation by now (the
>> original architecture was in place before 1997), but I'm not sure what
>> those tools are. Perhaps someone will chime in with a helpful
>> suggestion...
>
> Strange as it may sound, I see no grave problem here: C-h is not
> guaranteed to work after any arbitrary prefix, anyway.  So if that is
> too hard to fix, we could just punt and leave it unsolved.

I'm inclined to say it's too hard to fix! The only cleaner solution I
can think of is to actually define article-mode versions of all the
summary-mode commands we'd want to call, which would also provide a
place to do the necessary article-specific adjustments. That's a lot of
very tightly-coupled code, though.

> What about "C-h b" -- does that work in the situation described by the
> recipe?

No, that doesn't really work. The gnus-article-mode bindings are listed
under a "fundamental-mode Major Mode Bindings:" heading (??). That
includes gnus-article-mode's own keybindings, and the summary-mode
bindings that have been explicitly attached at the "S" prefix, but
nothing else.





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
  2024-02-10 18:59         ` Eric Abrahamsen
@ 2024-02-17 18:13           ` Eric Abrahamsen
  2024-02-17 18:14             ` Eli Zaretskii
  0 siblings, 1 reply; 9+ messages in thread
From: Eric Abrahamsen @ 2024-02-17 18:13 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: pranshusharma366, 68947

Eric Abrahamsen <eric@ericabrahamsen.net> writes:

> On 02/10/24 20:15 PM, Eli Zaretskii wrote:
>>> Cc: 68947@debbugs.gnu.org
>>> From: Eric Abrahamsen <eric@ericabrahamsen.net>
>>> Date: Sat, 10 Feb 2024 10:09:14 -0800
>>> 
>>> Your immediate issue is caused by the fact that
>>> `gnus-article-describe-bindings', which theoretically should be
>>> responsible for telling the user about all the redirections, is only
>>> aware of the "S" keymap prefix. It doesn't know all the ways in which an
>>> 'undefined binding might get translated into a valid summary-mode
>>> command, and can't show you those.
>>> 
>>> To be honest, I don't think I'm going to be able to fix this. If we keep
>>> the current implementation, `gnus-article-describe-bindings' would have
>>> to be made aware of the additional redirections, and I wouldn't even
>>> know where to start.
>>> 
>>> It could be that Elisp has better tools for this situation by now (the
>>> original architecture was in place before 1997), but I'm not sure what
>>> those tools are. Perhaps someone will chime in with a helpful
>>> suggestion...
>>
>> Strange as it may sound, I see no grave problem here: C-h is not
>> guaranteed to work after any arbitrary prefix, anyway.  So if that is
>> too hard to fix, we could just punt and leave it unsolved.
>
> I'm inclined to say it's too hard to fix! The only cleaner solution I
> can think of is to actually define article-mode versions of all the
> summary-mode commands we'd want to call, which would also provide a
> place to do the necessary article-specific adjustments. That's a lot of
> very tightly-coupled code, though.
>
>> What about "C-h b" -- does that work in the situation described by the
>> recipe?
>
> No, that doesn't really work. The gnus-article-mode bindings are listed
> under a "fundamental-mode Major Mode Bindings:" heading (??). That
> includes gnus-article-mode's own keybindings, and the summary-mode
> bindings that have been explicitly attached at the "S" prefix, but
> nothing else.

I don't know, I don't see a good solution to this without a massive
rewrite, which I don't have the stomach for right now. Should we leave
the bug open, since it's a real problem?





^ permalink raw reply	[flat|nested] 9+ messages in thread

* bug#68947: 30.0.50; Gnus article mode keybindings
  2024-02-17 18:13           ` Eric Abrahamsen
@ 2024-02-17 18:14             ` Eli Zaretskii
  0 siblings, 0 replies; 9+ messages in thread
From: Eli Zaretskii @ 2024-02-17 18:14 UTC (permalink / raw)
  To: Eric Abrahamsen; +Cc: pranshusharma366, 68947

> From: Eric Abrahamsen <eric@ericabrahamsen.net>
> Cc: pranshusharma366@gmail.com,  68947@debbugs.gnu.org
> Date: Sat, 17 Feb 2024 10:13:02 -0800
> 
> Eric Abrahamsen <eric@ericabrahamsen.net> writes:
> 
> > On 02/10/24 20:15 PM, Eli Zaretskii wrote:
> >>> Cc: 68947@debbugs.gnu.org
> >>> From: Eric Abrahamsen <eric@ericabrahamsen.net>
> >>> Date: Sat, 10 Feb 2024 10:09:14 -0800
> >>> 
> >>> Your immediate issue is caused by the fact that
> >>> `gnus-article-describe-bindings', which theoretically should be
> >>> responsible for telling the user about all the redirections, is only
> >>> aware of the "S" keymap prefix. It doesn't know all the ways in which an
> >>> 'undefined binding might get translated into a valid summary-mode
> >>> command, and can't show you those.
> >>> 
> >>> To be honest, I don't think I'm going to be able to fix this. If we keep
> >>> the current implementation, `gnus-article-describe-bindings' would have
> >>> to be made aware of the additional redirections, and I wouldn't even
> >>> know where to start.
> >>> 
> >>> It could be that Elisp has better tools for this situation by now (the
> >>> original architecture was in place before 1997), but I'm not sure what
> >>> those tools are. Perhaps someone will chime in with a helpful
> >>> suggestion...
> >>
> >> Strange as it may sound, I see no grave problem here: C-h is not
> >> guaranteed to work after any arbitrary prefix, anyway.  So if that is
> >> too hard to fix, we could just punt and leave it unsolved.
> >
> > I'm inclined to say it's too hard to fix! The only cleaner solution I
> > can think of is to actually define article-mode versions of all the
> > summary-mode commands we'd want to call, which would also provide a
> > place to do the necessary article-specific adjustments. That's a lot of
> > very tightly-coupled code, though.
> >
> >> What about "C-h b" -- does that work in the situation described by the
> >> recipe?
> >
> > No, that doesn't really work. The gnus-article-mode bindings are listed
> > under a "fundamental-mode Major Mode Bindings:" heading (??). That
> > includes gnus-article-mode's own keybindings, and the summary-mode
> > bindings that have been explicitly attached at the "S" prefix, but
> > nothing else.
> 
> I don't know, I don't see a good solution to this without a massive
> rewrite, which I don't have the stomach for right now. Should we leave
> the bug open, since it's a real problem?

Fine with me.





^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-02-17 18:14 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-06  8:29 bug#68947: 30.0.50; Gnus article mode keybindings Pranshu
2024-02-06 15:09 ` Eric Abrahamsen
     [not found]   ` <87r0hofow9.fsf@gmail.com>
2024-02-10 18:09     ` Eric Abrahamsen
2024-02-10 18:15       ` Eli Zaretskii
2024-02-10 18:59         ` Eric Abrahamsen
2024-02-17 18:13           ` Eric Abrahamsen
2024-02-17 18:14             ` Eli Zaretskii
2024-02-06 15:42 ` Andreas Schwab
2024-02-06 20:33   ` Eric Abrahamsen

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.