# HG changeset patch # User fabio # Date 1498184875 14400 # Node ID 33e5c1b7b9af4e4ebd8bf4dce3d50bb1c7a2f988 # Parent b0d8d9cdf94298e05fcb5bdecd76f29b7016f96c Uploaded diff -r b0d8d9cdf942 -r 33e5c1b7b9af gdcwebapp.xml --- a/gdcwebapp.xml Thu Jun 22 16:34:14 2017 -0400 +++ b/gdcwebapp.xml Thu Jun 22 22:27:55 2017 -0400 @@ -5,15 +5,7 @@ python json_collect_data_source - - - - - - - + json_collect_data_source.py '${__app__.config.output_size_limit}' --json_param_file '${output1}' --path '.' --appdata 'tmp' Go to GDCWebApp service $GALAXY_URL diff -r b0d8d9cdf942 -r 33e5c1b7b9af jcds_wrapper.py --- a/jcds_wrapper.py Thu Jun 22 16:34:14 2017 -0400 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,46 +0,0 @@ -#!/usr/bin/env python -import json_collect_data_source as jcds -import optparse - -__version__ = "1.0.0" - -def __main__(): - """ Read the JSON return from a data source. Parse each line and request - the data, download to "newfilepath", and write metadata. - - Schema - ------ - - [ {"url":"http://url/to/file.tar.gz", - "name":"My Archive", - "extension":"tar.gz", - "organize":"true", - "metadata":{"db_key":"hg38"}, - "extra_data":[ {"url":"http://url_of_ext_file", - "path":"rel/path/to/ext_file"} - ] - } - ] - - """ - # Parse the command line options - usage = "Usage: jcds_wrapper.py max_size --json_param_file filename [options]" - parser = optparse.OptionParser(usage = usage) - parser.add_option("-j", "--json_param_file", type="string", - action="store", dest="json_param_file", help="json schema return data") - parser.add_option("-p", "--path", type="string", - action="store", dest="path", help="new file path") - # set appdata: temporary directory in which the archives will be decompressed - parser.add_option("-a", "--appdata", type="string", - action="store", dest="appdata", help="appdata folder name") - parser.add_option("-v", "--version", action="store_true", dest="version", - default=False, help="display version and exit") - - (options, args) = parser.parse_args() - if options.version: - print __version__ - else: - jcds.download_from_json_data( options, args ) - - -if __name__ == "__main__": __main__()