PythonDoc Ant Task

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • abcd

    #1

    PythonDoc Ant Task

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

    <path id="myPyPath">
    <pathelement location="src"/>
    <pathelement location="resou rces"/>
    </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.

  • abcd

    #2
    Re: PythonDoc Ant Task

    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!

    Comment

    • Fredrik Lundh

      #3
      Re: PythonDoc Ant Task

      "abcd" wrote:
      [color=blue]
      > class Bar:
      > global javax.swing
      > import javax.swing
      > [/code]
      >
      > ....so it seems that pydoc cant giggity-giggit![/color]

      "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>



      Comment

      Working...