From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sacha Chua Subject: [PATCH] Re: Bug: `org-agenda-prepare-buffers' fails at (org-refresh-properties "APPT_WARNTIME" 'org-appt-warntime) [8.2.5h (8.2.5h-82-gd91d4b-elpaplus @ /home/wgg/.emacs.d/elpa/org-plus-contrib-20140324/)] Date: Sat, 05 Apr 2014 14:28:09 -0400 Message-ID: <86fvlrfx6u.fsf@sachachua.com> References: <871txmsz92.fsf@motoko.kusanagi> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:58618) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WWVKH-0007EL-Tc for emacs-orgmode@gnu.org; Sat, 05 Apr 2014 14:28:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WWVK9-0005nO-Fl for emacs-orgmode@gnu.org; Sat, 05 Apr 2014 14:28:21 -0400 Received: from plane.gmane.org ([80.91.229.3]:37263) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WWVK9-0005n7-9F for emacs-orgmode@gnu.org; Sat, 05 Apr 2014 14:28:13 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1WWVK8-0004uJ-9g for emacs-orgmode@gnu.org; Sat, 05 Apr 2014 20:28:12 +0200 Received: from 69-196-133-182.dsl.teksavvy.com ([69.196.133.182]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 05 Apr 2014 20:28:12 +0200 Received: from sacha by 69-196-133-182.dsl.teksavvy.com with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 05 Apr 2014 20:28:12 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org wgg2@member.fsf.org writes: > On the latest `org-plus-contrib' build from the org package.el repo, my > Agenda buffers (for any Agenda command) fail to render properly, with > these pertinent lines from *Backtrace*: > Debugger entered--Lisp error: (wrong-type-argument integer-or-marker-p nil) > put-text-property(28484 nil org-appt-warntime "60") ... > I then isolated this to the following lines of function > `org-agenda-prepare-buffers': > (or (memq 'appt org-agenda-ignore-drawer-properties) > (org-refresh-properties "APPT_WARNTIME" 'org-appt-warntime)) I ran into a similar problem with org-agenda-prepare-buffers and the EFFORT property. This change to org-refresh-properties seems to fix it: diff --git a/lisp/org.el b/lisp/org.el index f8615a2..bd9c05e 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -9393,7 +9393,7 @@ property to set." (save-excursion (org-back-to-heading t) (put-text-property - (point-at-bol) (outline-next-heading) tprop p)))))))) + (point-at-bol) (or (outline-next-heading) (point-max)) tprop p)))))))) ;;;; Link Stuff The previous version by Bastien used (org-end-of-subtree t t), which had checked for (eobp) in it, but outline-next-heading returns nil if there are no further headings. Sacha Chua