emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-mode 3.5.1 @ emacs 24: invalid-functon 41
@ 2015-08-18  6:41 Martin Steffen
  2015-08-18 16:08 ` Bastien
  0 siblings, 1 reply; 6+ messages in thread
From: Martin Steffen @ 2015-08-18  6:41 UTC (permalink / raw)
  To: emacs-orgmode

Hi,

I have recently git-pulled the latest org-mode (and make-compiled it).
Since the upgrade, org is basically broken. If I visit a file, emacs answers
with invalid-function 41 (I have debug-on-error to "t", but it does not give
much info where it chokes).

I have now org-version 3.5.1. Before the upgrade, it was, I assume some
3.5.0 (maybe 3.5.0h, and that worked). 

emacs-version: 24.5.2


If I use emacs 23.1, the problem goes away.

To avoid interference with too many loaded packages (including org-features).
I started emacs with

   emacs --no-init-file

and eval'ed just the following 3 lines


(setq load-path (cons "~/gnu/emacs/24/lisp/org/lisp" load-path))
(setq load-path (cons "~/gnu/emacs/24/lisp/org/contrib/lisp" load-path))
(add-to-list 'auto-mode-alist '("\\.org\\'" . org-mode))


Here's some other errors in the *Messages* buffer:




Problems while trying to load feature `org-bbdb'
Problems while trying to load feature `org-bibtex'
Problems while trying to load feature `org-docview'
Problems while trying to load feature `org-gnus'
Problems while trying to load feature `org-info'
Problems while trying to load feature `org-irc'
Problems while trying to load feature `org-mhe'
Problems while trying to load feature `org-rmail'
File mode specification error: (invalid-function 41)

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: org-mode 3.5.1 @ emacs 24: invalid-functon 41
  2015-08-18  6:41 org-mode 3.5.1 @ emacs 24: invalid-functon 41 Martin Steffen
@ 2015-08-18 16:08 ` Bastien
  2015-08-18 19:39   ` org-mode 3.5.1 <at> " Martin Steffen
  0 siblings, 1 reply; 6+ messages in thread
From: Bastien @ 2015-08-18 16:08 UTC (permalink / raw)
  To: Martin Steffen; +Cc: emacs-orgmode

Hi Martin,

Martin Steffen <msteffen@ifi.uio.no> writes:

> (setq load-path (cons "~/gnu/emacs/24/lisp/org/lisp" load-path))
> (setq load-path (cons "~/gnu/emacs/24/lisp/org/contrib/lisp" load-path))
> (add-to-list 'auto-mode-alist '("\\.org\\'" . org-mode))

After you start Emacs in this minimal mode, can you call

M-x org-reload RET
M-x org-version RET

and report the value?

Also, grep'ing through your ~/gnu/emacs/ folder to find "41" somewhere
might help.

-- 
 Bastien

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: org-mode 3.5.1  <at>  emacs 24: invalid-functon 41
  2015-08-18 16:08 ` Bastien
@ 2015-08-18 19:39   ` Martin Steffen
  2015-08-28 21:03     ` Nicolas Goaziou
  0 siblings, 1 reply; 6+ messages in thread
From: Martin Steffen @ 2015-08-18 19:39 UTC (permalink / raw)
  To: emacs-orgmode

Bastien <bzg <at> gnu.org> writes:

> 
> Hi Martin,
> 
> Martin Steffen <msteffen <at> ifi.uio.no> writes:
> 
> > (setq load-path (cons "~/gnu/emacs/24/lisp/org/lisp" load-path))
> > (setq load-path (cons "~/gnu/emacs/24/lisp/org/contrib/lisp" load-path))
> > (add-to-list 'auto-mode-alist '("\\.org\\'" . org-mode))
> 
> After you start Emacs in this minimal mode, can you call
> 
> M-x org-reload RET
> M-x org-version RET
> 
> and report the value?
> 
> Also, grep'ing through your ~/gnu/emacs/ folder to find "41" somewhere
> might help.
> 



thanks for the feedback. What I did in the meantime: I checked out an older
version (I git-checked out a tag  "release_8.3") which made the troubles go
away. 


Now, to re-produce the error: I went back to the last revision which 
showed for me the error and started the minimal emacs (--no-init-file) again.

After starting emacs in the above mentioned  minimal mode (as you proposed),
I called M-x org-reload. That gives the output (1) below.

Org-version gives:


Org-mode version 8.3.1 (release_8.3.1-117-gc98729 @
/ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/)




The grep'ing of the directory does not reveal much. There's some occurences
of "41" in some time stamps or in hex-codes, but not much that seems to
relate to a "function 41". Note also: since I invoke emacs with
"no-init-file" and since my personally extended directories are not entered
to the load-path (apart from the org-subdir), none of the stuff I normally
load from there should play a role in the problem.

In general, I had the impression it's a rather fundamental bug: I disallows
me to type "RETURN" in an org file. More precisely, I cannot type
"RETURN" in "org-mode". If I do, I get the error message

            invalid function 41

