Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Recursive Load on any org-roam-bibtex function #27

Closed
dmgie opened this issue May 3, 2020 · 9 comments
Closed

Recursive Load on any org-roam-bibtex function #27

dmgie opened this issue May 3, 2020 · 9 comments
Assignees

Comments

@dmgie
Copy link

dmgie commented May 3, 2020

Hi,

I just installed org-roam-bibtex to try it out but whenever calling an org-roam-bibtex function I get:

Recursive load: "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/orb-note-actions.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/org-roam-bibtex.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/orb-note-actions.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/org-roam-bibtex.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/orb-note-actions.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/org-roam-bibtex.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/orb-note-actions.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/org-roam-bibtex.el", "/home/arch/.emacs.d/.local/straight/build/org-roam-bibtex/orb-note-actions.el"

and the backtrace being:

Debugger entered--Lisp error: (error "Recursive load" "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro...")
  require(org-roam-bibtex)
  #<subr eval-buffer>(#<buffer  *load*-280947> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*-280947> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*-280947> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 1800
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  require(orb-note-actions)
  #<subr eval-buffer>(#<buffer  *load*-31892> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*-31892> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*-31892> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 3240
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  require(org-roam-bibtex)
  #<subr eval-buffer>(#<buffer  *load*-886275> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*-886275> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*-886275> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 1800
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  require(orb-note-actions)
  #<subr eval-buffer>(#<buffer  *load*-820463> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*-820463> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*-820463> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 3240
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  require(org-roam-bibtex)
  #<subr eval-buffer>(#<buffer  *load*-584088> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*-584088> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*-584088> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 1800
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  require(orb-note-actions)
  #<subr eval-buffer>(#<buffer  *load*-283384> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*-283384> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*-283384> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 3240
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  require(org-roam-bibtex)
  #<subr eval-buffer>(#<buffer  *load*-746175> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*-746175> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*-746175> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 1800
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  require(orb-note-actions)
  #<subr eval-buffer>(#<buffer  *load*> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  apply(#<subr eval-buffer> (#<buffer  *load*> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t))
  eval-buffer(#<buffer  *load*> nil "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)  ; Reading at buffer position 3240
  load-with-code-conversion("/home/arch/.emacs.d/.local/straight/build/org-ro..." "/home/arch/.emacs.d/.local/straight/build/org-ro..." nil t)
  command-execute(orb-find-non-ref-file record)
  counsel-M-x-action("orb-find-non-ref-file")
  ivy-call()
  ivy-read("M-x " ("toggle-debug-on-error" "orb-note-actions" "orb-find-non-ref-file" "orb-insert-non-ref" "org-roam-bibtex-mode" "org-ref-help" "org-ref" "ivy-bibtex" "doc-view-mode" "org-bibtex-write" "doi-insert-bibtex" "ivy-bibtex-with-local-bibliography" "eglot" "lsp-mode" "bibtex-url" "bibtex-yank" "eglot-format" "org-bibtex-read-buffer" "biblio--selection-insert" "org-roam-bibtex-find-non-ref-file" "R" "cd" "jb" "5x5" "SAS" "amx" "arp" "dbx" "dig" "erc" "ert" "eww" "ftp" "gdb" "irc" "jdb" "lsp" "man" "mpc" "orc" "orn" "oro" "orp" "oru" "pdb" "pwd" "rsh" "sdb" "wos" "xdb" ...) :predicate #f(compiled-function (x) #<bytecode 0xa5624ab57773cf>) :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x)
  counsel-M-x()
  funcall-interactively(counsel-M-x)
  command-execute(counsel-M-x)

Additional information that might help: I'm currently running DOOM Emacs, and am on GNU Emacs 28.0.50.

@zaeph
Copy link
Member

zaeph commented May 3, 2020

On it.

@zaeph zaeph self-assigned this May 3, 2020
@zaeph
Copy link
Member

zaeph commented May 3, 2020

Fixed in 8cc2d95. Sorry for that.

Can you confirm it works on your end when using master?

@dmgie
Copy link
Author

dmgie commented May 3, 2020

Yep, there seems to be no more recursive load error, but two other errors have shown up. When calling orb-note-actions or org-roam-bibtex-note-actions I get a (wrong-type-argument arrayp nil) error.

Backtrace:

Debugger entered--Lisp error: (wrong-type-argument arrayp nil)
  orb--unformat-citekey(nil)
  org-roam-bibtex-note-actions()
  funcall-interactively(org-roam-bibtex-note-actions)
  command-execute(org-roam-bibtex-note-actions record)
  counsel-M-x-action("org-roam-bibtex-note-actions")
  ivy-call()
  ivy-read("M-x " ("org-roam-bibtex-note-actions" "org-ref-helm-insert-cite-link" "orb-note-actions" "org-ref-insert-cite-with-completion" "org-ref-cite-click-helm" "org-ref-ivy-cite-completion" "org-roam-bibtex-insert-non-ref" "ivy-bibtex" "orb-find-non-ref-file" "doc-view-mode" "orb-insert-non-ref" "toggle-debug-on-error" "org-ref" "org-roam-bibtex-mode" "org-bibtex-write" "doi-insert-bibtex" "org-roam-bibtex-find-non-ref-file" "ivy-bibtex-with-local-bibliography" "eglot" "lsp-mode" "bibtex-url" "bibtex-yank" "eglot-format" "org-ref-help" "emacs-version" "org-ref-bibliography" "org-roam-build-cache" "org-bibtex-read-buffer" "biblio--selection-insert" "R" "cd" "jb" "5x5" "SAS" "amx" "arp" "dbx" "dig" "erc" "ert" "eww" "ftp" "gdb" "irc" "jdb" "lsp" "man" "mpc" "orc" "orn" ...) :predicate #f(compiled-function (x) #<bytecode 0xa514ccba94110f>) :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x)
  counsel-M-x()
  funcall-interactively(counsel-M-x)
  command-execute(counsel-M-x)

and when calling org-roam-bibtex-mode I get (void-variable bibtex-completion-find-note-functions)

Backtrace:

Debugger entered--Lisp error: (void-variable bibtex-completion-find-note-functions)
  org-roam-bibtex-mode(toggle)
  funcall-interactively(org-roam-bibtex-mode toggle)
  command-execute(org-roam-bibtex-mode record)
  counsel-M-x-action("org-roam-bibtex-mode")
  ivy-call()
  ivy-read("M-x " ("toggle-debug-on-error" "orb-note-actions" "org-roam-bibtex-mode" "org-ref-cite-click-helm" "org-ref-helm-insert-cite-link" "org-ref-insert-cite-with-completion" "org-ref-ivy-cite-completion" "ivy-bibtex" "orb-find-non-ref-file" "org-roam-bibtex-note-actions" "doc-view-mode" "orb-insert-non-ref" "org-ref" "org-bibtex-write" "doi-insert-bibtex" "org-roam-bibtex-find-non-ref-file" "ivy-bibtex-with-local-bibliography" "eglot" "lsp-mode" "bibtex-url" "bibtex-yank" "eglot-format" "org-ref-help" "emacs-version" "org-ref-bibliography" "org-roam-build-cache" "org-bibtex-read-buffer" "biblio--selection-insert" "org-roam-bibtex-insert-non-ref" "R" "cd" "jb" "5x5" "SAS" "amx" "arp" "dbx" "dig" "erc" "ert" "eww" "ftp" "gdb" "irc" "jdb" "lsp" "man" "mpc" "orc" "orn" ...) :predicate #f(compiled-function (x) #<bytecode 0xadaee38836a20f>) :require-match t :history counsel-M-x-history :action counsel-M-x-action :keymap (keymap (67108908 . counsel--info-lookup-symbol) (67108910 . counsel-find-symbol)) :initial-input nil :caller counsel-M-x)
  counsel-M-x()
  funcall-interactively(counsel-M-x)
  command-execute(counsel-M-x)

@zaeph
Copy link
Member

zaeph commented May 3, 2020

and when calling org-roam-bibtex-mode I get (void-variable bibtex-completion-find-note-functions)

I think this one might be due to an old version of bibtex-completion. You should try to install the latest version from MELPA.

I'm investigating the first one now.

@zaeph
Copy link
Member

zaeph commented May 3, 2020

Also, if you're using helm-bibtex or ivy-bibtex, please make sure to update them too. Since bibtex-completion.el used to be shipped with them, it has a tendency to shadow the proper version of bibtex-completion which is now in a package of their own.

@zaeph
Copy link
Member

zaeph commented May 3, 2020

Yep, there seems to be no more recursive load error, but two other errors have shown up. When calling orb-note-actions or org-roam-bibtex-note-actions I get a (wrong-type-argument arrayp nil) error.

This seems to be due to a problem retrieving the citekey of the current bibliographic note. Are you sure you had a #+ROAM-KEY: file-metdata tag in your file? Because I get the same error when I do not have one.

@dmgie
Copy link
Author

dmgie commented May 3, 2020

One thing I noticed when I cd'd into the .emacs.d/.local/straight/repos/helm-bibtex was that it was on the notes-finder-plugins branch instead of the master branch, where the former did not have bibtex-completion-find-note-functions. I don't know if this might've just been weird thing on my end. Switching it to the master branch ended up fixing the (void-variable bibtex-completion-find-note-functions) bug.

@dmgie
Copy link
Author

dmgie commented May 3, 2020

Yep, there seems to be no more recursive load error, but two other errors have shown up. When calling orb-note-actions or org-roam-bibtex-note-actions I get a (wrong-type-argument arrayp nil) error.

This seems to be due to a problem retrieving the citekey of the current bibliographic note. Are you sure you had a #+ROAM-KEY: file-metdata tag in your file? Because I get the same error when I do not have one.

Ah yeah, the one file I was trying it on didn't have a #+ROAM-KEY:. Added a roam key and it worked 👍
Thanks!

@zaeph
Copy link
Member

zaeph commented May 3, 2020

One thing I noticed when I cd'd into the .emacs.d/.local/straight/repos/helm-bibtex was that it was on the notes-finder-plugins branch instead of the master branch, where the former did not have bibtex-completion-find-note-functions.

Uhm, could have been something done by the Doom guys to incorporate a behaviour they wanted. The branch is 17 days old now, so yeah, the changes we've pushed to bibtex-completion where after that.

Ah yeah, the one file I was trying it on didn't have a #+ROAM-KEY:. Added a roam key and it worked +1
Thanks!

And thank you for bringing it up! I've opened #28 to address it, but we're waiting on upstream to merge features before we fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants