commit/galaxy-central: jeremy goecks: Update tool template's chrom_info to correctly point to len file for custom builds defined by len files. This was broken was len files were moved from the len_file directory to HDAs.
1 new commit in galaxy-central: https://bitbucket.org/galaxy/galaxy-central/commits/117fef56513f/ Changeset: 117fef56513f User: jeremy goecks Date: 2014-01-23 21:29:14 Summary: Update tool template's chrom_info to correctly point to len file for custom builds defined by len files. This was broken was len files were moved from the len_file directory to HDAs. Affected #: 1 file diff -r 7fd2f3f098840a5a1b9d7041330100c4f2af70df -r 117fef56513fc563dd231516196cfd601c1635e2 lib/galaxy/tools/actions/__init__.py --- a/lib/galaxy/tools/actions/__init__.py +++ b/lib/galaxy/tools/actions/__init__.py @@ -213,7 +213,7 @@ db_datasets[ "chromInfo" ] = db_dataset incoming[ "chromInfo" ] = db_dataset.file_name else: - # -- Get chrom_info from either a custom or built-in build. -- + # -- Get chrom_info (len file) from either a custom or built-in build. -- chrom_info = None if trans.user and ( 'dbkeys' in trans.user.preferences ) and ( input_dbkey in from_json_string( trans.user.preferences[ 'dbkeys' ] ) ): @@ -226,9 +226,13 @@ # condition below to avoid getting chrom_info when running the # fasta-to-len converter. if 'fasta' in custom_build_dict and tool.id != 'CONVERTER_fasta_to_len': + # Build is defined by fasta; get len file, which is obtained from converting fasta. build_fasta_dataset = trans.sa_session.query( trans.app.model.HistoryDatasetAssociation ).get( custom_build_dict[ 'fasta' ] ) chrom_info = build_fasta_dataset.get_converted_dataset( trans, 'len' ).file_name - + elif 'len' in custom_build_dict: + # Build is defined by len file, so use it. + chrom_info = trans.sa_session.query( trans.app.model.HistoryDatasetAssociation ).get( custom_build_dict[ 'len' ] ).file_name + if not chrom_info: # Default to built-in build. chrom_info = os.path.join( trans.app.config.len_file_path, "%s.len" % input_dbkey ) Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.
participants (1)
-
commits-noreply@bitbucket.org