mapcar: Wrong type argument: listp, \.\.\.

Issue #20 resolved
Shahin Azad
created an issue

Hi, I installed org-plus-contrib using elpa. After running org-drill I was getting this error:

 org-indent-add-properties: Invalid function: org-with-silent-modifications

This problem wasn't just for org-drill, I'll get it when I wanted to get my agenda report. So I googled and find at this is an elpa bug, and it can be solved by removing all that elc files.

This problem is gone and agenda report is working well, but I got a new error on 'org-drill'. This is the error:

mapcar: Wrong type argument: listp, \.\.\.

Comments (4)

  1. Paul Sexton repo owner

    Can you please turn on the option "Enter debugger on error" to identify the function causing the error? (i.e. the function belonging to org or org-drill that calls mapcar). Can you also tell me what version of org mode you are using (M-x org-version)? If that version is < 8.2.5, are you using the latest org-drill from this repo?

    One thing you might want to try is simply to reinstall org mode separately from ELPA - the official ELPA version tends to lag behind, cauing compatibility problems with plugins such as org-drill.

  2. Shahin Azad reporter

    I turned debug-on-error using toggle-debug-on-error command and this is the output when I try to run org-drill:

    Debugger entered--Lisp error: (wrong-type-argument listp \.\.\.)
      car(\.\.\.)
      mapcar(car (("~/Workspace/org/flashcard.org" "56e4d412-9f29-47b1-9ebd-d323fa29eeb8") ("~/Workspace/org/flashcard.org" "03d7765e-09d5-40ec-98e4-98bcf7e1a971") ("~/flashcards.org" "efb01187-261b-42e5-b79f-ff093ebd2765") ("~/flashcards.org" "6162f9f2-7303-4893-9469-1fc96bc3370a") ("~/spanish.org" "382f927a-b5b8-46c4-80c6-a240089a2942") ("~/spanish.org" "1b9b1e91-69fe-43a4-a8c7-601f93f685d4") ("~/spanish.org" "a6a38b32-beaa-497b-9d9e-c3b04a90e67a") ("~/spanish.org" "f91c5551-562e-43dd-89aa-179bb2a2ae3a") ("~/spanish.org" "94e6ebbc-1ea5-48ce-af47-7af9329f62bc") ("~/spanish.org" "108e6d73-d00d-4ace-8dca-016c0a641be1") \.\.\.))
      (setq org-id-files (mapcar (quote car) org-id-locations))
      (progn (let ((temp-buffer (generate-new-buffer " *temp*"))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (condition-case nil (progn (insert-file-contents-literally org-id-locations-file) (goto-char ...) (setq org-id-locations ...)) (error (message "Could not read org-id-values from %s.  Setting it to nil." org-id-locations-file)))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))) (setq org-id-files (mapcar (quote car) org-id-locations)) (setq org-id-locations (org-id-alist-to-hash org-id-locations)))
      (if org-id-track-globally (progn (let ((temp-buffer (generate-new-buffer " *temp*"))) (save-current-buffer (set-buffer temp-buffer) (unwind-protect (progn (condition-case nil (progn ... ... ...) (error ...))) (and (buffer-name temp-buffer) (kill-buffer temp-buffer))))) (setq org-id-files (mapcar (quote car) org-id-locations)) (setq org-id-locations (org-id-alist-to-hash org-id-locations))))
      org-id-locations-load()
      (if org-id-locations nil (org-id-locations-load))
      (progn (if org-id-locations nil (org-id-locations-load)) (puthash id (abbreviate-file-name file) org-id-locations) (add-to-list (quote org-id-files) (abbreviate-file-name file)))
      (if (and org-id-track-globally id file) (progn (if org-id-locations nil (org-id-locations-load)) (puthash id (abbreviate-file-name file) org-id-locations) (add-to-list (quote org-id-files) (abbreviate-file-name file))))
      org-id-add-location("7c9402ae-0524-40f5-8427-680cdb3a52ef" "/home/shahin/Workspace/org/flashcard.org")
      (cond ((and id (stringp id) (string-match "\\S-" id)) id) (create (setq id (org-id-new prefix)) (org-entry-put pom "ID" id) (org-id-add-location id (buffer-file-name (buffer-base-buffer))) id))
      (let ((id (org-entry-get nil "ID"))) (cond ((and id (stringp id) (string-match "\\S-" id)) id) (create (setq id (org-id-new prefix)) (org-entry-put pom "ID" id) (org-id-add-location id (buffer-file-name (buffer-base-buffer))) id)))
      (save-excursion (goto-char (or --mpom (point))) (let ((id (org-entry-get nil "ID"))) (cond ((and id (stringp id) (string-match "\\S-" id)) id) (create (setq id (org-id-new prefix)) (org-entry-put pom "ID" id) (org-id-add-location id (buffer-file-name (buffer-base-buffer))) id))))
      (save-excursion (if (markerp --mpom) (set-buffer (marker-buffer --mpom))) (save-excursion (goto-char (or --mpom (point))) (let ((id (org-entry-get nil "ID"))) (cond ((and id (stringp id) (string-match "\\S-" id)) id) (create (setq id (org-id-new prefix)) (org-entry-put pom "ID" id) (org-id-add-location id (buffer-file-name (buffer-base-buffer))) id)))))
      (let ((--mpom pom)) (save-excursion (if (markerp --mpom) (set-buffer (marker-buffer --mpom))) (save-excursion (goto-char (or --mpom (point))) (let ((id (org-entry-get nil "ID"))) (cond ((and id (stringp id) (string-match "\\S-" id)) id) (create (setq id (org-id-new prefix)) (org-entry-put pom "ID" id) (org-id-add-location id (buffer-file-name ...)) id))))))
      org-id-get(19258 create)
      org-id-get-create()
      (cond ((not (org-drill-entry-p)) nil) (t (if (and (not warned-about-id-creation) (null (org-id-get))) (progn (message (concat "Creating unique IDs for items " "(slow, but only happens once)")) (sit-for 0.5) (setq warned-about-id-creation t))) (org-id-get-create) (progn (let* ((--cl-rest-- (org-drill-entry-status)) (status (if (= ... 2) (car ...) (signal ... ...))) (due (car --cl-rest--))) (cond ((eql status (quote :unscheduled)) (setq *org-drill-dormant-entry-count* (1+ *org-drill-dormant-entry-count*))) ((eql status (quote :future)) (setq *org-drill-dormant-entry-count* (1+ *org-drill-dormant-entry-count*)) (if (eq -1 due) (setq *org-drill-due-tomorrow-count* ...))) ((eql status (quote :new)) (setq *org-drill-new-entries* (cons ... *org-drill-new-entries*))) ((eql status (quote :failed)) (setq *org-drill-failed-entries* (cons ... *org-drill-failed-entries*))) ((eql status (quote :young)) (setq *org-drill-young-mature-entries* (cons ... *org-drill-young-mature-entries*))) ((eql status (quote :overdue)) (setq overdue-data (cons ... overdue-data))) ((eql status (quote :old)) (setq *org-drill-old-mature-entries* (cons ... *org-drill-old-mature-entries*))))))))
      (lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not (org-drill-entry-p)) nil) (t (if (and (not warned-about-id-creation) (null (org-id-get))) (progn (message (concat "Creating unique IDs for items " "(slow, but only happens once)")) (sit-for 0.5) (setq warned-about-id-creation t))) (org-id-get-create) (progn (let* ((--cl-rest-- (org-drill-entry-status)) (status (if ... ... ...)) (due (car --cl-rest--))) (cond ((eql status ...) (setq *org-drill-dormant-entry-count* ...)) ((eql status ...) (setq *org-drill-dormant-entry-count* ...) (if ... ...)) ((eql status ...) (setq *org-drill-new-entries* ...)) ((eql status ...) (setq *org-drill-failed-entries* ...)) ((eql status ...) (setq *org-drill-young-mature-entries* ...)) ((eql status ...) (setq overdue-data ...)) ((eql status ...) (setq *org-drill-old-mature-entries* ...))))))))()
      funcall((lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not (org-drill-entry-p)) nil) (t (if (and (not warned-about-id-creation) (null (org-id-get))) (progn (message (concat "Creating unique IDs for items " "(slow, but only happens once)")) (sit-for 0.5) (setq warned-about-id-creation t))) (org-id-get-create) (progn (let* ((--cl-rest-- (org-drill-entry-status)) (status (if ... ... ...)) (due (car --cl-rest--))) (cond ((eql status ...) (setq *org-drill-dormant-entry-count* ...)) ((eql status ...) (setq *org-drill-dormant-entry-count* ...) (if ... ...)) ((eql status ...) (setq *org-drill-new-entries* ...)) ((eql status ...) (setq *org-drill-failed-entries* ...)) ((eql status ...) (setq *org-drill-young-mature-entries* ...)) ((eql status ...) (setq overdue-data ...)) ((eql status ...) (setq *org-drill-old-mature-entries* ...)))))))))
      (setq rtn1 (funcall action))
      (save-excursion (setq rtn1 (funcall action)) (setq rtn (cons rtn1 rtn)))
      (cond ((eq action (quote sparse-tree)) (and org-highlight-sparse-tree-matches (org-get-heading) (match-end 0) (org-highlight-new-match (match-beginning 1) (match-end 1))) (org-show-context (quote tags-tree))) ((eq action (quote agenda)) (setq txt (org-agenda-format-item "" (concat (if (eq org-tags-match-list-sublevels (quote indented)) (make-string (1- level) 46) "") (org-get-heading)) level category tags-list) priority (org-get-priority txt)) (goto-char lspos) (setq marker (org-agenda-new-marker)) (org-add-props txt props (quote org-marker) marker (quote org-hd-marker) marker (quote org-category) category (quote todo-state) todo (quote priority) priority (quote type) "tagsmatch") (setq rtn (cons txt rtn))) ((functionp action) (setq org-map-continue-from nil) (save-excursion (setq rtn1 (funcall action)) (setq rtn (cons rtn1 rtn)))) (t (user-error "Invalid action")))
      (progn (cond ((eq action (quote sparse-tree)) (and org-highlight-sparse-tree-matches (org-get-heading) (match-end 0) (org-highlight-new-match (match-beginning 1) (match-end 1))) (org-show-context (quote tags-tree))) ((eq action (quote agenda)) (setq txt (org-agenda-format-item "" (concat (if (eq org-tags-match-list-sublevels ...) (make-string ... 46) "") (org-get-heading)) level category tags-list) priority (org-get-priority txt)) (goto-char lspos) (setq marker (org-agenda-new-marker)) (org-add-props txt props (quote org-marker) marker (quote org-hd-marker) marker (quote org-category) category (quote todo-state) todo (quote priority) priority (quote type) "tagsmatch") (setq rtn (cons txt rtn))) ((functionp action) (setq org-map-continue-from nil) (save-excursion (setq rtn1 (funcall action)) (setq rtn (cons rtn1 rtn)))) (t (user-error "Invalid action"))) (if org-tags-match-list-sublevels nil (org-end-of-subtree t) (backward-char 1)))
      (if (and (and (or (not todo-only) (member todo org-not-done-keywords)) (let ((case-fold-search t) (org-trust-scanner-tags t)) (eval matcher))) (progn (if (eq action (quote sparse-tree)) nil (org-agenda-skip)) t) (or (not todo-only) (and (member todo org-not-done-keywords) (or (not org-agenda-tags-todo-honor-ignore-options) (not (org-agenda-check-for-timestamp-as-reason-to-ignore-todo-item)))))) (progn (cond ((eq action (quote sparse-tree)) (and org-highlight-sparse-tree-matches (org-get-heading) (match-end 0) (org-highlight-new-match (match-beginning 1) (match-end 1))) (org-show-context (quote tags-tree))) ((eq action (quote agenda)) (setq txt (org-agenda-format-item "" (concat (if ... ... "") (org-get-heading)) level category tags-list) priority (org-get-priority txt)) (goto-char lspos) (setq marker (org-agenda-new-marker)) (org-add-props txt props (quote org-marker) marker (quote org-hd-marker) marker (quote org-category) category (quote todo-state) todo (quote priority) priority (quote type) "tagsmatch") (setq rtn (cons txt rtn))) ((functionp action) (setq org-map-continue-from nil) (save-excursion (setq rtn1 (funcall action)) (setq rtn (cons rtn1 rtn)))) (t (user-error "Invalid action"))) (if org-tags-match-list-sublevels nil (org-end-of-subtree t) (backward-char 1))))
      (catch :skip (setq todo (if (match-end 1) (org-match-string-no-properties 2)) tags (if (match-end 4) (org-match-string-no-properties 4))) (goto-char (setq lspos (match-beginning 0))) (setq level (org-reduced-level (org-outline-level)) category (org-get-category)) (setq i llast llast level) (while (>= i level) (if (setq entry (assoc i tags-alist)) (progn (setq tags-alist (delete entry tags-alist)))) (setq i (1- i))) (if tags (progn (setq tags (org-split-string tags ":") tags-alist (cons (cons level tags) tags-alist)))) (setq tags-list (if org-use-tag-inheritance (apply (quote append) (mapcar (quote cdr) (reverse tags-alist))) tags) org-scanner-tags tags-list) (if org-use-tag-inheritance (progn (setcdr (car tags-alist) (mapcar (function (lambda (x) (setq x ...) (org-add-prop-inherited x))) (cdar tags-alist))))) (if (and tags org-use-tag-inheritance (or (not (eq t org-use-tag-inheritance)) org-tags-exclude-from-inheritance)) (progn (setcdr (car tags-alist) (org-remove-uninherited-tags (cdar tags-alist))))) (if (and (and (or (not todo-only) (member todo org-not-done-keywords)) (let ((case-fold-search t) (org-trust-scanner-tags t)) (eval matcher))) (progn (if (eq action (quote sparse-tree)) nil (org-agenda-skip)) t) (or (not todo-only) (and (member todo org-not-done-keywords) (or (not org-agenda-tags-todo-honor-ignore-options) (not (org-agenda-check-for-timestamp-as-reason-to-ignore-todo-item)))))) (progn (cond ((eq action (quote sparse-tree)) (and org-highlight-sparse-tree-matches (org-get-heading) (match-end 0) (org-highlight-new-match (match-beginning 1) (match-end 1))) (org-show-context (quote tags-tree))) ((eq action (quote agenda)) (setq txt (org-agenda-format-item "" (concat ... ...) level category tags-list) priority (org-get-priority txt)) (goto-char lspos) (setq marker (org-agenda-new-marker)) (org-add-props txt props (quote org-marker) marker (quote org-hd-marker) marker (quote org-category) category (quote todo-state) todo (quote priority) priority (quote type) "tagsmatch") (setq rtn (cons txt rtn))) ((functionp action) (setq org-map-continue-from nil) (save-excursion (setq rtn1 (funcall action)) (setq rtn (cons rtn1 rtn)))) (t (user-error "Invalid action"))) (if org-tags-match-list-sublevels nil (org-end-of-subtree t) (backward-char 1)))))
      (while (let (case-fold-search) (re-search-forward re nil t)) (setq org-map-continue-from nil) (catch :skip (setq todo (if (match-end 1) (org-match-string-no-properties 2)) tags (if (match-end 4) (org-match-string-no-properties 4))) (goto-char (setq lspos (match-beginning 0))) (setq level (org-reduced-level (org-outline-level)) category (org-get-category)) (setq i llast llast level) (while (>= i level) (if (setq entry (assoc i tags-alist)) (progn (setq tags-alist (delete entry tags-alist)))) (setq i (1- i))) (if tags (progn (setq tags (org-split-string tags ":") tags-alist (cons (cons level tags) tags-alist)))) (setq tags-list (if org-use-tag-inheritance (apply (quote append) (mapcar (quote cdr) (reverse tags-alist))) tags) org-scanner-tags tags-list) (if org-use-tag-inheritance (progn (setcdr (car tags-alist) (mapcar (function (lambda ... ... ...)) (cdar tags-alist))))) (if (and tags org-use-tag-inheritance (or (not (eq t org-use-tag-inheritance)) org-tags-exclude-from-inheritance)) (progn (setcdr (car tags-alist) (org-remove-uninherited-tags (cdar tags-alist))))) (if (and (and (or (not todo-only) (member todo org-not-done-keywords)) (let ((case-fold-search t) (org-trust-scanner-tags t)) (eval matcher))) (progn (if (eq action (quote sparse-tree)) nil (org-agenda-skip)) t) (or (not todo-only) (and (member todo org-not-done-keywords) (or (not org-agenda-tags-todo-honor-ignore-options) (not ...))))) (progn (cond ((eq action (quote sparse-tree)) (and org-highlight-sparse-tree-matches (org-get-heading) (match-end 0) (org-highlight-new-match ... ...)) (org-show-context (quote tags-tree))) ((eq action (quote agenda)) (setq txt (org-agenda-format-item "" ... level category tags-list) priority (org-get-priority txt)) (goto-char lspos) (setq marker (org-agenda-new-marker)) (org-add-props txt props (quote org-marker) marker (quote org-hd-marker) marker (quote org-category) category (quote todo-state) todo (quote priority) priority (quote type) "tagsmatch") (setq rtn (cons txt rtn))) ((functionp action) (setq org-map-continue-from nil) (save-excursion (setq rtn1 ...) (setq rtn ...))) (t (user-error "Invalid action"))) (if org-tags-match-list-sublevels nil (org-end-of-subtree t) (backward-char 1))))) (if org-map-continue-from (goto-char org-map-continue-from) (and (= (point) lspos) (end-of-line 1))))
      (save-excursion (goto-char (point-min)) (if (eq action (quote sparse-tree)) (progn (org-overview) (org-remove-occur-highlights))) (while (let (case-fold-search) (re-search-forward re nil t)) (setq org-map-continue-from nil) (catch :skip (setq todo (if (match-end 1) (org-match-string-no-properties 2)) tags (if (match-end 4) (org-match-string-no-properties 4))) (goto-char (setq lspos (match-beginning 0))) (setq level (org-reduced-level (org-outline-level)) category (org-get-category)) (setq i llast llast level) (while (>= i level) (if (setq entry (assoc i tags-alist)) (progn (setq tags-alist (delete entry tags-alist)))) (setq i (1- i))) (if tags (progn (setq tags (org-split-string tags ":") tags-alist (cons (cons level tags) tags-alist)))) (setq tags-list (if org-use-tag-inheritance (apply (quote append) (mapcar (quote cdr) (reverse tags-alist))) tags) org-scanner-tags tags-list) (if org-use-tag-inheritance (progn (setcdr (car tags-alist) (mapcar (function ...) (cdar tags-alist))))) (if (and tags org-use-tag-inheritance (or (not (eq t org-use-tag-inheritance)) org-tags-exclude-from-inheritance)) (progn (setcdr (car tags-alist) (org-remove-uninherited-tags (cdar tags-alist))))) (if (and (and (or (not todo-only) (member todo org-not-done-keywords)) (let (... ...) (eval matcher))) (progn (if (eq action ...) nil (org-agenda-skip)) t) (or (not todo-only) (and (member todo org-not-done-keywords) (or ... ...)))) (progn (cond ((eq action ...) (and org-highlight-sparse-tree-matches ... ... ...) (org-show-context ...)) ((eq action ...) (setq txt ... priority ...) (goto-char lspos) (setq marker ...) (org-add-props txt props ... marker ... marker ... category ... todo ... priority ... "tagsmatch") (setq rtn ...)) ((functionp action) (setq org-map-continue-from nil) (save-excursion ... ...)) (t (user-error "Invalid action"))) (if org-tags-match-list-sublevels nil (org-end-of-subtree t) (backward-char 1))))) (if org-map-continue-from (goto-char org-map-continue-from) (and (= (point) lspos) (end-of-line 1)))))
      (let* ((re (concat "^" (if start-level (concat "\\*\\{" (number-to-string start-level) "\\} ") org-outline-regexp) " *\\(\\<\\(" (mapconcat (quote regexp-quote) org-todo-keywords-1 "\\|") "\\)\\>\\)? *\\(.*?\\)\\(:[[:alnum:]_@#%:]+:\\)?[     ]*$")) (props (list (quote face) (quote default) (quote done-face) (quote org-agenda-done) (quote undone-face) (quote default) (quote mouse-face) (quote highlight) (quote org-not-done-regexp) org-not-done-regexp (quote org-todo-regexp) org-todo-regexp (quote org-complex-heading-regexp) org-complex-heading-regexp (quote help-echo) (format "mouse-2 or RET jump to org file %s" (abbreviate-file-name (or (buffer-file-name ...) (buffer-name ...)))))) (org-map-continue-from nil) lspos tags tags-list (tags-alist (list (cons 0 org-file-tags))) (llast 0) rtn rtn1 level category i txt todo marker entry priority) (if (not (or (member action (quote (agenda sparse-tree))) (functionp action))) (progn (setq action (list (quote lambda) nil action)))) (save-excursion (goto-char (point-min)) (if (eq action (quote sparse-tree)) (progn (org-overview) (org-remove-occur-highlights))) (while (let (case-fold-search) (re-search-forward re nil t)) (setq org-map-continue-from nil) (catch :skip (setq todo (if (match-end 1) (org-match-string-no-properties 2)) tags (if (match-end 4) (org-match-string-no-properties 4))) (goto-char (setq lspos (match-beginning 0))) (setq level (org-reduced-level (org-outline-level)) category (org-get-category)) (setq i llast llast level) (while (>= i level) (if (setq entry (assoc i tags-alist)) (progn (setq tags-alist ...))) (setq i (1- i))) (if tags (progn (setq tags (org-split-string tags ":") tags-alist (cons ... tags-alist)))) (setq tags-list (if org-use-tag-inheritance (apply (quote append) (mapcar ... ...)) tags) org-scanner-tags tags-list) (if org-use-tag-inheritance (progn (setcdr (car tags-alist) (mapcar ... ...)))) (if (and tags org-use-tag-inheritance (or (not ...) org-tags-exclude-from-inheritance)) (progn (setcdr (car tags-alist) (org-remove-uninherited-tags ...)))) (if (and (and (or ... ...) (let ... ...)) (progn (if ... nil ...) t) (or (not todo-only) (and ... ...))) (progn (cond (... ... ...) (... ... ... ... ... ...) (... ... ...) (t ...)) (if org-tags-match-list-sublevels nil (org-end-of-subtree t) (backward-char 1))))) (if org-map-continue-from (goto-char org-map-continue-from) (and (= (point) lspos) (end-of-line 1))))) (if (and (eq action (quote sparse-tree)) (not org-sparse-tree-open-archived-trees)) (progn (org-hide-archived-subtrees (point-min) (point-max)))) (nreverse rtn))
      org-scan-tags((lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not (org-drill-entry-p)) nil) (t (if (and (not warned-about-id-creation) (null (org-id-get))) (progn (message (concat "Creating unique IDs for items " "(slow, but only happens once)")) (sit-for 0.5) (setq warned-about-id-creation t))) (org-id-get-create) (progn (let* ((--cl-rest-- (org-drill-entry-status)) (status (if ... ... ...)) (due (car --cl-rest--))) (cond ((eql status ...) (setq *org-drill-dormant-entry-count* ...)) ((eql status ...) (setq *org-drill-dormant-entry-count* ...) (if ... ...)) ((eql status ...) (setq *org-drill-new-entries* ...)) ((eql status ...) (setq *org-drill-failed-entries* ...)) ((eql status ...) (setq *org-drill-young-mature-entries* ...)) ((eql status ...) (setq overdue-data ...)) ((eql status ...) (setq *org-drill-old-mature-entries* ...)))))))) (and (progn (setq org-cached-props nil) (member "drill" tags-list)) t) nil nil)
      (setq res (org-scan-tags func matcher todo-only start-level))
      (progn (org-agenda-prepare-buffers (list (buffer-file-name (current-buffer)))) (setq res (org-scan-tags func matcher todo-only start-level)))
      (if (not scope) (progn (org-agenda-prepare-buffers (list (buffer-file-name (current-buffer)))) (setq res (org-scan-tags func matcher todo-only start-level))) (cond ((and scope (listp scope) (symbolp (car scope))) (setq scope (eval scope))) ((eq scope (quote agenda)) (setq scope (org-agenda-files t))) ((eq scope (quote agenda-with-archives)) (setq scope (org-agenda-files t)) (setq scope (org-add-archive-files scope))) ((eq scope (quote file)) (setq scope (list (buffer-file-name)))) ((eq scope (quote file-with-archives)) (setq scope (org-add-archive-files (list (buffer-file-name)))))) (org-agenda-prepare-buffers scope) (while (setq file (car (prog1 scope (setq scope (cdr scope))))) (save-current-buffer (set-buffer (org-find-base-buffer-visiting file)) (save-excursion (save-restriction (widen) (goto-char (point-min)) (setq res (append res (org-scan-tags func matcher todo-only))))))))
      (save-restriction (cond ((eq scope (quote tree)) (org-back-to-heading t) (org-narrow-to-subtree) (setq scope nil)) ((and (or (eq scope (quote region)) (eq scope (quote region-start-level))) (org-region-active-p)) (if start-level (progn (save-excursion (goto-char (region-beginning)) (if (org-at-heading-p) nil (outline-next-heading)) (setq start-level (org-current-level))))) (narrow-to-region (region-beginning) (save-excursion (goto-char (region-end)) (if (and (bolp) (org-at-heading-p)) nil (outline-next-heading)) (point))) (setq scope nil))) (if (not scope) (progn (org-agenda-prepare-buffers (list (buffer-file-name (current-buffer)))) (setq res (org-scan-tags func matcher todo-only start-level))) (cond ((and scope (listp scope) (symbolp (car scope))) (setq scope (eval scope))) ((eq scope (quote agenda)) (setq scope (org-agenda-files t))) ((eq scope (quote agenda-with-archives)) (setq scope (org-agenda-files t)) (setq scope (org-add-archive-files scope))) ((eq scope (quote file)) (setq scope (list (buffer-file-name)))) ((eq scope (quote file-with-archives)) (setq scope (org-add-archive-files (list (buffer-file-name)))))) (org-agenda-prepare-buffers scope) (while (setq file (car (prog1 scope (setq scope (cdr scope))))) (save-current-buffer (set-buffer (org-find-base-buffer-visiting file)) (save-excursion (save-restriction (widen) (goto-char (point-min)) (setq res (append res ...))))))))
      (save-excursion (save-restriction (cond ((eq scope (quote tree)) (org-back-to-heading t) (org-narrow-to-subtree) (setq scope nil)) ((and (or (eq scope (quote region)) (eq scope (quote region-start-level))) (org-region-active-p)) (if start-level (progn (save-excursion (goto-char ...) (if ... nil ...) (setq start-level ...)))) (narrow-to-region (region-beginning) (save-excursion (goto-char (region-end)) (if (and ... ...) nil (outline-next-heading)) (point))) (setq scope nil))) (if (not scope) (progn (org-agenda-prepare-buffers (list (buffer-file-name (current-buffer)))) (setq res (org-scan-tags func matcher todo-only start-level))) (cond ((and scope (listp scope) (symbolp (car scope))) (setq scope (eval scope))) ((eq scope (quote agenda)) (setq scope (org-agenda-files t))) ((eq scope (quote agenda-with-archives)) (setq scope (org-agenda-files t)) (setq scope (org-add-archive-files scope))) ((eq scope (quote file)) (setq scope (list (buffer-file-name)))) ((eq scope (quote file-with-archives)) (setq scope (org-add-archive-files (list ...))))) (org-agenda-prepare-buffers scope) (while (setq file (car (prog1 scope (setq scope ...)))) (save-current-buffer (set-buffer (org-find-base-buffer-visiting file)) (save-excursion (save-restriction (widen) (goto-char ...) (setq res ...))))))))
      (let* ((org-agenda-archives-mode nil) (org-agenda-skip-archived-trees (memq (quote archive) skip)) (org-agenda-skip-comment-trees (memq (quote comment) skip)) (org-agenda-skip-function (car (org-delete-all (quote (comment archive)) skip))) (org-tags-match-list-sublevels t) (start-level (eq scope (quote region-start-level))) matcher file res org-todo-keywords-for-agenda org-done-keywords-for-agenda org-todo-keyword-alist-for-agenda org-drawers-for-agenda org-tag-alist-for-agenda todo-only) (cond ((eq match t) (setq matcher t)) ((eq match nil) (setq matcher t)) (t (setq matcher (if match (cdr (org-make-tags-matcher match)) t)))) (save-excursion (save-restriction (cond ((eq scope (quote tree)) (org-back-to-heading t) (org-narrow-to-subtree) (setq scope nil)) ((and (or (eq scope ...) (eq scope ...)) (org-region-active-p)) (if start-level (progn (save-excursion ... ... ...))) (narrow-to-region (region-beginning) (save-excursion (goto-char ...) (if ... nil ...) (point))) (setq scope nil))) (if (not scope) (progn (org-agenda-prepare-buffers (list (buffer-file-name ...))) (setq res (org-scan-tags func matcher todo-only start-level))) (cond ((and scope (listp scope) (symbolp ...)) (setq scope (eval scope))) ((eq scope (quote agenda)) (setq scope (org-agenda-files t))) ((eq scope (quote agenda-with-archives)) (setq scope (org-agenda-files t)) (setq scope (org-add-archive-files scope))) ((eq scope (quote file)) (setq scope (list ...))) ((eq scope (quote file-with-archives)) (setq scope (org-add-archive-files ...)))) (org-agenda-prepare-buffers scope) (while (setq file (car (prog1 scope ...))) (save-current-buffer (set-buffer (org-find-base-buffer-visiting file)) (save-excursion (save-restriction ... ... ...))))))) res)
      (if (and (or (eq scope (quote region)) (eq scope (quote region-start-level))) (not (org-region-active-p))) nil (let* ((org-agenda-archives-mode nil) (org-agenda-skip-archived-trees (memq (quote archive) skip)) (org-agenda-skip-comment-trees (memq (quote comment) skip)) (org-agenda-skip-function (car (org-delete-all (quote (comment archive)) skip))) (org-tags-match-list-sublevels t) (start-level (eq scope (quote region-start-level))) matcher file res org-todo-keywords-for-agenda org-done-keywords-for-agenda org-todo-keyword-alist-for-agenda org-drawers-for-agenda org-tag-alist-for-agenda todo-only) (cond ((eq match t) (setq matcher t)) ((eq match nil) (setq matcher t)) (t (setq matcher (if match (cdr (org-make-tags-matcher match)) t)))) (save-excursion (save-restriction (cond ((eq scope (quote tree)) (org-back-to-heading t) (org-narrow-to-subtree) (setq scope nil)) ((and (or ... ...) (org-region-active-p)) (if start-level (progn ...)) (narrow-to-region (region-beginning) (save-excursion ... ... ...)) (setq scope nil))) (if (not scope) (progn (org-agenda-prepare-buffers (list ...)) (setq res (org-scan-tags func matcher todo-only start-level))) (cond ((and scope ... ...) (setq scope ...)) ((eq scope ...) (setq scope ...)) ((eq scope ...) (setq scope ...) (setq scope ...)) ((eq scope ...) (setq scope ...)) ((eq scope ...) (setq scope ...))) (org-agenda-prepare-buffers scope) (while (setq file (car ...)) (save-current-buffer (set-buffer ...) (save-excursion ...)))))) res))
      org-map-entries((lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not (org-drill-entry-p)) nil) (t (if (and (not warned-about-id-creation) (null (org-id-get))) (progn (message (concat "Creating unique IDs for items " "(slow, but only happens once)")) (sit-for 0.5) (setq warned-about-id-creation t))) (org-id-get-create) (progn (let* ((--cl-rest-- (org-drill-entry-status)) (status (if ... ... ...)) (due (car --cl-rest--))) (cond ((eql status ...) (setq *org-drill-dormant-entry-count* ...)) ((eql status ...) (setq *org-drill-dormant-entry-count* ...) (if ... ...)) ((eql status ...) (setq *org-drill-new-entries* ...)) ((eql status ...) (setq *org-drill-failed-entries* ...)) ((eql status ...) (setq *org-drill-young-mature-entries* ...)) ((eql status ...) (setq overdue-data ...)) ((eql status ...) (setq *org-drill-old-mature-entries* ...)))))))) "+drill" nil)
      apply(org-map-entries (lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not (org-drill-entry-p)) nil) (t (if (and (not warned-about-id-creation) (null (org-id-get))) (progn (message (concat "Creating unique IDs for items " "(slow, but only happens once)")) (sit-for 0.5) (setq warned-about-id-creation t))) (org-id-get-create) (progn (let* ((--cl-rest-- (org-drill-entry-status)) (status (if ... ... ...)) (due (car --cl-rest--))) (cond ((eql status ...) (setq *org-drill-dormant-entry-count* ...)) ((eql status ...) (setq *org-drill-dormant-entry-count* ...) (if ... ...)) ((eql status ...) (setq *org-drill-new-entries* ...)) ((eql status ...) (setq *org-drill-failed-entries* ...)) ((eql status ...) (setq *org-drill-young-mature-entries* ...)) ((eql status ...) (setq overdue-data ...)) ((eql status ...) (setq *org-drill-old-mature-entries* ...)))))))) "+drill" nil nil)
      (let ((org-drill-scope (or scope org-drill-scope))) (apply (quote org-map-entries) func (concat "+" org-drill-question-tag) (cond ((eql org-drill-scope (quote file)) nil) ((eql org-drill-scope (quote file-no-restriction)) (quote file)) ((eql org-drill-scope (quote directory)) (directory-files (file-name-directory (buffer-file-name)) t "\\.org$")) (t org-drill-scope)) skip))
      org-map-drill-entries((lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not (org-drill-entry-p)) nil) (t (if (and (not warned-about-id-creation) (null (org-id-get))) (progn (message (concat "Creating unique IDs for items " "(slow, but only happens once)")) (sit-for 0.5) (setq warned-about-id-creation t))) (org-id-get-create) (progn (let* ((--cl-rest-- (org-drill-entry-status)) (status (if ... ... ...)) (due (car --cl-rest--))) (cond ((eql status ...) (setq *org-drill-dormant-entry-count* ...)) ((eql status ...) (setq *org-drill-dormant-entry-count* ...) (if ... ...)) ((eql status ...) (setq *org-drill-new-entries* ...)) ((eql status ...) (setq *org-drill-failed-entries* ...)) ((eql status ...) (setq *org-drill-young-mature-entries* ...)) ((eql status ...) (setq overdue-data ...)) ((eql status ...) (setq *org-drill-old-mature-entries* ...)))))))) nil)
      (let ((org-trust-scanner-tags t) (warned-about-id-creation nil)) (org-map-drill-entries (function (lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not (org-drill-entry-p)) nil) (t (if (and ... ...) (progn ... ... ...)) (org-id-get-create) (progn (let* ... ...)))))) scope) (org-drill-order-overdue-entries overdue-data) (setq *org-drill-overdue-entry-count* (length *org-drill-overdue-entries*)))
      (if resume-p nil (let ((org-trust-scanner-tags t) (warned-about-id-creation nil)) (org-map-drill-entries (function (lambda nil (org-drill-progress-message (+ (length *org-drill-new-entries*) (length *org-drill-overdue-entries*) (length *org-drill-young-mature-entries*) (length *org-drill-old-mature-entries*) (length *org-drill-failed-entries*)) (setq cnt (1+ cnt))) (cond ((not ...) nil) (t (if ... ...) (org-id-get-create) (progn ...))))) scope) (org-drill-order-overdue-entries overdue-data) (setq *org-drill-overdue-entry-count* (length *org-drill-overdue-entries*))))
      (save-excursion (if resume-p nil (let ((org-trust-scanner-tags t) (warned-about-id-creation nil)) (org-map-drill-entries (function (lambda nil (org-drill-progress-message (+ ... ... ... ... ...) (setq cnt ...)) (cond (... nil) (t ... ... ...)))) scope) (org-drill-order-overdue-entries overdue-data) (setq *org-drill-overdue-entry-count* (length *org-drill-overdue-entries*)))) (setq *org-drill-due-entry-count* (org-drill-pending-entry-count)) (cond ((and (null *org-drill-current-item*) (null *org-drill-new-entries*) (null *org-drill-failed-entries*) (null *org-drill-overdue-entries*) (null *org-drill-young-mature-entries*) (null *org-drill-old-mature-entries*)) (message "I did not find any pending drill items.")) (t (org-drill-entries resume-p) (message "Drill session finished!"))))
      (unwind-protect (save-excursion (if resume-p nil (let ((org-trust-scanner-tags t) (warned-about-id-creation nil)) (org-map-drill-entries (function (lambda nil (org-drill-progress-message ... ...) (cond ... ...))) scope) (org-drill-order-overdue-entries overdue-data) (setq *org-drill-overdue-entry-count* (length *org-drill-overdue-entries*)))) (setq *org-drill-due-entry-count* (org-drill-pending-entry-count)) (cond ((and (null *org-drill-current-item*) (null *org-drill-new-entries*) (null *org-drill-failed-entries*) (null *org-drill-overdue-entries*) (null *org-drill-young-mature-entries*) (null *org-drill-old-mature-entries*)) (message "I did not find any pending drill items.")) (t (org-drill-entries resume-p) (message "Drill session finished!")))) (progn (if end-pos nil (setq *org-drill-cram-mode* nil) (org-drill-free-markers *org-drill-done-entries*))))
      (progn (if resume-p nil (org-drill-free-markers t) (setq *org-drill-current-item* nil *org-drill-done-entries* nil *org-drill-dormant-entry-count* 0 *org-drill-due-entry-count* 0 *org-drill-due-tomorrow-count* 0 *org-drill-overdue-entry-count* 0 *org-drill-new-entries* nil *org-drill-overdue-entries* nil *org-drill-young-mature-entries* nil *org-drill-old-mature-entries* nil *org-drill-failed-entries* nil *org-drill-again-entries* nil) (setq *org-drill-session-qualities* nil) (setq *org-drill-start-time* (float-time (current-time)))) (setq *random-state* (make-random-state t)) (unwind-protect (save-excursion (if resume-p nil (let ((org-trust-scanner-tags t) (warned-about-id-creation nil)) (org-map-drill-entries (function (lambda nil ... ...)) scope) (org-drill-order-overdue-entries overdue-data) (setq *org-drill-overdue-entry-count* (length *org-drill-overdue-entries*)))) (setq *org-drill-due-entry-count* (org-drill-pending-entry-count)) (cond ((and (null *org-drill-current-item*) (null *org-drill-new-entries*) (null *org-drill-failed-entries*) (null *org-drill-overdue-entries*) (null *org-drill-young-mature-entries*) (null *org-drill-old-mature-entries*)) (message "I did not find any pending drill items.")) (t (org-drill-entries resume-p) (message "Drill session finished!")))) (progn (if end-pos nil (setq *org-drill-cram-mode* nil) (org-drill-free-markers *org-drill-done-entries*)))))
      (let ((end-pos nil) (overdue-data nil) (cnt 0)) (progn (if resume-p nil (org-drill-free-markers t) (setq *org-drill-current-item* nil *org-drill-done-entries* nil *org-drill-dormant-entry-count* 0 *org-drill-due-entry-count* 0 *org-drill-due-tomorrow-count* 0 *org-drill-overdue-entry-count* 0 *org-drill-new-entries* nil *org-drill-overdue-entries* nil *org-drill-young-mature-entries* nil *org-drill-old-mature-entries* nil *org-drill-failed-entries* nil *org-drill-again-entries* nil) (setq *org-drill-session-qualities* nil) (setq *org-drill-start-time* (float-time (current-time)))) (setq *random-state* (make-random-state t)) (unwind-protect (save-excursion (if resume-p nil (let ((org-trust-scanner-tags t) (warned-about-id-creation nil)) (org-map-drill-entries (function ...) scope) (org-drill-order-overdue-entries overdue-data) (setq *org-drill-overdue-entry-count* (length *org-drill-overdue-entries*)))) (setq *org-drill-due-entry-count* (org-drill-pending-entry-count)) (cond ((and (null *org-drill-current-item*) (null *org-drill-new-entries*) (null *org-drill-failed-entries*) (null *org-drill-overdue-entries*) (null *org-drill-young-mature-entries*) (null *org-drill-old-mature-entries*)) (message "I did not find any pending drill items.")) (t (org-drill-entries resume-p) (message "Drill session finished!")))) (progn (if end-pos nil (setq *org-drill-cram-mode* nil) (org-drill-free-markers *org-drill-done-entries*))))) (cond (end-pos (if (markerp end-pos) (progn (org-drill-goto-entry end-pos) (org-reveal) (org-show-entry))) (let ((keystr (command-keybinding-to-string (quote org-drill-resume)))) (message "You can continue the drill session with the command `org-drill-resume'.%s" (if keystr (format "\nYou can run this command by pressing %s." keystr) "")))) (t (org-drill-final-report) (if (eql (quote sm5) org-drill-spaced-repetition-algorithm) (org-drill-save-optimal-factor-matrix)) (if org-drill-save-buffers-after-drill-sessions-p (save-some-buffers)) (message "Drill session finished!"))))
      org-drill()
      call-interactively(org-drill record nil)
      command-execute(org-drill record)
      execute-extended-command(nil "org-drill")
      call-interactively(execute-extended-command nil nil)
      ergoemacs-read-key-call(execute-extended-command)
      ergoemacs-shortcut-remap(execute-extended-command)
      ergoemacs-read-key-lookup(nil nil [134217825] "【Alt+A】" nil)
      byte-code("\203\\\306\203j
    

    And this is my org-version output:

    Org-mode version 8.2.5h (8.2.5h-25-gc5d88f-elpaplus @ /home/shahin/.emacs.d/elpa/org-plus-contrib-20140224/
    

    As you said I tried to install org-mode using the latest availible tar ball. But after installing org-version says it is the version 7.9.3f and the mapcar error is still there!

  3. Paul Sexton repo owner

    Your problem is with the variable org-id-locations (part of the org-mode module org-id.el). This variable is supposed to be a list of lists, but in your case it has the symbol '... at the end of the list (see the line near the top beginning with mapcar in the backtrace you posted). I don't know how this variable has received this malformed value in your case, but I don't believe it has anything to do with org-drill. Search your emacs init file and customization file to see if you are inadvertently changing the value of this variable. If you don't find anything, I would ask for help on the main org-mode mailing list.

  4. Log in to comment