emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Cannot convert to Odt
@ 2013-07-10 17:55 Tim Hawes
  2013-07-10 18:11 ` Jambunathan K
  2013-07-10 18:38 ` Eric S Fraga
  0 siblings, 2 replies; 7+ messages in thread
From: Tim Hawes @ 2013-07-10 17:55 UTC (permalink / raw)
  To: emacs-orgmode Mode

I am running Emacs 24.2 (installed from a bootstrapped pkgsrc) on Ubuntu
Linux 12.04

When I try to convert my org doc to odt format, it fails. I have tried
two different versions of org-mode. Version 7.8.11 that comes with Emacs
24.2 and the latest from GNU Emacs Elpa 8.0.5

This is the *Messages* buffer from org-version 7.8.11:
http://pastebin.com/pFv8xZEk

and from 8.0.5:
http://pastebin.com/cYGRi2qM

I have tried both from completely stripped .emacs files, and getting the
same errors. I have an Ubuntu laptop at home with the same setup and no
issues in converting org docs to odt.

I caught the "No OpenOffice schema files are installed" message, and
could not find these schema files in the git repository, nor were they
installed from Elpa. Any ideas?

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

* Re: Cannot convert to Odt
  2013-07-10 17:55 Cannot convert to Odt Tim Hawes
@ 2013-07-10 18:11 ` Jambunathan K
  2013-07-10 21:54   ` Tim Hawes
  2013-07-10 18:38 ` Eric S Fraga
  1 sibling, 1 reply; 7+ messages in thread
From: Jambunathan K @ 2013-07-10 18:11 UTC (permalink / raw)
  To: Tim Hawes; +Cc: emacs-orgmode Mode

Tim Hawes <hawest@anx.com> writes:

> I am running Emacs 24.2 (installed from a bootstrapped pkgsrc) on Ubuntu
> Linux 12.04
>
> When I try to convert my org doc to odt format, it fails. I have tried
> two different versions of org-mode. Version 7.8.11 that comes with Emacs
> 24.2 and the latest from GNU Emacs Elpa 8.0.5
>
> This is the *Messages* buffer from org-version 7.8.11:
> http://pastebin.com/pFv8xZEk
>
> and from 8.0.5:
> http://pastebin.com/cYGRi2qM
>
> I have tried both from completely stripped .emacs files, and getting the
> same errors. I have an Ubuntu laptop at home with the same setup and no
> issues in converting org docs to odt.

Both the 7.8 and 8.0 exporter has the following messages.


sh-syntax-propertize-function: Beginning of buffer

bash                                                                               
OpenDocument export failed: Beginning of buffer                                                                     
(New file)


It may have something to do with what you have in your Org file.  Try
"minimizing" your Org file one by one until you find where the problem
is.


> I caught the "No OpenOffice schema files are installed" message, and
> could not find these schema files in the git repository, nor were they
> installed from Elpa. Any ideas?

Schema files are important only if you were to debug the XML emitted by
the exporter.  See Info manual for more information.

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

* Re: Cannot convert to Odt
  2013-07-10 17:55 Cannot convert to Odt Tim Hawes
  2013-07-10 18:11 ` Jambunathan K
@ 2013-07-10 18:38 ` Eric S Fraga
  1 sibling, 0 replies; 7+ messages in thread
From: Eric S Fraga @ 2013-07-10 18:38 UTC (permalink / raw)
  To: Tim Hawes; +Cc: emacs-orgmode Mode

Tim Hawes <hawest@anx.com> writes:

> I am running Emacs 24.2 (installed from a bootstrapped pkgsrc) on Ubuntu
> Linux 12.04
>
> When I try to convert my org doc to odt format, it fails. I have tried
> two different versions of org-mode. Version 7.8.11 that comes with Emacs
> 24.2 and the latest from GNU Emacs Elpa 8.0.5
>
> This is the *Messages* buffer from org-version 7.8.11:
> http://pastebin.com/pFv8xZEk
>
> and from 8.0.5:
> http://pastebin.com/cYGRi2qM
>
> I have tried both from completely stripped .emacs files, and getting the
> same errors. I have an Ubuntu laptop at home with the same setup and no
> issues in converting org docs to odt.

First, try with "emacs -Q".
Second, can you post a minimal example org file that has this problem?
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 24.3.50.1, Org release_8.0.5-326-g325e40

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

* Re: Cannot convert to Odt
  2013-07-10 18:11 ` Jambunathan K