and the return is not executed (insofar that no new line is added but an
error raised). Due to 
that, org-mode for me in that version is ``broken'' as a cannot enter a new
line at all (except I can "cut-and-paste" a new line  or similar) which is
why I checked-out the previous tag.

.
Martin


-------------------------- (1) ---------------------------

Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-comint...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-core...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-emacs-lisp...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-eval...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-exp...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-keys...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-lob...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-ref...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-table...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/ob-tangle...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-compat...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-entities...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-faces...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-footnote...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-list...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-macro...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-macs...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-pcomplete...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-src...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-w3m...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org-version.el
(source)...done
Loading /ifi/asgard/a01/msteffen/gnu/emacs/24/lisp/org/lisp/org.el (source)...
Problems while trying to load feature `org-bbdb'
Problems while trying to load feature `org-bibtex'
Problems while trying to load feature `org-docview'
Problems while trying to load feature `org-gnus'
Problems while trying to load feature `org-info'
Problems while trying to load feature `org-irc'
Problems while trying to load feature `org-mhe'
Problems while trying to load feature `org-rmail'
org-element--set-regexps: Invalid function: 41
Quit
Mark set

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: org-mode 3.5.1  <at>  emacs 24: invalid-functon 41
  2015-08-18 19:39   ` org-mode 3.5.1 <at> " Martin Steffen
@ 2015-08-28 21:03     ` Nicolas Goaziou
  2015-08-29 11:09       ` Martin Steffen
  0 siblings, 1 reply; 6+ messages in thread
From: Nicolas Goaziou @ 2015-08-28 21:03 UTC (permalink / raw)
  To: Martin Steffen; +Cc: emacs-orgmode

Hello,

Martin Steffen <msteffen@ifi.uio.no> writes:

> org-element--set-regexps: Invalid function: 41

41 is ?\) character. I think the problem lies in this snippet from
`org-element--set-regexps'

  (case org-plain-list-ordered-item-terminator
    (?\) ")") (?. "\\.") (otherwise "[.)]"))
     ^^^

Could you try the following patch?

diff --git a/lisp/org-element.el b/lisp/org-element.el
index 8f41ab2..7b95e0d 100644
--- a/lisp/org-element.el
+++ b/lisp/org-element.el
@@ -177,8 +177,11 @@ specially in `org-element--object-lex'.")
 		;; Clock lines.
 		(regexp-quote org-clock-string) "\\|"
 		;; Lists.
-		(let ((term (case org-plain-list-ordered-item-terminator
-			      (?\) ")") (?. "\\.") (otherwise "[.)]")))
+		(let ((term (if (characterp
+				 org-plain-list-ordered-item-terminator)
+				(char-to-string
+				 org-plain-list-ordered-item-terminator)
+			      "[.)]"))
 		      (alpha (and org-list-allow-alphabetical "\\|[A-Za-z]")))
 		  (concat "\\(?:[-+*]\\|\\(?:[0-9]+" alpha "\\)" term "\\)"
 			  "\\(?:[ \t]\\|$\\)"))


Regards,

-- 
Nicolas Goaziou

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: org-mode 3.5.1  <at>  emacs 24: invalid-functon 41
  2015-08-28 21:03     ` Nicolas Goaziou
@ 2015-08-29 11:09       ` Martin Steffen
  2015-09-02  5:54         ` Martin Steffen
  0 siblings, 1 reply; 6+ messages in thread
From: Martin Steffen @ 2015-08-29 11:09 UTC (permalink / raw)
  To: emacs-orgmode



Hi,

thanks for the info. I tried to reproduce the error but failed, which
means, in the meantime org 3.5.1  works. 

