ghelp icon indicating copy to clipboard operation
ghelp copied to clipboard

Ghelp breaks compatibility with default describe-* behaviour

Open ogdenwebb opened this issue 4 years ago • 11 comments

For example ghelp-describe-variable/ghelp-describe-function doesn't receive any argument at all, so I can't integrate that to ivy/counsel like helpful allows me to do. Emacs default describe-key/function/variables receives an arguments as well.

(setq counsel-describe-function-function #'helpful-callable
      counsel-describe-variable-function #'helpful-variable)

I suppose that ghelp alternatives should receive an [optional] argument.

ogdenwebb avatar Oct 01 '21 09:10 ogdenwebb

Thanks. Should be fixed now. Could yo verify?

casouri avatar Oct 01 '21 16:10 casouri

On Emacs 27.2, I get error when calling ghelp-describe-function Debugger entered--Lisp error: (void-function help-fns--describe-function-or-command-prompt)

And ghelp-describe-variable causes this: Debugger entered--Lisp error: (void-function format-prompt)

ogdenwebb avatar Oct 01 '21 18:10 ogdenwebb

They must have changed in Emacs 28, I changed it to be Emacs 27-compatible.

casouri avatar Oct 01 '21 18:10 casouri

Now it throws me this error:

emacs

For some reason I can't copypaste text from backtrace buffer. :/

ogdenwebb avatar Oct 01 '21 18:10 ogdenwebb

I guess I shouldn't just copy code from describe-function and expect it to work. I changed it to native code. It seems to work with counsel.

casouri avatar Oct 02 '21 02:10 casouri

On 27.2, it throws the same error. But it also appears when I try to call it with M-x ghelp-describe-function for example. Will test in on 28 later...

ogdenwebb avatar Oct 02 '21 07:10 ogdenwebb

Seems this bug related to Emacs 27.2, on Emacs version from git it works fine.

ogdenwebb avatar Oct 07 '21 16:10 ogdenwebb

Ah, sorry, I forgot to reply. Last time I checked, it works on vanilla Emacs 27. Could you try test it with emacs -q? You want to pull the latest ghelp.el, which fixed a bug where loading ghelp.el fails if Emacs can't find helpful.el.

casouri avatar Oct 07 '21 16:10 casouri

Well, manual loading without config works, so probably there's some incompatibility with my configuration/package in my setup between ghelp and that. I will try to detect what exactly causes the issue.

But it's pretty strange considering ghelp works on Emacs from git with exactly the same config, ugh.

ogdenwebb avatar Oct 07 '21 17:10 ogdenwebb

Welcome to GNU Emacs, bro.

casouri avatar Oct 07 '21 17:10 casouri

Ok. Probably something is wrong with straight.el or autoloads within your package. If I download the package and throw it directly into use-package with :load-path it works, but if I call this package through straight.el it won't work with the same error as above.

ogdenwebb avatar Oct 07 '21 18:10 ogdenwebb