@ 2013-07-10 21:54   ` Tim Hawes
  2013-07-11  2:32     ` Jambunathan K
  0 siblings, 1 reply; 7+ messages in thread
From: Tim Hawes @ 2013-07-10 21:54 UTC (permalink / raw)
  To: Jambunathan K; +Cc: emacs-orgmode Mode


Jambunathan K writes:

I am able to convert the same file on my home laptop with org-version
7.8.11

Nonetheless, I tried it with this minimal file:
#+STARTUP: showeverything

* Heading 1

  1. Item 1

starting emacs with emacs -Q I am getting this error:
("emacs")
Loading term/xterm...done
For information about GNU Emacs and the GNU system, type C-h C-a.
kmacro-call-macro: No kbd macro has been defined
Making completion list... [2 times]
Export buffer: 
Debug (org-odt): Searching for OpenDocument schema files...
Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/contrib/odt/etc/schema/...
Debug (org-odt): No OpenDocument schema files installed
Debug (org-odt): Searching for OpenDocument styles files...
Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/etc/styles/...
Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/org/etc/styles/...
Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/etc/org/...
Debug (org-odt): Using styles under /usr/pkg/share/emacs/24.2/etc/org/
Exporting to ODT using org-lparse...
Using vacuous schema
org-babel-exp processing... [2 times]
org-odt-format-source-code-or-example-colored: Symbol's function definition is void: copy-seq
byte-code: Beginning of buffer [16 times]


> (New file)
>
>
> It may have something to do with what you have in your Org file.  Try
> "minimizing" your Org file one by one until you find where the problem
> is.
>

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

* Re: Cannot convert to Odt
  2013-07-10 21:54   ` Tim Hawes
@ 2013-07-11  2:32     ` Jambunathan K
  2013-07-11 14:37       ` Tim Hawes
  0 siblings, 1 reply; 7+ messages in thread
From: Jambunathan K @ 2013-07-11  2:32 UTC (permalink / raw)
  To: Tim Hawes; +Cc: emacs-orgmode Mode

Tim Hawes <hawest@anx.com> writes:

> Jambunathan K writes:
>
> I am able to convert the same file on my home laptop with org-version
> 7.8.11
>
> Nonetheless, I tried it with this minimal file:
> #+STARTUP: showeverything
>
> * Heading 1
>
>   1. Item 1



> starting emacs with emacs -Q I am getting this error:
> ("emacs")
> Loading term/xterm...done
> For information about GNU Emacs and the GNU system, type C-h C-a.
> kmacro-call-macro: No kbd macro has been defined
> Making completion list... [2 times]
> Export buffer: 
> Debug (org-odt): Searching for OpenDocument schema files...
> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/contrib/odt/etc/schema/...
> Debug (org-odt): No OpenDocument schema files installed
> Debug (org-odt): Searching for OpenDocument styles files...
> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/etc/styles/...
> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/org/etc/styles/...
> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/etc/org/...
> Debug (org-odt): Using styles under /usr/pkg/share/emacs/24.2/etc/org/
> Exporting to ODT using org-lparse...
                         ^^^^^^^^^^
                         ^^^^^^^^^^
> Using vacuous schema
> org-babel-exp processing... [2 times]
> org-odt-format-source-code-or-example-colored: Symbol's function
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^    
> definition is void: copy-seq
       
> byte-code: Beginning of buffer [16 times]

The ODT exporter is 7.8.11 version.  (The presence of org-lparse says it
is a 7.8 version)

You are having a old version of Emacs and hence org-odt.el.  Try
upgrading it to emacs-24.3 (or whatever is the newest stable version) or
the latest Org-7.8.X version.

----------------------------------------------------------------

I see no correspondence between the example Org file and the problem
reported.  Problematic path gets triggered only if there are source
blocks.  The Org file has no source block.  Definitely there is
something amiss at your side.

----------------------------------------------------------------

Org-7.8.11 is more or less on life-support.  Issues with Org-8.0 will be
more interesting.  Make sure to use GNU ELPA package and isolate
the issue further.

Start Emacs *normally*.  (Otherwise the exporter used will be the old
one.)  

*After* export, try 

    M-x org-version RET

    M-x locate-library RET org-compat RET

and ensure that the right version of Org is picked up.

The problem comes from one of the shell blocks (either babel execution
or source block coloration.)

----------------------------------------------------------------


>> (New file)
>>
>>
>> It may have something to do with what you have in your Org file.  Try
>> "minimizing" your Org file one by one until you find where the problem
>> is.
>>

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

* Re: Cannot convert to Odt
  2013-07-11  2:32     ` Jambunathan K
