[-- Attachment #1: Type: text/plain, Size: 440 bytes --] Dear all, I tried exporting a document with table that has caption to ODT and it failed with this error message: OpenDocument export failed: Wrong number of arguments: nil, 0 Sample document: #+CAPTION: some caption | row1 | Export is successful when caption is removed. Export is successful for image captions. Export to HTML or Markdown is successful. Org-mode version 8.2.10, Emacs 25.2.2 on LinuxMint 19. Any pointer? [-- Attachment #2: Type: text/html, Size: 655 bytes --]
Perl Ancar <perlancar@gmail.com> writes: > I tried exporting a document with table that has caption to ODT and it > failed with this error message: > > OpenDocument export failed: Wrong number of arguments: nil, 0 > > Sample document: > > #+CAPTION: some caption > | row1 | Trying with the latest release of Org (9.3.6), I exported this without hitting the above error, so upgrading will likely resolve the issue for you. > Any pointer? If upgrading doesn't work for you (or you'd just like to investigate), doing "M-x toggle-debug-on-error" and getting a backtrace could be a good place to start.
[-- Attachment #1: Type: text/plain, Size: 1987 bytes --] On Sun, Apr 5, 2020 at 12:16 PM Kyle Meyer <kyle@kyleam.com> wrote: > Perl Ancar <perlancar@gmail.com> writes: > > > I tried exporting a document with table that has caption to ODT and it > > failed with this error message: > > > > OpenDocument export failed: Wrong number of arguments: nil, 0 > > > > Sample document: > > > > #+CAPTION: some caption > > | row1 | > > Trying with the latest release of Org (9.3.6), I exported this without > hitting the above error, so upgrading will likely resolve the issue for > you. > > > Any pointer? > > If upgrading doesn't work for you (or you'd just like to investigate), > doing "M-x toggle-debug-on-error" and getting a backtrace could be a > good place to start. > Unfortunately after M-x toggle-debug-on-error I'm not getting relevant additional messages in the *Messages* buffer (I read that messages will appear in the *Warnings* buffer, but I see that there is no *Warnings* buffer created): Debug on Error enabled globally Debug (ox-odt): Searching for OpenDocument styles files... Debug (ox-odt): Trying /usr/share/emacs/25.2/etc/styles/... [2 times] Debug (ox-odt): Trying /usr/share/emacs/25.2/lisp/org/etc/styles/... Debug (ox-odt): Trying /usr/share/emacs/25.2/etc/org/... Debug (ox-odt): Using styles under /usr/share/emacs/25.2/etc/org/ Debug (ox-odt): Searching for OpenDocument schema files... Debug (ox-odt): Trying /usr/share/emacs/25.2/etc/schema/... Debug (ox-odt): No OpenDocument schema files installed LaTeX to MathML converter not available. Formatting LaTeX using verbatim OpenDocument export failed: Wrong number of arguments: nil, 0 You can run the command ‘org-odt-export-to-odt’ with M-x -od-t RET However, when trying to upgrade org, I try exporting under "emacs -q" and this error does not happen. So I'll need to comb through my years-old ~/.emacs to try to figure out what causes this error. [-- Attachment #2: Type: text/html, Size: 2580 bytes --]
Perl Ancar <perlancar@gmail.com> writes:
> On Sun, Apr 5, 2020 at 12:16 PM Kyle Meyer <kyle@kyleam.com> wrote:
>
>> > Any pointer?
>>
>> If upgrading doesn't work for you (or you'd just like to investigate),
>> doing "M-x toggle-debug-on-error" and getting a backtrace could be a
>> good place to start.
>>
>
> Unfortunately after M-x toggle-debug-on-error I'm not getting relevant
> additional messages in the *Messages* buffer (I read that messages will
> appear in the *Warnings* buffer, but I see that there is no *Warnings*
> buffer created):
Ah, sorry for the unhelpful suggestion. It looks like that error is
being caught (which I should have guessed from the "OpenDocument ..."
prefix):
(defmacro org-odt--export-wrap (out-file &rest body)
[...]
(condition-case err
[...]
(error
;; Cleanup work directory and work files.
(funcall --cleanup-xml-buffers)
(message "OpenDocument export failed: %s"
(error-message-string err)))))
So to see the error, you could either remove that error handling or
tweak it to re-throw it:
(signal (car err) (cdr err))