On 27/02/12 22:05, Jorge Marín G wrote:
Hello , I used asciidoc version 8.5.3 to create HTML documents from
txt documents calling ascidocapi.py from java
(org.python.util.PythonInterpreter).

It worked very well until asciidoc version 8.6.5, but when I have
tried to use the newest version (8.6.6) an exception is launched.

I call the asciidocapi.py script in this way:

1- PythonInterpreter python = new PythonInterpreter();
2- python.exec("import imp");
3- python.exec("asciidocapi = imp.load_source('AsciiDocAPI', [PATH
where
is asciidocapi.py in my machine])");

4- python.exec("asciidoc = asciidocapi.AsciiDocAPI()");
5- python.exec("asciidoc.asciidoc.execute(''file.txt')");

When I did that, I got a file.HTML using previous asciidoc versions,
but now, with version 8.6.6 I get the next exception:

asciidoc: FAILED: malformed [titles] underlines entry

I think there is a BUG in this version, something has been changed and
now this version (8.6.6) is not compatible with JYTHON.

If anybody know how to fix this error, please, answer me.

Have just done a basic tests against the distributed example article with Jython 2.5.2 (Release_2_5_2:7206, Mar 2 2011, 23:12:06)
[OpenJDK Server VM (Sun Microsystems Inc.)] on java1.6.0_20

and come up with the same error:

$ jython asciidoc.py doc/article.txt
asciidoc: FAILED: malformed [titles] underlines entry

I poked around and *suspect* that the error was introduced with this changeset:

http://code.google.com/p/asciidoc/source/detail?r=66543730504e5dc07a56fcd89b238ef784cdeac4

which uses the Python compiler to remove eval()s.

I would like AsciiDoc to work with Jython so if anyone can figure out exactly what's causing it and come up with at patch that would be great.


Cheers, Stuart


Thanks.


--
You received this message because you are subscribed to the Google Groups 
"asciidoc" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/asciidoc?hl=en.

Reply via email to