@ 2013-07-11 14:37       ` Tim Hawes
  2013-07-11 17:09         ` Jambunathan K
  0 siblings, 1 reply; 7+ messages in thread
From: Tim Hawes @ 2013-07-11 14:37 UTC (permalink / raw)
  To: Jambunathan K; +Cc: emacs-orgmode Mode


Ok, there is a lot going on that I have no explanation for. The document
in question converts just fine on my home laptop with org-version 7.8.11
(or does it? need to go home and check the resulting doc. It does convert, and libreoffice starts and opens the converted document)

On my work laptop, both the document in question and my small test
document failed with both 7.8.11 and 8.0.5 (from elpa)

I don't know why the minimalistic file was failing. It is working today
(alignment of the planets? phase of the moon? stupid user? <-- I'll
never admit to this)

Since I got the minimalistic file running, I started adding more content
from my original content, piece by piece, until it failed (using
org-mode 8.0.5 from elpa).

These messages should have clued me in originally:
>> sh-syntax-propertize-function: Beginning of buffer
and
>> org-odt-format-source-code-or-example-colored: Symbol's function
The problem was a shell code fragment, the parser did not know what to
do with:
#+BEGIN_SRC sh
  nodaemon)
    nodaemon()
    ;;
#+END_SRC

Just making the code more comprehensible as shell code as thus:

#+BEGIN_SRC sh
case "$1" in
....
  nodaemon)
    nodaemon()
    ;;
....
esac
#+END_SRC

or changing the code segment into EXAMPLE instead, fixes it. It converts
under 7.8.11 and 8.0.5

What I am curious about is why doesn't this fail in html or latex
conversion, but even more important, what bone-head thing did I do to
make it work on my home laptop, with an un-corrected version of the same
document (both home and work laptops are getting the file from my
Dropbox folder, so I know it is the same file)

I guess the other question is, what bone-headed thing did I do that
caused the minimalistic file to fail with both versions of org-mode on
my work laptop?

The world may never know...

The important thing is now I am converting this document to odt on the
work laptop. Afterall, the document in question is a work document.

Jambunathan K writes:

