On Tue, Feb 25, 2014 at 2:29 PM, John Chilton <jmchil...@gmail.com> wrote:
> On Tue, Feb 25, 2014 at 8:08 AM, Peter Cock <p.j.a.c...@googlemail.com> wrote:
>>
>> I've also just tried this for the masking files - but ran into a problem.
>> Here the masks are optional, and I want the default to be no mask:
>>
>> https://github.com/peterjc/galaxy_blast/commit/e1bcb24ac24613395a0fe327c54cd3eab343feb7
>>
>> This works fine from the user interface perspective:
>>
>> <param name="input_file" type="data" multiple="true" optional="false"
>> format="fasta" label="Input FASTA files(s)" help="One or more FASTA
>> files" />
>>
>> This requires at least one file, although a confusing red error
>> message is given if none is selected:
>>
>> "History does not include a dataset of the required format / build"
>>
>> <param name="mask_data_file" type="data" multiple="true"
>> optional="true" value="" format="maskinfo-asn1,maskinfo-asn1-binary"
>> label="Optional ASN.1 file(s) containing masking data" help="As
>> produced by NCBI masking applications (e.g. dustmasker, segmasker,
>> windowmasker)" />
>>
>> This does not require a file, and defaults to selecting a new dummy
>> entry "Selection is Optional". This is presumably intended as a visual
>> cue - but it means you can do weird things like picking a read file
>> and the dummy entry, or no entries. Neither allows me to proceed,
>> instead on pressing execute I get a red error on a new page:
>>
>> Error executing tool: 'NoneType' object has no attribute 'file_name'
>>
>> galaxy.tools ERROR 2014-02-25 14:02:47,844 Exception caught while
>> attempting tool execution:
>> Traceback (most recent call last):
>>   File "/mnt/galaxy/galaxy-central/lib/galaxy/tools/__init__.py", line
>> 1916, in __handle_tool_execute
>>     _, out_data = self.execute( trans, incoming=params,
>> history=history, rerun_remap_job_id=rerun_remap_job_id )
>>   File "/mnt/galaxy/galaxy-central/lib/galaxy/tools/__init__.py", line
>> 2424, in execute
>>     return self.tool_action.execute( self, trans, incoming=incoming,
>> set_output_hid=set_output_hid, history=history, **kwargs )
>>   File "/mnt/galaxy/galaxy-central/lib/galaxy/tools/actions/__init__.py",
>> line 287, in execute
>>     data.name = self.get_output_name( output, data, tool, on_text,
>> trans, incoming, history, wrapped_params.params, job_params )
>>   File "/mnt/galaxy/galaxy-central/lib/galaxy/tools/parameters/wrapped.py",
>> line 26, in params
>>     self.wrap_values( self.tool.inputs, params,
>> skip_missing_values=not self.tool.check_values )
>>   File "/mnt/galaxy/galaxy-central/lib/galaxy/tools/parameters/wrapped.py",
>> line 51, in wrap_values
>>     name=input.name )
>>   File "/mnt/galaxy/galaxy-central/lib/galaxy/tools/wrappers.py", line
>> 215, in __init__
>>     list.__init__( self, map( to_wrapper, datasets ) )
>>   File "/mnt/galaxy/galaxy-central/lib/galaxy/tools/wrappers.py", line
>> 209, in to_wrapper
>>     real_path = dataset.file_name
>> AttributeError: 'NoneType' object has no attribute 'file_name'
>>
>> Any thoughts? Is zero files a little tested corner of the multiple file 
>> support?
>
> Yes it is a corner case I personally had not tested. Are you are
> running something later than the latest dist but not the latest
> central? It seems like yes. Because I believe Dan has fixed the bug
> that produces the particular stack trace you are seeing last week - he
> has probably fixed the other problems you mentioned also? Can you
> upgrade and let me know, if not let me know and I can take a look a
> closer look.

This one on TravisCI (which looks like the latest galaxy-central)
fails with:

Fatal error: Matched on Error:
Error: Ignoring mask file 'None' as it does not exist.

https://travis-ci.org/peterjc/galaxy_blast/builds/19577818

Perhaps I can workaround this in the Cheetah template, but
ideally the no-files case would be handled nicely in the framework.

Peter
___________________________________________________________
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