From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jonathan Johnson Subject: Bug: Passing nil argument in org-refresh-properties [8.2.5h (8.2.5h-98-g0820d0-elpa @ /home/jjohnson/.emacs.d/elpa/org-20140407/)] Date: Mon, 07 Apr 2014 13:06:27 -0500 Message-ID: <1396893987.3067.5.camel@aristeros.symphero.mn.org> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:60435) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WXDwQ-0007A9-I1 for emacs-orgmode@gnu.org; Mon, 07 Apr 2014 14:06:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WXDwL-0003uQ-AL for emacs-orgmode@gnu.org; Mon, 07 Apr 2014 14:06:42 -0400 Received: from symphero.mn.org ([63.228.3.77]:44004 helo=aristeros.symphero.mn.org) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WXDwK-0003uB-SF for emacs-orgmode@gnu.org; Mon, 07 Apr 2014 14:06:37 -0400 Received: from [10.0.0.3] (symphero.mn.org [10.0.0.3]) by aristeros.symphero.mn.org (8.14.2/8.14.2) with ESMTP id s37I6Rae008173 for ; Mon, 7 Apr 2014 13:06:27 -0500 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 Org Mode community, I updated to the latest ELPA release today and got an error loading an agenda with 'C-c a a'. The problem can be reproduced by including a properly-formatted Org file in the agenda list. To present that formatting, that Org file should end with an outline heading that has an effort property set in its properties. The problem stems from the last line of org-refresh-properties (line 9298), in which (point-at-eol) was replaced with (outline-next-heading). This is not an emacs versioning issue; in the 24.3 emacs release, as in my version (a recent Cygwin version of Emacs), the outline-next-heading function returns nil when there is no next heading after the point. I worked around the problem by adding a dummy heading at the end of the offending Org file, but a fix would be to add some conditional construct that validates the return value from outline-next-heading to avoid passing nil to put-text-property, or revert the code to using (point-at-eol). Not knowing more about the history of the code, and as an amateur lisp hacker, I probably shouldn't make recommendations...but...how would the following work: ... (put-text-property (point-at-bol) (or (outline-next-heading) (point-max)) tprop p)... It works for me, anyway. My info: Emacs : GNU Emacs 24.3.1 (i686-pc-cygwin, GTK+ Version 3.8.2) of 2013-08-14 on moufang Package: Org-mode version 8.2.5h (8.2.5h-98-g0820d0-elpa @ /home/jjohnson/.emacs.d/elpa/org-20140407/) current state: ============== (setq org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point org-babel-execute-safely-maybe) org-agenda-todo-ignore-scheduled 'future org-clock-persist 'history org-tab-first-hook '(org-hide-block-toggle-maybe org-src-native-tab-command-maybe org-babel-hide-result-toggle-maybe org-babel-header-arg-expand) org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers org-cycle-hide-inline-tasks org-cycle-show-empty-lines org-optimize-window-after-visibility-change) org-agenda-before-write-hook '(org-agenda-add-entry-text) org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook) org-blocker-hook '(org-block-todo-from-children-or-siblings-or-parent) org-babel-pre-tangle-hook '(save-buffer) org-occur-hook '(org-first-headline-recenter) org-clock-history-length 10 org-log-done 'time org-metaup-hook '(org-babel-load-in-session-maybe) org-confirm-elisp-link-function 'yes-or-no-p org-agenda-todo-ignore-deadlines 14 org-agenda-dim-blocked-tasks 'invisible org-clock-out-hook '(org-clock-remove-empty-clock-drawer) org-agenda-include-diary t org-enforce-todo-dependencies t org-mode-hook '(org-clock-load #[nil "\300\301\302\303\304 $\207" [org-add-hook change-major-mode-hook org-show-block-all append local] 5] #[nil "\300\301\302\303\304$\207" [org-add-hook change-major-mode-hook org-babel-show-result-all append local] 5] org-babel-result-hide-spec org-babel-hide-all-hashes) org-clock-idle-time 6 org-metadown-hook '(org-babel-pop-to-session-maybe) org-agenda-files "/cygdrive/i/org/.agenda_files" org-clock-report-include-clocking-task t org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer) org-after-todo-state-change-hook '(org-clock-out-if-current) org-after-todo-statistics-hook '(org-summary-todo) org-confirm-shell-link-function 'yes-or-no-p ) Regards, -- Jonathan Johnson