> Tim Hawes <hawest@anx.com> writes:
>
>> Jambunathan K writes:
>>
>> I am able to convert the same file on my home laptop with org-version
>> 7.8.11
>>
>> Nonetheless, I tried it with this minimal file:
>> #+STARTUP: showeverything
>>
>> * Heading 1
>>
>>   1. Item 1
>
>
>
>> starting emacs with emacs -Q I am getting this error:
>> ("emacs")
>> Loading term/xterm...done
>> For information about GNU Emacs and the GNU system, type C-h C-a.
>> kmacro-call-macro: No kbd macro has been defined
>> Making completion list... [2 times]
>> Export buffer: 
>> Debug (org-odt): Searching for OpenDocument schema files...
>> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/contrib/odt/etc/schema/...
>> Debug (org-odt): No OpenDocument schema files installed
>> Debug (org-odt): Searching for OpenDocument styles files...
>> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/etc/styles/...
>> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/lisp/org/etc/styles/...
>> Debug (org-odt): Trying /usr/pkg/share/emacs/24.2/etc/org/...
>> Debug (org-odt): Using styles under /usr/pkg/share/emacs/24.2/etc/org/
>> Exporting to ODT using org-lparse...
>                          ^^^^^^^^^^
>                          ^^^^^^^^^^
>> Using vacuous schema
>> org-babel-exp processing... [2 times]
>> org-odt-format-source-code-or-example-colored: Symbol's function
>   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^    
>> definition is void: copy-seq
>        
>> byte-code: Beginning of buffer [16 times]
>
> The ODT exporter is 7.8.11 version.  (The presence of org-lparse says it
> is a 7.8 version)
>
> You are having a old version of Emacs and hence org-odt.el.  Try
> upgrading it to emacs-24.3 (or whatever is the newest stable version) or
> the latest Org-7.8.X version.
>
> ----------------------------------------------------------------
>
> I see no correspondence between the example Org file and the problem
> reported.  Problematic path gets triggered only if there are source
> blocks.  The Org file has no source block.  Definitely there is
> something amiss at your side.
>
> ----------------------------------------------------------------
>
> Org-7.8.11 is more or less on life-support.  Issues with Org-8.0 will be
> more interesting.  Make sure to use GNU ELPA package and isolate
> the issue further.
>
> Start Emacs *normally*.  (Otherwise the exporter used will be the old
> one.)  
>
> *After* export, try 
>
>     M-x org-version RET
>
>     M-x locate-library RET org-compat RET
>
> and ensure that the right version of Org is picked up.
>
> The problem comes from one of the shell blocks (either babel execution
> or source block coloration.)
>
> ----------------------------------------------------------------
>
>
>>> (New file)
>>>
>>>
>>> It may have something to do with what you have in your Org file.  Try
>>> "minimizing" your Org file one by one until you find where the problem
>>> is.
>>>

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

* Re: Cannot convert to Odt
  2013-07-11 14:37       ` Tim Hawes
@ 2013-07-11 17:09         ` Jambunathan K
  0 siblings, 0 replies; 7+ messages in thread
From: Jambunathan K @ 2013-07-11 17:09 UTC (permalink / raw)
  To: Tim Hawes; +Cc: emacs-orgmode Mode

Tim Hawes <hawest@anx.com> writes:

> The problem was a shell code fragment, the parser did not know what to
> do with:
> #+BEGIN_SRC sh
>   nodaemon)
>     nodaemon()
>     ;;
> #+END_SRC
>
> Just making the code more comprehensible as shell code as thus:
>
> #+BEGIN_SRC sh
> case "$1" in
> ....
>   nodaemon)
>     nodaemon()
>     ;;
> ....
> esac
> #+END_SRC
>
> or changing the code segment into EXAMPLE instead, fixes it. It converts
> under 7.8.11 and 8.0.5

I don't use Org-mode or Babel myself.  I don't understand shell code.

Different backends use different engines for colorizing source blocks.

    ODT uses htmlfontify.  
    HTML uses htmlize.
    LaTeX probably relies on TeX packages like minted etc.

I suspect the problem could be in htmlfontify library or the exporter
interfaces with it.  If you could post a complete minimal snippet by
removing ellipses etc., I can do some post-mortem and narrow the issue
further.

You can turn off the colors on source blocks by customizing,

     M-x customize-variable RET org-odt-fontify-srcblocks RET

So, instead of switching to EXAMPLE blocks you can just turn off
colorization and see whether problem is reproducible.  This is a sure
proof that there is something amiss in htmlfontify.el or how the expoter
interfaces with it.

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

end of thread, other threads:[~2013-07-11 17:07 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-10 17:55 Cannot convert to Odt Tim Hawes
2013-07-10 18:11 ` Jambunathan K
2013-07-10 21:54   ` Tim Hawes
2013-07-11  2:32     ` Jambunathan K
2013-07-11 14:37       ` Tim Hawes
2013-07-11 17:09         ` Jambunathan K
2013-07-10 18:38 ` Eric S Fraga

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