aboutsummaryrefslogtreecommitdiff
path: root/tests/test-custom-ordering-unarrayify.el
diff options
context:
space:
mode:
authorCraig Jennings <c@cjennings.net>2026-05-16 01:31:36 -0500
committerCraig Jennings <c@cjennings.net>2026-05-16 01:31:36 -0500
commit23886aaf4ca2be79e1b25ee12581e45cab753734 (patch)
tree9f97e8f1ce1eb92ea389979320eb683df687daed /tests/test-custom-ordering-unarrayify.el
parent1ef93a50806be0163d431d61eee7b15906d40583 (diff)
downloaddotemacs-23886aaf4ca2be79e1b25ee12581e45cab753734.tar.gz
dotemacs-23886aaf4ca2be79e1b25ee12581e45cab753734.zip
fix(ai-config): hook gptel-magit wiring per-feature, not on magit
The wiring keyed on `with-eval-after-load 'magit` fires while two of its three references are still undefined. `magit.el` calls `(provide 'magit)` BEFORE its `cl-eval-when (load eval)` block requires `magit-commit` and `magit-stash`. At that moment the `magit-commit` transient prefix doesn't exist, and `transient-append-suffix` silently no-ops on missing prefixes (default `transient-error-on-insert-failure` is nil). The "g Generate commit" and "x Explain" suffixes never landed. Only the M-g binding worked, because `git-commit` IS required before provide. Three per-feature hooks replace the single `'magit` hook: one each on `git-commit`, `magit-commit`, and `magit-diff`. Each hooks the exact dependency the wiring needs, side-stepping the load-order race entirely. The companion test was rewritten to check `after-load-alist` registration rather than drive the hooks through `provide`. Emacs 30 batch mode doesn't fire registered `eval-after-load` callbacks on `provide` alone -- only an actual `load` does. Inspecting the registration is the stronger guard anyway: the regression is "a single `'magit` hook," and the right shape of that check is "no entry under `magit`, entries under `git-commit`, `magit-commit`, `magit-diff`."
Diffstat (limited to 'tests/test-custom-ordering-unarrayify.el')
0 files changed, 0 insertions, 0 deletions