Hi,

While developing a tool, I am facing Cheetah code issue. I looked up the
mailing list archive and found many similar issues reported earlier but
could not debug this. Any tips in debugging is appreciated.

File "cheetah_DynamicallyCompiledCheetahTemplate_1391530084_29_71368.py",
line 97, in respond
NotFound: cannot find 'rngstart'

Attached is the xml tool definition file.

Best,
Ketan
<tool id="swiftforeach" name="foreach">
    <description>A generic tool to run executable via Swift foreach parallel construct</description>

    <command interpreter="bash">
        
    #if $rangeorlist.rl == "rng" 
    swiftforeachrange.sh
    $site 
    $interpret
    $exec
    $rngstart
    $rend
    $stepsize
    $outloc
    $logfile
    $outlist
    #for $a in $arg
    ${a.argname}
    #end for
    #else
    swiftforeachlist.sh
    $site 
    $interpret
    $exec
    $listfile
    $outloc
    $logfile
    $outlist
    #for $a in $arg
    ${a.argname}
    #end for
    #end if

    </command>

    <inputs>
        <param name="site" type="select" label="Execution Location">
            <option value="localhost">Localhost</option>
            <option value="midway">Midway</option>
            <option value="uc3">UC3</option>
            <option value="stampede">Stampede</option>
        </param>

        <param name="interpret" type="select" label="Execution interpreter">
            <option value="sh">sh</option>
            <option value="python">python</option>
            <option value="java">java</option>
            <option value="R">R</option>
            <option value="matlab">matlab</option>
        </param>

        <param format="sh,binexec" name="exec" type="data" label="Executable"/>

        <conditional name="rangeorlist">
        <param name="rl" type="select" label="Select range or list">
        <option value="rng">numeric range</option>
        <option value="lst">items list</option>
        </param>

        <when value="rng">
        <param name="rngstart" size="2" type="integer"  value="0" label="start"/>
        <param name="rend" size="2" type="integer"  value="9" label="end"/>
        <param name="stepsize" size="2" type="integer"  value="1" label="stepsize"/>
        </when>

        <when value="lst">
        <param format="data" name="listfile" type="data" label="List file"/>
        </when>

        </conditional>
        
        <repeat name="arg" title="arg">
            <param name="argname" type="text" label="arg" />
        </repeat>

        <param name="outloc" size="50" type="text" value="$HOME/swift-sandbox" label="location for output files" help="Swift will write output files here on disc">
            <sanitizer sanitize="False" />
        </param>

        <conditional name="configuration">
            <param name="mode" type="select" label="Swift configuration">
                <option value="default">default configuration</option>
                <option value="advanced">advanced configuration</option>
            </param>

            <when value="default">
            </when>
            <when value="advanced">
                <param name="remoteurl" size="50" type="text" value="midway.swift.rcc.uchicago.edu" label="remote url" help="remote resource to run jobs on"></param>
                <param name="throttle" size="5" type="float" value="0.07" label="job throttle" help="number of parallel jobs to run"></param>
                <param name="project" type="text" value="TG-STA110005S" label="Project allocation" help="name/code of project"></param>
                <param name="slots" size="5" type="integer" value="1" label="slots" help="number of scheduler jobs"></param>
                <param name="queue" size="5" type="text" value="normal" label="queue" help="queue to run jobs on"></param>
                <param name="nodes" size="5" type="integer" value="1" label="nodes" help="number of nodes requested"></param>
                <param name="nodegranularity" size="5" type="integer" value="1" label="node granularity" help="node granularity"></param>
                <param name="jobspernode" size="5" type="integer" value="8" label="jobs per node" help="number of jobs per node requested"></param>
                <param name="ppn" size="5" type="integer" value="8" label="ppn" help="processes per node requested"></param>
                <param name="walltime" size="5" type="text" value="00:10:00" label="Job walltime" help="time in hh:mm:ss to request to scheduler for this job"></param>
                <param name="maxtime" size="5" type="integer" value="700" label="application maxtime" help="Application maxtime in seconds for this job"></param>
            </when>
        </conditional>
    </inputs>
    <outputs>
        <data format="txt" name="logfile" type="data" label="Swift output" />
        <data format="txt" name="outlist" type="data" label="Output list" />
    </outputs>

    <!--
  <code file="postprocess.py">
    <hook postprocess="writeoutlist" />
  </code>
  -->

<help>
.. class:: warningmark

**TIP**. Add args to provide additional arguments to your executable. 

-----

**What it does**

This is a generic Swift tool that runs an executable over a range of numbers with arbitrary stepsize. 

Execution location allows user to declare where to run the tool. Executable can be any arbitrary executable of type "binexec" uploaded by user.

Start, end and stepsize are integer values. Note that the stepsize cannot be less than 1. Optionally, sser can add new arguments to be provided to the tool executable after the numeric argument. Each args box must contain exactly one argument without spaces.

-----

**Example**

Pick up an executable from the Executable list. Enter the start, end and the step size values. Enter an additional argument "hello". 

If an executable is echo.sh with following line:

echo $@

The start, end and step is 0, 9 and 2, the executable will be invoked in parallel 5 times for n where n is 0 2 4 6 8:

echo n hello

</help>
</tool>
___________________________________________________________
Please keep all replies on the list by using "reply all"
in your mail client.  To manage your subscriptions to this
and other Galaxy lists, please use the interface at:
  http://lists.bx.psu.edu/

To search Galaxy mailing lists use the unified search at:
  http://galaxyproject.org/search/mailinglists/

Reply via email to