importing tasks using relative paths in Terra

Post author
Wendy Wong

Hi,

I am wondering if there is a way to write a WDL workflow that import tasks using relative paths in Terra. I am able to do so by supplying a zip file of the tasks when I submit jobs directly to the Cromwell server. However, in Terra it seems that the option is to provide a single WDL file in Broads methods repository, where I can only import tasks by providing their HTML paths. 

Is it possible to upload a directory and use relative paths for the task instead? 

Thanks,

Wendy

Comments

6 comments

  • Comment author
    Jason Cerrato

    Hi Wendy,

    Thank you for writing in. You can do imports in both the Broad methods repository and in Dockstore.

    Dockstore allows you to use HTML paths and relative paths to WDL workflow files from a git repository. In the Broad methods repository you have to use HTML paths to the workflows.

    If you are interested in using relative paths, I would recommend setting up a git repository for your WDL and utilizing Dockstore. You can see an example of this here: https://dockstore.org/workflows/github.com/gatk-workflows/gatk4-exome-analysis-pipeline/ExomeGermlineSingleSample:1.4.0?tab=info

    Kind regards,

    Jason

    0
  • Comment author
    Andrew Davidson

    can you provide me with a couple of examples?

     

    1) say I am defining a workflow WDL in the namespace 'xyzNameSpace' in the Broad's method repository' and want to import a task in the same workspace 

     

    2) same example now I want to import a task in a different repository

     

    Kind regards

    Andy

    0
  • Comment author
    Jason Cerrato

    Hey Andrew Davidson,

    I'm happy to help provide examples. For number 1, am I correct in understanding that you want to import a task in the same method namespace (rather than Terra workspace)? As mentioned in my message above, you will need to import the HTML paths when using the Broad Methods Repository.

    For an example, see this Cumulus method: https://portal.firecloud.org/#methods/cumulus/cumulus/37/wdl

     

    Line 3 shows how you would import a subworkflow. And here is how you would call a specific task from that subworkflow:

     

    The arrow in the first screenshot shows you where to find the HTTP path for the workflow, which is what you would use if you want to import that method and its tasks for another method. The same practice would be used for a task from a different namespace.

    I hope this makes sense! If you have any further questions, please let us know.

    Kind regards,

    Jason

    0
  • Comment author
    Andrew Davidson

    Hi Jason

     

    I only have the option to download wdl or export to workspace. I do not have the "import URL for this WDL"

     

    Also a minor request for enhancement. It would be really nice if there was a pull-down menu that made it easy for me to select one of my existing  namespaces

     

    Kind regards

     

    Andy

     

    p.s. I am very impressed with Terra. 

     

     

    0
  • Comment author
    Jason Cerrato

    Hi Andy,

    Ah one more important piece of information I didn't mention - any WDL you want to import must be Publicly Readable, which you can set in the Permissions options. 

     

    If you are set on not making your WDL public, you can consider copy-pasting the relevant sections to your main WDL.

    Thank you for your suggestion of a pull-down menu. I'll be happy to flag this up with our developers for their consideration!

    Kind regards,

    Jason

    0
  • Comment author
    Andrew Davidson

    LOL!

    Thanks

    Andy

    0

Please sign in to leave a comment.