Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maikol-solis/47aa20ab7c07737322bd17c146b1aa97 to your computer and use it in GitHub Desktop.
Save maikol-solis/47aa20ab7c07737322bd17c146b1aa97 to your computer and use it in GitHub Desktop.
org-ref error
Debugger entered--Lisp error: (wrong-type-argument stringp nil)
insert-file-contents(nil)
(progn (insert-file-contents bibfile) (bibtex-set-dialect (parsebib-find-bibtex-dialect) t) (bibtex-search-entry key) (bibtex-autokey-get-field "url"))
(unwind-protect (progn (insert-file-contents bibfile) (bibtex-set-dialect (parsebib-find-bibtex-dialect) t) (bibtex-search-entry key) (bibtex-autokey-get-field "url")) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))
(save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents bibfile) (bibtex-set-dialect (parsebib-find-bibtex-dialect) t) (bibtex-search-entry key) (bibtex-autokey-get-field "url")) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))
(let ((temp-buffer (generate-new-buffer " *temp*"))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents bibfile) (bibtex-set-dialect (parsebib-find-bibtex-dialect) t) (bibtex-search-entry key) (bibtex-autokey-get-field "url")) (and (buffer-name temp-buffer) (kill-buffer temp-buffer)))))
(save-excursion (let ((temp-buffer (generate-new-buffer " *temp*"))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (insert-file-contents bibfile) (bibtex-set-dialect (parsebib-find-bibtex-dialect) t) (bibtex-search-entry key) (bibtex-autokey-get-field "url")) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))))
(let* ((results (org-ref-get-bibtex-key-and-file)) (key (car results)) (bibfile (cdr results)) (bibtex-completion-bibliography (list bibfile)) (entry (bibtex-completion-get-entry key)) (pdf-file (funcall org-ref-get-pdf-filename-function key)) (pdf-bibtex-completion (car (bibtex-completion-find-pdf key))) (notes-p (cdr (assoc "=has-note=" entry))) (url (save-excursion (let ((temp-buffer (generate-new-buffer " *temp*"))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn ... ... ... ...) (and ... ...)))))) (doi (save-excursion (let ((temp-buffer (generate-new-buffer " *temp*"))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn ... ... ... ...) (and ... ...)))))) (candidates (quote (("Quit" . org-ref-citation-at-point) ("Open bibtex entry" . org-ref-open-citation-at-point))))) (if (string= doi "") (progn (setq doi nil))) (if (string= url "") (progn (setq url nil))) (cond ((file-exists-p pdf-file) (if (memql (quote ("Open pdf" lambda nil (funcall org-ref-open-pdf-function))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Open pdf" lambda nil ...)) candidates)))) (pdf-bibtex-completion (if (memql (quote ("Open pdf" lambda nil (funcall org-ref-open-pdf-function))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Open pdf" lambda nil ...)) candidates)))) (t (if (memql (quote ("Try to get pdf" lambda nil (save-window-excursion ... ... ...))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Try to get pdf" lambda nil ...)) candidates))))) (if notes-p (if (memql (quote ("Open notes" . org-ref-open-notes-at-point)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Open notes" . org-ref-open-notes-at-point)) candidates))) (if (memql (quote ("Add notes" . org-ref-open-notes-at-point)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Add notes" . org-ref-open-notes-at-point)) candidates)))) (if (or url doi) (progn (if (memql (quote ("Open in browser" . org-ref-open-url-at-point)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Open in browser" . org-ref-open-url-at-point)) candidates))))) (if doi (progn (mapc (function (lambda (x) (let* (...) (if ... ... ...)))) (quote (("WOS" . org-ref-wos-at-point) ("Related articles in WOS" . org-ref-wos-related-at-point) ("Citing articles in WOS" . org-ref-wos-citing-at-point) ("Google Scholar" . org-ref-google-scholar-at-point) ("Pubmed" . org-ref-pubmed-at-point) ("Crossref" . org-ref-crossref-at-point)))))) (if (memql (quote ("Insert new citation" lambda nil (org-ref-helm-insert-cite-link nil))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Insert new citation" lambda nil (org-ref-helm-insert-cite-link nil))) candidates))) (if (memql (quote ("Delete key at point" . org-ref-delete-key-at-point)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Delete key at point" . org-ref-delete-key-at-point)) candidates))) (if (memql (quote ("Replace key at point" . org-ref-replace-key-at-point)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Replace key at point" . org-ref-replace-key-at-point)) candidates))) (if (memql (quote ("Delete citation at point" . org-ref-delete-cite-at-point)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Delete citation at point" . org-ref-delete-cite-at-point)) candidates))) (if bibtex-completion-cite-prompt-for-optional-arguments (progn (if (memql (quote ("Update pre/post text" . org-ref-update-pre-post-text)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Update pre/post text" . org-ref-update-pre-post-text)) candidates))))) (if (memql (quote ("Sort keys by year" . org-ref-sort-citation-link)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Sort keys by year" . org-ref-sort-citation-link)) candidates))) (if (memql (quote ("Copy formatted citation to clipboard" . org-ref-copy-cite-as-summary)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Copy formatted citation to clipboard" . org-ref-copy-cite-as-summary)) candidates))) (if (memql (quote ("Copy key to clipboard" lambda nil (kill-new (car (org-ref-get-bibtex-key-and-file))))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Copy key to clipboard" lambda nil (kill-new (car ...)))) candidates))) (if (memql (quote ("Copy bibtex entry to file" . org-ref-copy-entry-at-point-to-file)) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Copy bibtex entry to file" . org-ref-copy-entry-at-point-to-file)) candidates))) (if (memql (quote ("Email bibtex entry and pdf" lambda nil (save-excursion (org-ref-open-citation-at-point) (org-ref-email-bibtex-entry)))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Email bibtex entry and pdf" lambda nil (save-excursion (org-ref-open-citation-at-point) (org-ref-email-bibtex-entry)))) candidates))) (if (and (boundp (quote *scopus-api-key*)) *scopus-api-key*) (progn (if (memql (quote ("Open in Scopus" lambda nil (let ... ...))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Open in Scopus" lambda nil ...)) candidates))) (if (memql (quote ("Scopus citing articles" lambda nil (let ... ...))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Scopus citing articles" lambda nil ...)) candidates))) (if (memql (quote ("Scopus related by authors" lambda nil (let ... ...))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Scopus related by authors" lambda nil ...)) candidates))) (if (memql (quote ("Scopus related by references" lambda nil (let ... ...))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Scopus related by references" lambda nil ...)) candidates))) (if (memql (quote ("Scopus related by keywords" lambda nil (let ... ...))) candidates) (with-no-warnings candidates) (setq candidates (cons (quote ("Scopus related by keywords" lambda nil ...)) candidates))))) (let* ((i 0) (--cl-var-- (reverse candidates)) (cell nil) (--cl-var-- nil)) (while (consp --cl-var--) (setq cell (car --cl-var--)) (setq --cl-var-- (cons (cons (format "%2s. %s" i (car cell)) (cdr cell)) --cl-var--)) (setq i (+ i 1)) (setq --cl-var-- (cdr --cl-var--))) (nreverse --cl-var--)))
org-ref-cite-candidates()
(let ((name (org-ref-format-entry (org-ref-get-bibtex-key-under-cursor))) (candidates (org-ref-cite-candidates)) (cb (current-buffer))) (helm :sources (list (list (cons (quote name) name) (cons (quote candidates) candidates) (cons (quote action) (cons (quote lambda) (cons (quote ...) (cons ... ...))))) (list (quote (name . "User functions")) (cons (quote candidates) org-ref-helm-user-candidates) (cons (quote action) (cons (quote lambda) (cons (quote ...) (cons ... ...))))))))
org-ref-cite-click-helm(nil)
funcall(org-ref-cite-click-helm nil)
(lambda (_) (funcall org-ref-cite-onclick-function nil))("Martinetz1991")
org-link-open((link (:type "cite" :path "Martinetz1991" :format plain :raw-link "cite:Martinetz1991" :application nil :search-option nil :begin 114 :end 132 :contents-begin nil :contents-end nil :post-blank 0 :parent (paragraph (:begin 103 :end 135 :contents-begin 103 :contents-end 133 :post-blank 2 :post-affiliated 103 :parent nil)))) nil)
org-open-at-point()
org-open-at-mouse((mouse-2 (#<window 3 on neural_gas_network_learns_topologies.org> 126 (226 . 180) 228850903 nil 126 (17 . 6) nil (5 . 18) (13 . 27))))
funcall-interactively(org-open-at-mouse (mouse-2 (#<window 3 on neural_gas_network_learns_topologies.org> 126 (226 . 180) 228850903 nil 126 (17 . 6) nil (5 . 18) (13 . 27))))
call-interactively(org-open-at-mouse nil nil)
command-execute(org-open-at-mouse)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment