emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <nicholas.dokos@hp.com>
To: Stelian Iancu <stelian.iancu@gmail.com>
Cc: nicholas.dokos@hp.com, emacs-orgmode@gnu.org
Subject: Re: Bug: wrong-type-argument when changing TODO state [7.7]
Date: Mon, 29 Aug 2011 03:59:06 -0400	[thread overview]
Message-ID: <23342.1314604746@alphaville.dokosmarshall.org> (raw)
In-Reply-To: Message from Stelian Iancu <stelian.iancu@gmail.com> of "Mon\, 29 Aug 2011 09\:41\:29 +0200." <CAKvLAoh3ufj_kGvCHHGFQUVabp3EfjqKt+q=wWGekX3EsuB1Wg@mail.gmail.com>

Stelian Iancu <stelian.iancu@gmail.com> wrote:

> On Sun, Aug 28, 2011 at 19:09, Nick Dokos <nicholas.dokos@hp.com> wrote:
> > Stelian Iancu <stelian.iancu@gmail.com> wrote:
> >
> >>
> >> I am trying to switch between TODO and DONE states with Shift-Right
> >> Arrow and I get a (wrong-type-argument stringp nil) error.
> >>
> >> Please find attached the backtrace.
> >>
> >>
> >> Emacs  : GNU Emacs 23.2.1 (i486-pc-linux-gnu, GTK+ Version 2.20.0)
> >>  of 2010-12-11 on raven, modified by Debian
> >> Package: Org-mode version 7.7
> >>
> >
> >> Debugger entered--Lisp error: (wrong-type-argument stringp nil)
> >>   looking-at(nil)
> >>   (save-excursion (beginning-of-line 1) (looking-at org-todo-line-regexp))
> >>   (and (outline-on-heading-p) (not (bolp)) (save-excursion (beginning-of-line 1) (looking-at org-todo-line-regexp)) (< (point) (+ 2 ...)))
> >>   (if (and (outline-on-heading-p) (not ...) (save-excursion ... ...) (< ... ...)) (progn (goto-char ...) (and ... ...)))
> >>   (let* ...)
> >>   (catch (quote exit) ...)
> >>   (save-excursion (catch (quote exit)...)
> >>   (let ...)
> >>   org-todo(right)
> >>   call-interactively(org-todo)
> >>   (let ((current-prefix-arg arg)) (call-interactively command))
> >>   org-call-with-arg(org-todo right)
> >>   (let ...)
> >>   (cond ...)
> >>   org-shiftright(nil)
> >>   call-interactively(org-shiftright nil nil)
> >
> > The problem is that org-todo-line-regexp is nil. This variable is
> > made buffer-local and initialized when the buffer's mode is set
> > to org-mode.
> >
> > Are you sure that your buffer's major mode is org-mode?
> >
> > Nick
> >
> 
> Yeah, the mode shows as org-mode.

What happens if while visiting the buffer, you say

C-h v org-todo-line-regexp RET

Is the value reported nil? 

> But now I get another weird one.
> Everytime I open an org file, I see the following message in the
> minibuffer:
> 
> File mode specification error: (wrong-type-argument keymap nil)
> 

That will require another backtrace but...

> I'm lost ...

When you get to the point of feeling lost, it's time to take a step
back. Make yourself a minimal.emacs that contains just the basics to
get org-mode loaded - assuming you get your org sources from git, then
you need something like this (with pathnames changed appropriately):

--8<---------------cut here---------------start------------->8---
;;; -*- mode: emacs-lisp -*-
;;; constant part
(add-to-list 'load-path (expand-file-name "~/src/emacs/org/org-mode/lisp"))
(add-to-list 'auto-mode-alist '("\\.\\(org\\|org_archive\\|txt\\)$" . org-mode))
(require 'org-install)
(global-set-key "\C-cl" 'org-store-link)
(global-set-key "\C-ca" 'org-agenda)
--8<---------------cut here---------------end--------------->8---

Then start up an emacs without any of your customizations, load the minimal.emacs
file and visit an org file and try what you tried before:

   emacs -q -l /path/to/minimal.emacs /path/to/somefile.org

and try changing a TODO as before.  Does that work? If not, try -Q
instead of -q: does *that* work?

Assuming one of these works, then you have localized the problem to
some customization (yours or the systems) and then there are various
ways to proceed.

Nick

> 
> S.
> 

  reply	other threads:[~2011-08-29  7:59 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-28 11:24 Bug: wrong-type-argument when changing TODO state [7.7] Stelian Iancu
2011-08-28 17:09 ` Nick Dokos
2011-08-29  7:41   ` Stelian Iancu
2011-08-29  7:59     ` Nick Dokos [this message]
2011-08-29 13:32       ` Stelian Iancu
2011-08-29 21:42       ` Stelian Iancu
2011-08-29 21:59         ` Stelian Iancu
2011-08-29 22:37           ` Nick Dokos
2011-08-29 23:02             ` Nick Dokos
2011-08-30 17:21               ` Nick Dokos
2011-08-31 11:03                 ` Stelian Iancu
2011-08-30  7:47             ` Stelian Iancu
2011-08-29 22:25         ` Nick Dokos
     [not found]   ` <stelian.iancu@gmail.com>
2011-11-24  8:03     ` Org from ELPA question Stelian Iancu
2011-11-24  8:17       ` Nick Dokos
2011-11-24  8:38         ` Stelian Iancu
2011-11-24 12:23           ` Jambunathan K
2011-11-24 12:55             ` Stelian Iancu
2011-11-24 20:44             ` Achim Gratz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=23342.1314604746@alphaville.dokosmarshall.org \
    --to=nicholas.dokos@hp.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=stelian.iancu@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).