2

This problem only arose today and I haven't really changed anything substantial in my init.el so I am sure what the source of the error is. Essentially, when running org-capture (and also during startup) I get (json-readtable-error). When I set debug-on-error to be true, but could not find anything useful (debugger output is below).

Debugger entered--Lisp error: (error "Capture abort: (json-readtable-error)")
  signal(error ("Capture abort: (json-readtable-error)"))
  error("Capture abort: %s" (json-readtable-error))
  #[512 "\203�  \306=\203�\307\310\232!\311\232\203�\312 \207\313\232\203\"�\314 \207p\315\303!\2034�\2034�\316\f\317\"\202A�\3201?�\321\322!0\202A�\210\322
\206H�\323!\322@\206W�\324 \205W�`\325 {\262\211;\203f�\326\327G\330$\210;\203t�\326\327G\331$\210\332\232\203\200�\333\334!\202\222\335\232\203\214�\336\337!\202\222\340!\210\341 \210\342\343\344\345!\206\253�\346\347!\205\253�\350A\"@\351\345\n!\205\271�\352\345!!\317\n\353\n\354\355 \356\n\206\311�\357 &\210\360 \210\3611\334�\342\362\363 \"0\202\354�\364\365!\203\346�\366\365!\210\367\370\"\262\210\371\372!B\327\232\203\375�\373 \202\222\3741
\375\371\376!@\377=!0\202>\201E�p!\203'\201F�\201G�\201H� \"\203'\366p!\210\201I�\371\354!!\210\367\201J�\371\201K�!A@#\262\210\201L�\201M�!\203\206\371\201N�!\203\206\201O�1\201\201P� \203j\342\201Q�\201R�C!\"\210\201S� \210\201T�\201D�!\210\201U�\211D0\202\205\210\202\206\210\371\201V�!\205\222\201W� \207" [org-capture-use-agenda-date major-mode org-overriding-default-time org-capture-link-is-already-stored org-store-link-plist org-capture-entry org-agenda-mode org-get-cursor-date 1 (4) org-capture-goto-target (16) org-capture-goto-last-stored boundp plist-get :annotation (error) org-store-link nil org-capture-select-template org-region-active-p mark remove-text-properties 0 (read-only t) (read-only t) "C" customize-variable org-capture-templates "q" user-error "Abort" org-capture-set-plist org-capture-get-template org-capture-put :original-buffer :original-file buffer-file-name featurep dired rassq :original-file-nondirectory file-name-nondirectory :initial :return-to-wconf current-window-configuration :default-time org-current-time org-capture-set-target-location (error quit) ...] 21 ("/Users/bibekpokharel/.emacs.d/elpa/org-20180129/org-capture.elc" . 23542) "P"](nil nil)
  ad-Advice-org-capture(#[512 "\203�    \306=\203�\307\310\232!\311\232\203�\312 \207\313\232\203\"�\314 \207p\315\303!\2034�\2034�\316\f\317\"\202A�\3201?�\321\322!0\202A�\210\322
\206H�\323!\322@\206W�\324 \205W�`\325 {\262\211;\203f�\326\327G\330$\210;\203t�\326\327G\331$\210\332\232\203\200�\333\334!\202\222\335\232\203\214�\336\337!\202\222\340!\210\341 \210\342\343\344\345!\206\253�\346\347!\205\253�\350A\"@\351\345\n!\205\271�\352\345!!\317\n\353\n\354\355 \356\n\206\311�\357 &\210\360 \210\3611\334�\342\362\363 \"0\202\354�\364\365!\203\346�\366\365!\210\367\370\"\262\210\371\372!B\327\232\203\375�\373 \202\222\3741
\375\371\376!@\377=!0\202>\201E�p!\203'\201F�\201G�\201H� \"\203'\366p!\210\201I�\371\354!!\210\367\201J�\371\201K�!A@#\262\210\201L�\201M�!\203\206\371\201N�!\203\206\201O�1\201\201P� \203j\342\201Q�\201R�C!\"\210\201S� \210\201T�\201D�!\210\201U�\211D0\202\205\210\202\206\210\371\201V�!\205\222\201W� \207" [org-capture-use-agenda-date major-mode org-overriding-default-time org-capture-link-is-already-stored org-store-link-plist org-capture-entry org-agenda-mode org-get-cursor-date 1 (4) org-capture-goto-target (16) org-capture-goto-last-stored boundp plist-get :annotation (error) org-store-link nil org-capture-select-template org-region-active-p mark remove-text-properties 0 (read-only t) (read-only t) "C" customize-variable org-capture-templates "q" user-error "Abort" org-capture-set-plist org-capture-get-template org-capture-put :original-buffer :original-file buffer-file-name featurep dired rassq :original-file-nondirectory file-name-nondirectory :initial :return-to-wconf current-window-configuration :default-time org-current-time org-capture-set-target-location (error quit) ...] 21 ("/Users/bibekpokharel/.emacs.d/elpa/org-20180129/org-capture.elc" . 23542) "P"] nil)
   apply(ad-Advice-org-capture #[512 "\203� \306=\203�\307\310\232!\311\232\203�\312 \207\313\232\203\"�\314 \207p\315\303!\2034�\2034�\316\f\317\"\202A�\3201?�\321\322!0\202A�\210\322
\206H�\323!\322@\206W�\324 \205W�`\325 {\262\211;\203f�\326\327G\330$\210;\203t�\326\327G\331$\210\332\232\203\200�\333\334!\202\222\335\232\203\214�\336\337!\202\222\340!\210\341 \210\342\343\344\345!\206\253�\346\347!\205\253�\350A\"@\351\345\n!\205\271�\352\345!!\317\n\353\n\354\355 \356\n\206\311�\357 &\210\360 \210\3611\334�\342\362\363 \"0\202\354�\364\365!\203\346�\366\365!\210\367\370\"\262\210\371\372!B\327\232\203\375�\373 \202\222\3741
\375\371\376!@\377=!0\202>\201E�p!\203'\201F�\201G�\201H� \"\203'\366p!\210\201I�\371\354!!\210\367\201J�\371\201K�!A@#\262\210\201L�\201M�!\203\206\371\201N�!\203\206\201O�1\201\201P� \203j\342\201Q�\201R�C!\"\210\201S� \210\201T�\201D�!\210\201U�\211D0\202\205\210\202\206\210\371\201V�!\205\222\201W� \207" [org-capture-use-agenda-date major-mode org-overriding-default-time org-capture-link-is-already-stored org-store-link-plist org-capture-entry org-agenda-mode org-get-cursor-date 1 (4) org-capture-goto-target (16) org-capture-goto-last-stored boundp plist-get :annotation (error) org-store-link nil org-capture-select-template org-region-active-p mark remove-text-properties 0 (read-only t) (read-only t) "C" customize-variable org-capture-templates "q" user-error "Abort" org-capture-set-plist org-capture-get-template org-capture-put :original-buffer :original-file buffer-file-name featurep dired rassq :original-file-nondirectory file-name-nondirectory :initial :return-to-wconf current-window-configuration :default-time org-current-time org-capture-set-target-location (error quit) ...] 21 ("/Users/bibekpokharel/.emacs.d/elpa/org-20180129/org-capture.elc" . 23542) "P"] nil)
  org-capture(nil)
   funcall-interactively(org-capture nil)
  call-interactively(org-capture nil nil)
  command-execute(org-capture)
  • Maybe try (1) load the source file that defines command org-capture and then (2) M-x debug-on-entry org-capture. Then step through the debugger using d to see what goes wrong. But before doing that, check that you see the same problem when starting Emacs using emacs -Q (no init file). If not, bisect your init file to find the culprit. – Drew Jan 30 '18 at 1:49
  • Thanks for the comment @Drew. For anyone who is curious, adding the following code in the init.el solved the issue. Turns out emacs was not being able to load json setup. (when (memq window-system '(mac ns x)) (exec-path-from-shell-initialize)). – Quarky Quanta Feb 2 '18 at 2:55
1

For anyone who is curious, adding the following code in the init.el solved the issue. Turns out Rmacs was not being able to load JSON setup because it was looking in the wrong folder. I also had to install the package exec-path-from-shell.

(when (memq window-system '(mac ns x)) (exec-path-from-shell-initialize))

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.