I attached a minimal document that causes the error. It has a ``#+TODO:'' line at the top which does not list ``TODO'' as a TODO state. Meanwhile, in other documents in directories listed in my org-agenda-files I have many TODO entries. When org-agenda tried to collect just my TODO headlines, it found one in a file with locally defined TODO words but without TODO. That caused the error. Is it possible to add additional TODO keywords to a local file without excluding the global keywords? Regards, Kyle -----Original Message----- From: Bastien Guerry [mailto:bastienguerry@gmail.com] On Behalf Of Bastien Sent: Friday, January 04, 2013 10:34 To: Andrews, Kyle (KC) Cc: nicholas.dokos@hp.com; emacs-orgmode@gnu.org Subject: Re: Bug: org-agenda-get-todos: Wrong type argument: integer-or-marker-p, nil [7.9.2 (7.9.2-181-ge8aaca-elpa @ c:/users/--------/documents/store/.emacs.d/elpa/org-20121231/)] Hi Andrews, "Andrews, Kyle (KC)" writes: > I followed Nick's advice and tried to isolate an offending headline in > my emacs.org. It turns out I can't have a headline called: I still can't reproduce the problem. Here is the recipe I used: 1. have a ~/test.org containing "* TODO REGEXP" 2. emacs -Q --find "~/test.org" 3. C-c [ 3. M-x org-agenda RET < t 1 r And no error. Can you reproduce the error with another file yourtest.org and share it with us? Thanks, -- Bastien