zevlg / telega.el

GNU Emacs telegram client (unofficial)
https://zevlg.github.io/telega.el/
GNU General Public License v3.0
1.09k stars 85 forks source link

[fix] add missing interactive to transient-define-prefix #473

Closed HyperSuperMetaCtrl closed 3 months ago

HyperSuperMetaCtrl commented 3 months ago

without this telega does not start anymore Addresses Issue #472

HyperSuperMetaCtrl commented 3 months ago

Starting telega with M-x returned:

internal-macroexpand-for-load: Eager macro-expansion failure: (error "transient-define-*: Interactive form missing")

I then turned on tooggle-debug-on-error and got:

Debugger entered--Lisp error: (error "Eager macro-expansion failure: (error \"transient-d...")
  error("Eager macro-expansion failure: %S" (error "transient-define-*: Interactive form missing"))
  internal-macroexpand-for-load((transient-define-prefix telega-saved-messages-tag-commands (tag) [:description (lambda nil (telega-ins--as-string (telega-ins--saved-messages-tag (car (oref transient--prefix scope))) (telega-ins--with-face 'transient-heading (telega-ins "Tag Commands")))) (telega-saved-messages-tag-filter) (telega-saved-messages-tag-add-name) (telega-saved-messages-tag-remove)] (lambda (tag) (interactive (list (user-error "Do not call this command directly"))))) nil)
  load-with-code-conversion("/home/me/.config/emacs/.local/straight/build-2..." "/home/me/.config/emacs/.local/straight/build-2..." nil t)
  require(telega-util)
  load-with-code-conversion("/home/me/.config/emacs/.local/straight/build-2..." "/home/me/.config/emacs/.local/straight/build-2..." nil t)
  require(telega-root)
  load-with-code-conversion("/home/me/.config/emacs/.local/straight/build-2..." "/home/me/.config/emacs/.local/straight/build-2..." nil t)
  command-execute(telega record)
  execute-extended-command(nil "telega" nil)
  funcall-interactively(execute-extended-command nil "telega" nil)
  command-execute(execute-extended-command)

Then added (interactive) to transient-define-prefix in telega-util.el.

With this change telega starts as usual.

rudolf-adamkovic commented 3 months ago

I can confirm that this works.

Thanks @HyperSuperMetaCtrl for figuring out the problem!

HyperSuperMetaCtrl commented 3 months ago

Happy to help

HyperSuperMetaCtrl commented 3 months ago

Found a way to do this without adding (interactive) closing