Note, however, that it's no longer the same git-reversion. When I first
stumbled upon it, it was org-version 3.5.1 and the then latest pull from
the git-server. Since it basically made all of org unsusable ("RETURN"
did not work any longer), I decided to ``go back in time'' and
git-pulled an earlier version (namely the one git-labeled "release
3.5").

Now, in order to reproduce the error (and try the patch), I pulled the
now latest one, and the ``41-error'' does _not_ show up. I also applied
to small patch (because the 2 lines you pointed at do appear in the
org-element.el file), but that does not lead to an immediately visible
change (but as said, the error was gone already).

Unfortunately, I don't know which exact revision it was that showed that
problem ---I think in the meantime I did not also update emacs
itself---, but if it disappeared in the now latest version, I am content
as well.


Thanks, Martin


    Nicolas> Hello,

    Nicolas> Martin Steffen <msteffen@ifi.uio.no> writes:

    >> org-element--set-regexps: Invalid function: 41

    Nicolas> 41 is ?\) character. I think the problem lies in this
    Nicolas> snippet from `org-element--set-regexps'

    Nicolas>   (case org-plain-list-ordered-item-terminator (?\) ")")
    Nicolas> (?. "\\.") (otherwise "[.)]"))  ^^^




    Nicolas> Could you try the following patch?

    Nicolas> diff --git a/lisp/org-element.el b/lisp/org-element.el
    Nicolas> index 8f41ab2..7b95e0d 100644 --- a/lisp/org-element.el +++
    Nicolas> b/lisp/org-element.el @@ -177,8 +177,11 @@ specially in
    Nicolas> `org-element--object-lex'.")  ;; Clock lines.
    Nicolas> (regexp-quote org-clock-string) "\\|" ;; Lists.  - (let
    Nicolas> ((term (case org-plain-list-ordered-item-terminator - (?\)
    Nicolas> ")") (?. "\\.") (otherwise "[.)]")))  + (let ((term (if
    Nicolas> (characterp + org-plain-list-ordered-item-terminator) +
    Nicolas> (char-to-string + org-plain-list-ordered-item-terminator) +
    Nicolas> "[.)]"))  (alpha (and org-list-allow-alphabetical
    Nicolas> "\\|[A-Za-z]"))) (concat "\\(?:[-+*]\\|\\(?:[0-9]+" alpha
    Nicolas> "\\)" term "\\)" "\\(?:[ \t]\\|$\\)"))


    Nicolas> Regards,

    Nicolas> -- Nicolas Goaziou

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: org-mode 3.5.1  <at>  emacs 24: invalid-functon 41
  2015-08-29 11:09       ` Martin Steffen
@ 2015-09-02  5:54         ` Martin Steffen
  0 siblings, 0 replies; 6+ messages in thread
From: Martin Steffen @ 2015-09-02  5:54 UTC (permalink / raw)
  To: emacs-orgmode





Hi Nicolas, and all.

I recently answered to a prior suggestion concerning the cause of a
problem (see below), basically I could not confirm the cause of the
error. In the meantime, I had the same problem (on different computer),
again with the newest org-mode with the same symptoms (org-mode
basically broken, with constant ``invalid function 41'' message).


I applied the suggested patch, and it made the symptoms go away. So it
seems that it cause of the error was located.

Thanks, Martin


>>>>> "Martin" == Martin Steffen <msteffen@ifi.uio.no> writes:

    Martin> Hi,

    Martin> thanks for the info. I tried to reproduce the error but
    Martin> failed, which means, in the meantime org 3.5.1 works.

    Martin> Note, however, that it's no longer the same
    Martin> git-reversion. When I first stumbled upon it, it was
    Martin> org-version 3.5.1 and the then latest pull from the
    Martin> git-server. Since it basically made all of org unsusable
    Martin> ("RETURN" did not work any longer), I decided to ``go back
    Martin> in time'' and git-pulled an earlier version (namely the one
    Martin> git-labeled "release 3.5").

    Martin> Now, in order to reproduce the error (and try the patch), I
    Martin> pulled the now latest one, and the ``41-error'' does _not_
    Martin> show up. I also applied to small patch (because the 2 lines
    Martin> you pointed at do appear in the org-element.el file), but
    Martin> that does not lead to an immediately visible change (but as
    Martin> said, the error was gone already).

    Martin> Unfortunately, I don't know which exact revision it was that
    Martin> showed that problem ---I think in the meantime I did not
    Martin> also update emacs itself---, but if it disappeared in the
    Martin> now latest version, I am content as well.


    Martin> Thanks, Martin


    Nicolas> Hello,

    Nicolas> Martin Steffen <msteffen@ifi.uio.no> writes:

    >>> org-element--set-regexps: Invalid function: 41

    Nicolas> 41 is ?\) character. I think the problem lies in this
    Nicolas> snippet from `org-element--set-regexps'

    Nicolas> (case org-plain-list-ordered-item-terminator (?\) ")")
    Nicolas> (?. "\\.") (otherwise "[.)]"))  ^^^




    Nicolas> Could you try the following patch?

    Nicolas> diff --git a/lisp/org-element.el b/lisp/org-element.el
    Nicolas> index 8f41ab2..7b95e0d 100644 --- a/lisp/org-element.el +++
    Nicolas> b/lisp/org-element.el @@ -177,8 +177,11 @@ specially in
    Nicolas> `org-element--object-lex'.")  ;; Clock lines.
    Nicolas> (regexp-quote org-clock-string) "\\|" ;; Lists.  - (let
    Nicolas> ((term (case org-plain-list-ordered-item-terminator - (?\)
    Nicolas> ")") (?. "\\.") (otherwise "[.)]")))  + (let ((term (if
    Nicolas> (characterp + org-plain-list-ordered-item-terminator) +
    Nicolas> (char-to-string + org-plain-list-ordered-item-terminator) +
    Nicolas> "[.)]"))  (alpha (and org-list-allow-alphabetical
    Nicolas> "\\|[A-Za-z]"))) (concat "\\(?:[-+*]\\|\\(?:[0-9]+" alpha
    Nicolas> "\\)" term "\\)" "\\(?:[ \t]\\|$\\)"))


    Nicolas> Regards,

    Nicolas> -- Nicolas Goaziou

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2015-09-02  5:55 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-18  6:41 org-mode 3.5.1 @ emacs 24: invalid-functon 41 Martin Steffen
2015-08-18 16:08 ` Bastien
2015-08-18 19:39   ` org-mode 3.5.1 <at> " Martin Steffen
2015-08-28 21:03     ` Nicolas Goaziou
2015-08-29 11:09       ` Martin Steffen
2015-09-02  5:54         ` Martin Steffen

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).