jceb / vim-orgmode

Text outlining and task management for Vim based on Emacs' Org-Mode
http://www.vim.org/scripts/script.php?script_id=3642
Other
3.1k stars 266 forks source link

Agenda error #259

Open rgc69 opened 7 years ago

rgc69 commented 7 years ago

Hi Jan, the weekly/daily agenda command caa return this error:

Traceback (most recent call last): File "", line 1, in File "~/.vim/ftplugin/orgmode/plugins/Agenda.py", line 152, in list_next_week last_date = raw_agenda[0].active_date IndexError: list index out of range

The global TODO list command cat it's ok. Any idea? Thank you!

EDIT: Got it! When I insert the date with sa it's allright. The problem arise with pa (don't know why)

jceb commented 7 years ago

Hi, thanks for reporting the issue. Would you investigate the issue a little more and provide a pull request?

JaniM commented 3 years ago

Reproduced with an org file that has a single timestamped item

* Foo <2020-09-01 Tue>

Having headers before this does not affect the error. Having a non-timestamped entry after it gets rid of it.

Edit: Hmm actually this seems to have more to do with some org files not being opened in buffers. I get no errors if all org files are open.