mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Fix for get_microbial_data tool.
This commit is contained in:
@@ -24,7 +24,7 @@ while have_none:
|
||||
#create dictionary keyed by uid of tuples of (displayName,filePath,build) for all files
|
||||
available_files = {}
|
||||
try:
|
||||
filename = sys.argv[9]
|
||||
filename = sys.argv[-1]
|
||||
for i, line in enumerate( file( filename ) ):
|
||||
if not line or line[0:1] == "#" : continue
|
||||
fields = line.split('\t')
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
|
||||
def load_microbial_data( GALAXY_INDEX_DATA_DIR, sep='\t' ):
|
||||
def load_microbial_data( GALAXY_DATA_INDEX_DIR, sep='\t' ):
|
||||
# FIXME: this function is duplicated in the DynamicOptions class. It is used here only to
|
||||
# set data.name in exec_after_process().
|
||||
microbe_info= {}
|
||||
orgs = {}
|
||||
|
||||
filename = "%s/microbial_data.loc" % GALAXY_DATA_INDEX_DIR
|
||||
for i, line in enumerate( file( filename ) ):
|
||||
for i, line in enumerate( open( filename ) ):
|
||||
line = line.rstrip( '\r\n' )
|
||||
if line and not line.startswith( '#' ):
|
||||
fields = line.split( sep )
|
||||
@@ -96,7 +96,8 @@ def exec_after_process(app, inp_data, out_data, param_dict, tool, stdout, stderr
|
||||
if not (kingdom or org):
|
||||
print "Parameters are not available."
|
||||
|
||||
microbe_info = load_microbial_data( param_dict.get( 'GALAXY_INDEX_DATA_DIR' ), sep='\t' )
|
||||
GALAXY_DATA_INDEX_DIR = app.config.tool_data_path
|
||||
microbe_info = load_microbial_data( GALAXY_DATA_INDEX_DIR, sep='\t' )
|
||||
new_stdout = ""
|
||||
split_stdout = stdout.split("\n")
|
||||
basic_name = ""
|
||||
|
||||
Reference in New Issue
Block a user