PythonDoc Ant Task

A

abcd

Anyone ever use the PythonDoc ant task? I have the following...

<path id="myPyPath">
<pathelement location="src"/>
<pathelement location="resources"/>
</path>

<target name="pyDoc">
<mkdir dir="docs"/>
<py-doc pythonpathref="myPyPath" destdir="docs">
<fileset dir="src">
<include name="**/*.py"/>
</fileset>
</py-doc>
</target>

....this is a cut out of the build xml i am using...but it shows the
relevant parts. Anyways I can run my "pyDoc" target and it runs
successful with no errors. a "docs" directory is created but is empty.
Any idea as to why?

My "src" folder contains a python file, Foo.py. which looks like this

class Bar:
def printMe(self):
"""This method prints my data"""
print "some data is being printed"

....Thanks in advance.
 
A

abcd

i found that the problem is because of an import, which is strange.
The imported module looks something like this

Code:
import time

class Foo:
    pass

class Bar:
    global javax.swing
    import javax.swing

.....so it seems that pydoc cant giggity-giggit!
 
F

Fredrik Lundh

abcd said:
class Bar:
global javax.swing
import javax.swing
[/code]

....so it seems that pydoc cant giggity-giggit!

"global javax.swing" is not valid Python syntax. what is that global/import combo
supposed to do, and what environment do you run this under ?

</F>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,989
Messages
2,570,207
Members
46,782
Latest member
ThomasGex

Latest Threads

Top