emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orgmode] Problem with archiving


From: Nick Dokos
Subject: Re: [Orgmode] Problem with archiving
Date: Mon, 02 Mar 2009 21:24:44 -0500

Ed Hirgelt <address@hidden> wrote:

> Using the latest from git:  when I try to archive a subtree with C-c 
> $, I get
> 
> org-archive-subtree: Wrong type argument: number-or-marker-p, nil
> 
> Archive is going to the default location, in my case Tasks.org_archive
> in the
> same directory.  This also failed with a newly created file.
> 

Here's a little more information on what goes wrong:

---- foo.org -----

* foo
** bar
** baz
------------------

C-c $ (on the * foo line) then gives:

Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil)
  org-get-valid-level(0 nil)
  org-archive-subtree(nil)
  call-interactively(org-archive-subtree nil nil)


the suspect line in org-archive.el being:

          ...
          ;; Paste
          (org-paste-subtree (org-get-valid-level level (and heading 1)))
          ...

heading was evaluated to "" and then set to nil, so (and heading 1) evaluates
to nil (it probably should evaluate to 0?), which is used in org-get-valid-level
as a number to be added to the level.

Should (and heading 1) become (if heading 1 0)?




reply via email to

[Prev in Thread] Current Thread [Next in Thread]