1

today I have to ask the community for some help. I used my org-agenda for a few years now. But since a few month my missed deadlines wont be shown in weekly agenda. Maybe I miss-configured something during continues cleanup but I dont find a bad configuration.

I already tried a clean only org-mode installed config but it also does not work, no warnings of missed deadlines :-(

Documentation for deadlines writes "In addition, the agenda for today will carry a warning about the approaching or missed deadline, starting org-deadline-warning-days before the due date, and continuing until the entry is marked DONE." So actually no magic.

My Emacs-Version: GNU Emacs 26.3

My Org-Version: 9.3.1

My org-mode config:

(use-package
  org

  :mode
  ("\\.org\\'" . org-mode)

  :commands
  (org-agenda
   org-capture-todo
   org-capture-todo-context
   org-capture-journal
   org-capture-calendar)

  :config
  (setq
   org-gtd-directory "~/.gtd/"
   ;; org-gtd-todos-file (expand-file-name "todos.org" org-gtd-directory)
   ;; org-gtd-journal-file (expand-file-name "journal.org" org-gtd-directory)
   org-gtd-todos-file (expand-file-name "gtd.org" org-gtd-directory)
   org-gtd-journal-file (expand-file-name "gtd.org" org-gtd-directory))

  (setq
   org-startup-indented t
   org-M-RET-may-split-line t
   org-default-notes-file org-gtd-todos-file
   org-outline-path-complete-in-steps nil
   org-refile-use-outline-path t
   org-blank-before-new-entry '((heading . nil) (plain-list-item . nil))
   org-agenda-files (list org-gtd-todos-file)
   org-todo-keywords '((sequence "TODO(t)" "STARTED(s)" "BLOCKED(b)" "|" "DONE(d)" "DELEGATED(g)" "CANCELED(c)"))
   org-tag-alist '(;; For exclusiv groups
                   ;; (:startgroup . nil)
                   ;; ("@work" . ?w) ("@home" . ?h)
                   ;; ("@tennisclub" . ?t)
                   ;; (:endgroup . nil)
                   ("GENERAL" . ?g) ("EMACS" . ?e))
   org-refile-targets '((org-agenda-files :maxlevel . 5)))

  (setq
   org-capture-templates
   '(("t" "Todo (without context)" entry (file+headline org-gtd-todos-file "Inbox")
      "* TODO %? %i %^g\n:PROPERTIES:\n:ADDED: %U\n:CONTEXT:\n:DEADLINE: %^t\n:END:")
     ("T" "Todo (with context)" entry (file+headline org-gtd-todos-file "Inbox")
      "* TODO %? %i %^g\n:PROPERTIES:\n:ADDED: %U\n:CONTEXT: %a\n:DEADLINE: %^t\n:END:")
     ("j" "Journal" entry (file+headline org-gtd-journal-file "Journal")
      "* %? %i %^g\n:PROPERTIES:\n:ADDED: %U\n:CONTEXT: %a\n:END:")
     ("c" "Calendar" entry (file+headline org-gtd-todos-file "Calendar")
      "* TODO %? %i %^g\n:PROPERTIES:\n:ADDED: %U\n:CONTEXT: %a\n:SCHEDULED: %^T\n:DEADLINE: %^t\n:END:")))

  (defun org-capture-todo ()
    (interactive)
    (org-capture nil "t"))

  (defun org-capture-todo-context ()
    (interactive)
    (org-capture nil "T"))

  (defun org-capture-journal ()
    (interactive)
    (org-capture nil "j"))

  (defun org-capture-calendar ()
    (interactive)
    (org-capture nil "c"))

  :bind*
  (("C-M-- <RET>" . org-capture)
   ("C-M-- t" . org-capture-todo)
   ("C-M-- T" . org-capture-todo-context)
   ("C-M-- j" . org-capture-journal)
   ("C-M-- c" . org-capture-calendar)
   ("C-M-- a" . org-agenda)))

My example org-file:

* TODO TEST A                                                       :GENERAL:
:PROPERTIES:
:ADDED: [2020-01-05 Sun 16:47]
:DEADLINE: <2020-01-08 Wed>
:END:
* TODO TEST B                                                       :GENERAL:
:PROPERTIES:
:ADDED: [2020-01-05 Sun 16:47]
:DEADLINE: <2020-01-16 Thu>
:END:

My agenda output:

Week-agenda (W03):
Monday     13 January 2020 W03
Tuesday    14 January 2020
Wednesday  15 January 2020
Thursday   16 January 2020
  gtd:        TODO TEST B                                                               :GENERAL:
Friday     17 January 2020
Saturday   18 January 2020
Sunday     19 January 2020

Expectation: TEST A schould be shown as missed deadlined task.

Any ideas what I missed, hopefully someone can help me, thx.

5
  • The way to find out if you have a misconfiguration is to invoke emacs with the -q option, thereby skipping your init file (that should be enough if you use the Org mode that is built-in to your emacs, although you may have to do a bit more initialization if you install your own). Have you tried that? If that works, then your init file is to blame: bisect it to find out where things go wrong. If it does not, then provide a complete recipe of how to reproduce the failure, starting from emacs -q.
    – NickD
    Jan 14, 2020 at 14:03
  • I already tried a clean config, see written above "I already tried a clean only org-mode installed config but it also does not work, no warnings of missed deadlines :-(" Do you can try yourself, please? I added emacs version. Jan 14, 2020 at 14:31
  • It wasn't clear to me what you meant by a "clean only org-mode installed config". If that means emacs -q, then the second part of my comment applies: provide a complete recipe of how to reproduce the problem, including an Org mode file.
    – NickD
    Jan 14, 2020 at 15:49
  • Thx, I added an example with output and expectation. Jan 14, 2020 at 16:11
  • As you can see, if you had provided the Org mode file in the first place, we could have avoided all the back-and-forth.
    – NickD
    Jan 14, 2020 at 16:57

1 Answer 1

3
+50

You are setting your deadline incorrectly. The normal way of setting a deadline is as follows:

* MY-TEST :GENERAL:
DEADLINE: <2020-01-13 Mon>

Your entry should thus look like this:

* TODO TEST :GENERAL:
DEADLINE: <2020-01-13 Fri>
:PROPERTIES:
:ADDED: [2020-01-14 Tue 16:47]
:END:

DEADLINE is not an ordinary org property.

5
  • It seems to me that your solution works, but actually deadline is a org property! Furthermore it works for the active week, so the deadline is interpreted. Maybe someone else has any idea, otherwise I has to change my template shift the deadline out of properties. Jan 14, 2020 at 16:46
  • 3
    DEADLINE is a special property and as such should not be used as a key in the properties drawer. See Org Mode Manual 7.2
    – Edman
    Jan 14, 2020 at 16:52
  • 2
    It is not a property in the sense that it cannot appear in a properties drawer (it is a "special property" in the sense that you can search for it using the methods described in the Matching tags and properties section of the manual. Mistakes like this can often be found by executing M-x org-lint in the Org mode buffer. In this case, that issues a warning: ` 4 high Special property "DEADLINE" found in a properties drawer`.
    – NickD
    Jan 14, 2020 at 16:54
  • Damm, you are right! I could swear it wasn't like that in earlier versions Jan 14, 2020 at 17:05
  • 1
    It has always been like that. What was different in earlier versions was that you could have scheduling information after a PROPERTIES drawer. The syntax has been tightened however: first a headline, then scheduling information, then properties drawer and no empty lines separating them. That caused serious incompatibilities with pre-existing Org mode files that did not follow the new syntax, so org-lint was introduced at about the same time to flag these.
    – NickD
    Jan 14, 2020 at 20:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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