Menu

when running a sql2java ant task...

Help
2007-08-23
2013-04-25
  • David Goodenough

    which directory is used to make the paths in the properties file?

    I ask because I have build an ant task, and it keeps on saying things like:-

    Aborted writing component:sql2java/java5/pertable/manager.java.vm for table:string_value_details because Velocity could not find the resource.

    Yet relative to the current directory there is a directory sql2java/java5/pertable and a file of the right name in that directory.

    This was actually the last of the error messages, it produced this for all the resources it tried to use.

    In the properties file I have:-

    velocity.templates.loadingpath=sql2java/includes
    velocity.templates=sql2java

    I notice in the source that this message throws away whatever information velocity might have left around saying exactly what it failed to find.

    David

     
    • David Goodenough

      found it.  I had the following in my properties file:-

      velocity.templates.loadingpath=sql2java/includes
      velocity.templates=sql2java

      Using strace I found it was trying to access files at:-

      sql2java/includes/sql2java/java5....

      Looking at the original properties file I noticed that the loadingpath
      should have been:-

      velocity.templates.loadingpath=.;sql2java/includes

      I had removed the .; as I could not see why it was needed, now I see.

      It is a bit depressing that I had to use strace to find it, but emitting good error messages always was a dark art.

      David

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.