doomemacs
doomemacs copied to clipboard
Activating `+forge` within `magit` results in `(void-function org-link-set-parameters)`
What did you expect to happen?
No error.
What actually happened?
During startup, the following error happens: (void-function org-link-set-parameters). Weirdly, this error is thrown in the user configuration loading some org customizations. The configuration works perfectly fine without +forge.
I think the error happens in orgit-forge: https://github.com/magit/orgit-forge/blob/master/orgit-forge.el#L57.
Somehow, this function is called too early, but I do not know why. The full error trace is:
Debugger entered--Lisp error: (void-function org-link-set-parameters)
org-link-set-parameters("orgit-topic" :store orgit-topic-store :follow orgit-topic-open :export orgit-topic-export :complete orgit-topic-complete-link)
#f(compiled-function () #<bytecode 0x1ce7a5f73f5e0715>)()
funcall(#f(compiled-function () #<bytecode 0x1ce7a5f73f5e0715>))
mapc(funcall (#f(compiled-function () #<bytecode 0x1ce7a5f73f5e0715>)))
do-after-load-evaluation("/home/dominik/.doom.d/modules/org.el")
load-with-code-conversion("/home/dominik/.doom.d/modules/org.el" "/home/dominik/.doom.d/modules/org.el" nil t)
load("/home/dominik/.doom.d/modules/org" nil nomessage)
(let (file-name-handler-alist) (load (expand-file-name "./modules/org" "/home/dominik/.doom.d") nil 'nomessage))
(condition-case e (let (file-name-handler-alist) (load (expand-file-name "./modules/org" "/home/dominik/.doom.d") nil 'nomessage)) ((debug doom-error) (signal (car e) (cdr e))) ((debug error) (doom--handle-load-error e (expand-file-name "./modules/org" "/home/dominik/.doom.d") "/home/dominik/.doom.d")))
eval-buffer(#<buffer *load*-60381> nil "/home/dominik/.doom.d/config.el" nil t) ; Reading at buffer position 306
load-with-code-conversion("/home/dominik/.doom.d/config.el" "/home/dominik/.doom.d/config.el" t t)
load("/home/dominik/.doom.d/config" t nomessage)
(let (file-name-handler-alist) (load (expand-file-name "config" doom-private-dir) t 'nomessage))
(condition-case e (let (file-name-handler-alist) (load (expand-file-name "config" doom-private-dir) t 'nomessage)) ((debug doom-error) (signal (car e) (cdr e))) ((debug error) (doom--handle-load-error e (expand-file-name "config" doom-private-dir) doom-private-dir)))
(if no-config-p nil (maphash (doom-module-loader doom-module-config-file) doom-modules) (doom-run-hooks 'doom-init-modules-hook) (condition-case e (let (file-name-handler-alist) (load (expand-file-name "config" doom-private-dir) t 'nomessage)) ((debug doom-error) (signal (car e) (cdr e))) ((debug error) (doom--handle-load-error e (expand-file-name "config" doom-private-dir) doom-private-dir))) (if custom-file (progn (load custom-file 'noerror (not doom-debug-mode)))))
(progn (doom-log "Initializing user config") (maphash (doom-module-loader doom-module-init-file) doom-modules) (doom-run-hooks 'doom-before-init-modules-hook) (if no-config-p nil (maphash (doom-module-loader doom-module-config-file) doom-modules) (doom-run-hooks 'doom-init-modules-hook) (condition-case e (let (file-name-handler-alist) (load (expand-file-name "config" doom-private-dir) t 'nomessage)) ((debug doom-error) (signal (car e) (cdr e))) ((debug error) (doom--handle-load-error e (expand-file-name "config" doom-private-dir) doom-private-dir))) (if custom-file (progn (load custom-file 'noerror (not doom-debug-mode))))))
(if init-p (progn (doom-log "Initializing user config") (maphash (doom-module-loader doom-module-init-file) doom-modules) (doom-run-hooks 'doom-before-init-modules-hook) (if no-config-p nil (maphash (doom-module-loader doom-module-config-file) doom-modules) (doom-run-hooks 'doom-init-modules-hook) (condition-case e (let (file-name-handler-alist) (load (expand-file-name "config" doom-private-dir) t 'nomessage)) ((debug doom-error) (signal (car e) (cdr e))) ((debug error) (doom--handle-load-error e (expand-file-name "config" doom-private-dir) doom-private-dir))) (if custom-file (progn (load custom-file 'noerror (not doom-debug-mode)))))) nil)
(let* ((init-p (and t (condition-case e (let (file-name-handler-alist) (load (expand-file-name doom-module-init-file doom-private-dir) t 'nomessage)) ((debug doom-error) (signal (car e) (cdr e))) ((debug error) (doom--handle-load-error e (expand-file-name doom-module-init-file doom-private-dir) doom-private-dir)))))) (if init-p (progn (doom-log "Initializing user config") (maphash (doom-module-loader doom-module-init-file) doom-modules) (doom-run-hooks 'doom-before-init-modules-hook) (if no-config-p nil (maphash (doom-module-loader doom-module-config-file) doom-modules) (doom-run-hooks 'doom-init-modules-hook) (condition-case e (let (file-name-handler-alist) (load (expand-file-name "config" doom-private-dir) t 'nomessage)) ((debug doom-error) (signal (car e) (cdr e))) ((debug error) (doom--handle-load-error e (expand-file-name "config" doom-private-dir) doom-private-dir))) (if custom-file (progn (load custom-file 'noerror (not doom-debug-mode)))))) nil))
(progn (setq doom-init-modules-p t) (if no-config-p nil (doom-log "Initializing core modules") (doom-initialize-core-modules)) (let* ((init-p (and t (condition-case e (let (file-name-handler-alist) (load ... t ...)) ((debug doom-error) (signal ... ...)) ((debug error) (doom--handle-load-error e ... doom-private-dir)))))) (if init-p (progn (doom-log "Initializing user config") (maphash (doom-module-loader doom-module-init-file) doom-modules) (doom-run-hooks 'doom-before-init-modules-hook) (if no-config-p nil (maphash (doom-module-loader doom-module-config-file) doom-modules) (doom-run-hooks 'doom-init-modules-hook) (condition-case e (let (file-name-handler-alist) (load ... t ...)) ((debug doom-error) (signal ... ...)) ((debug error) (doom--handle-load-error e ... doom-private-dir))) (if custom-file (progn (load custom-file ... ...))))) nil)))
(if (or force-p (not doom-init-modules-p)) (progn (setq doom-init-modules-p t) (if no-config-p nil (doom-log "Initializing core modules") (doom-initialize-core-modules)) (let* ((init-p (and t (condition-case e (let ... ...) (... ...) (... ...))))) (if init-p (progn (doom-log "Initializing user config") (maphash (doom-module-loader doom-module-init-file) doom-modules) (doom-run-hooks 'doom-before-init-modules-hook) (if no-config-p nil (maphash (doom-module-loader doom-module-config-file) doom-modules) (doom-run-hooks 'doom-init-modules-hook) (condition-case e (let ... ...) (... ...) (... ...)) (if custom-file (progn ...)))) nil))))
doom-initialize-modules()
eval-buffer(#<buffer *load*> nil "/home/dominik/.emacs.d/lisp/doom-start.el" nil t) ; Reading at buffer position 8270
load-with-code-conversion("/home/dominik/.emacs.d/lisp/doom-start.el" "/home/dominik/.emacs.d/lisp/doom-start.el" t t)
load("/home/dominik/.emacs.d/lisp/doom-start" noerror nomessage)
#f(compiled-function (filename-function &optional alternate-filename-function load-defaults) "Load a user init-file.\nFILENAME-FUNCTION is called with no arguments and should return\nthe name of the init-file to load. If this file cannot be\nloaded, and ALTERNATE-FILENAME-FUNCTION is non-nil, then it is\ncalled with no arguments and should return the name of an\nalternate init-file to load. If LOAD-DEFAULTS is non-nil, then\nload default.el after the init-file, unless `inhibit-default-init'\nis non-nil.\n\nThis function sets `user-init-file' to the name of the loaded\ninit-file, or to a default value if loading is not possible." #<bytecode 0x11230eb2e34ac88d>)((closure ((args #f(compiled-function () #<bytecode 0xf3861b359f855e0>) #f(compiled-function () #<bytecode -0x1f3c686ddc0cdc35>) t) (init-file . "/home/dominik/.emacs.d/lisp/doom-start") t) nil (or init-file (expand-file-name "init.el" user-emacs-directory))) (closure ((args #f(compiled-function () #<bytecode 0xf3861b359f855e0>) #f(compiled-function () #<bytecode -0x1f3c686ddc0cdc35>) t) (init-file . "/home/dominik/.emacs.d/lisp/doom-start") t) nil (expand-file-name "safe-mode@static/init.el" doom-profiles-dir)) t)
apply(#f(compiled-function (filename-function &optional alternate-filename-function load-defaults) "Load a user init-file.\nFILENAME-FUNCTION is called with no arguments and should return\nthe name of the init-file to load. If this file cannot be\nloaded, and ALTERNATE-FILENAME-FUNCTION is non-nil, then it is\ncalled with no arguments and should return the name of an\nalternate init-file to load. If LOAD-DEFAULTS is non-nil, then\nload default.el after the init-file, unless `inhibit-default-init'\nis non-nil.\n\nThis function sets `user-init-file' to the name of the loaded\ninit-file, or to a default value if loading is not possible." #<bytecode 0x11230eb2e34ac88d>) ((closure ((args #f(compiled-function () #<bytecode 0xf3861b359f855e0>) #f(compiled-function () #<bytecode -0x1f3c686ddc0cdc35>) t) (init-file . "/home/dominik/.emacs.d/lisp/doom-start") t) nil (or init-file (expand-file-name "init.el" user-emacs-directory))) (closure ((args #f(compiled-function () #<bytecode 0xf3861b359f855e0>) #f(compiled-function () #<bytecode -0x1f3c686ddc0cdc35>) t) (init-file . "/home/dominik/.emacs.d/lisp/doom-start") t) nil (expand-file-name "safe-mode@static/init.el" doom-profiles-dir)) t))
startup--load-user-init-file(#f(compiled-function () #<bytecode 0xf3861b359f855e0>) #f(compiled-function () #<bytecode -0x1f3c686ddc0cdc35>) t)
command-line()
normal-top-level()
Describe your attempts to resolve the issue
I know which function is causing the error, but I do not know why it is loaded too early when activating +forge.
Steps to reproduce
Activate +forge.
Open Emacs.
System Information
https://pastebin.com/SXVttGn8