Hi, I created a metadata to hold 5 files together (1 primary and 4 data files). The file extension corresponding to the following metadata appears correctly in the list. But When I try to upload the files. I get the following error. Could you please help me fix this. Here is the small class that I created to hold metadata: class CompositeTest( Data ): file_ext="comptest" MetadataElement( name="data_lines", default=0, desc="Number of data lines", readonly=True, optional=True, visible=False, no_value=0 ) composite_type="basic" def __init__(self,**kwd): Data.__init__(self,**kwd) self.add_composite_file('pedfile.txt') self.add_composite_file('mapfile.txt') self.add_composite_file('frequencyfile.txt') self.add_composite_file('datafile.txt') def init_meta(self,dataset,copy_from=None ): Data.init_meta(self,dataset,copy_from=copy_from) Source Template Extra Data Traceback Error Traceback: View as: Interactive | Text | XML (full) ⇝ AttributeError: 'Bunch' object has no attribute 'space_to_tab' URL: http://10.70.250.254:8080/tool_runner/index Module weberror.evalexception.middleware:364 in respond view
app_iter = self.application(environ, detect_start_response) Module paste.debug.prints:97 in __call__ view status, headers, body = wsgilib.intercept_output( Module paste.wsgilib:539 in intercept_output view app_iter = application(environ, replacement_start_response) Module paste.recursive:80 in __call__ view return self.application(environ, start_response) Module paste.httpexceptions:632 in __call__ view return self.application(environ, start_response) Module galaxy.web.framework.base:125 in __call__ view body = method( trans, **kwargs ) Module galaxy.web.controllers.tool_runner:53 in index view template, vars = tool.handle_input( trans, params.__dict__ ) Module galaxy.tools:795 in handle_input view _, out_data = self.execute( trans, incoming=params ) Module galaxy.tools:1067 in execute view return self.tool_action.execute( self, trans, incoming=incoming, set_output_hid=set_output_hid ) Module galaxy.tools.actions.upload:18 in execute view uploaded_datasets = upload_common.get_uploaded_datasets( trans, incoming, precreated_datasets, dataset_upload_inputs ) Module galaxy.tools.actions.upload_common:214 in get_uploaded_datasets view uploaded_datasets.extend( dataset_upload_input.get_uploaded_datasets( trans, params ) ) Module galaxy.tools.parameters.grouping:301 in get_uploaded_datasets view dataset.space_to_tab = file_bunch.space_to_tab AttributeError: 'Bunch' object has no attribute 'space_to_tab'
Extra Features
Display the lines of code near each part of the traceback Show a debug prompt to allow you to directly debug the code at the traceback
In Text Tab : URL: http://10.70.250.254:8080/tool_runner/index File '/export/home/galaxy/galaxy-dist/eggs/WebError-0.8a-py2.4.egg/weberror/evalexception/middleware.py', line 364 in respond app_iter = self.application(environ, detect_start_response) File '/export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/debug/prints.py', line 97 in __call__ status, headers, body = wsgilib.intercept_output( File '/export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/wsgilib.py', line 539 in intercept_output app_iter = application(environ, replacement_start_response) File '/export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/recursive.py', line 80 in __call__ return self.application(environ, start_response) File '/export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/httpexceptions.py', line 632 in __call__ return self.application(environ, start_response) File '/export/home/galaxy/galaxy-dist/lib/galaxy/web/framework/base.py', line 125 in __call__ body = method( trans, **kwargs ) File '/export/home/galaxy/galaxy-dist/lib/galaxy/web/controllers/tool_runner.py', line 53 in index template, vars = tool.handle_input( trans, params.__dict__ ) File '/export/home/galaxy/galaxy-dist/lib/galaxy/tools/__init__.py', line 795 in handle_input _, out_data = self.execute( trans, incoming=params ) File '/export/home/galaxy/galaxy-dist/lib/galaxy/tools/__init__.py', line 1067 in execute return self.tool_action.execute( self, trans, incoming=incoming, set_output_hid=set_output_hid ) File '/export/home/galaxy/galaxy-dist/lib/galaxy/tools/actions/upload.py', line 18 in execute uploaded_datasets = upload_common.get_uploaded_datasets( trans, incoming, precreated_datasets, dataset_upload_inputs ) File '/export/home/galaxy/galaxy-dist/lib/galaxy/tools/actions/upload_common.py', line 214 in get_uploaded_datasets uploaded_datasets.extend( dataset_upload_input.get_uploaded_datasets( trans, params ) ) File '/export/home/galaxy/galaxy-dist/lib/galaxy/tools/parameters/grouping.py', line 301 in get_uploaded_datasets dataset.space_to_tab = file_bunch.space_to_tab AttributeError: 'Bunch' object has no attribute 'space_to_tab' In XML(full) TAB: <?xml version="1.0" ?> <traceback> <sysinfo> <language version="2.4.3"> Python </language> </sysinfo> <stack> <frame> <module> weberror.evalexception.middleware </module> <filename> /export/home/galaxy/galaxy-dist/eggs/WebError-0.8a-py2.4.egg/weberror/evalexception/middleware.py </filename> <line> 364 </line> <function> respond </function> <operation> app_iter = self.application(environ, detect_start_response) </operation> <operation_context> try: __traceback_supplement__ = errormiddleware.Supplement, self, environ app_iter = self.application(environ, detect_start_response) try: return_iter = list(app_iter) </operation_context> </frame> <frame> <module> paste.debug.prints </module> <filename> /export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/debug/prints.py </filename> <line> 97 </line> <function> __call__ </function> <operation> status, headers, body = wsgilib.intercept_output( </operation> <operation_context> threadedprint.register(replacement_stdout) try: status, headers, body = wsgilib.intercept_output( environ, self.app) if status is None: </operation_context> </frame> <frame> <module> paste.wsgilib </module> <filename> /export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/wsgilib.py </filename> <line> 539 </line> <function> intercept_output </function> <operation> app_iter = application(environ, replacement_start_response) </operation> <operation_context> data.append(headers) return output.write app_iter = application(environ, replacement_start_response) if data[0] is None: return (None, None, app_iter) </operation_context> </frame> <frame> <module> paste.recursive </module> <filename> /export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/recursive.py </filename> <line> 80 </line> <function> __call__ </function> <operation> return self.application(environ, start_response) </operation> <operation_context> environ['paste.recursive.script_name'] = my_script_name try: return self.application(environ, start_response) except ForwardRequestException, e: middleware = CheckForRecursionMiddleware( </operation_context> </frame> <frame> <module> paste.httpexceptions </module> <filename> /export/home/galaxy/galaxy-dist/eggs/Paste-1.6-py2.4.egg/paste/httpexceptions.py </filename> <line> 632 </line> <function> __call__ </function> <operation> return self.application(environ, start_response) </operation> <operation_context> []).append(HTTPException) try: return self.application(environ, start_response) except HTTPException, exc: return exc(environ, start_response) </operation_context> </frame> <frame> <module> galaxy.web.framework.base </module> <filename> /export/home/galaxy/galaxy-dist/lib/galaxy/web/framework/base.py </filename> <line> 125 </line> <function> __call__ </function> <operation> body = method( trans, **kwargs ) </operation> <operation_context> kwargs.pop( '_', None ) try: body = method( trans, **kwargs ) except Exception, e: body = self.handle_controller_exception( e, trans, **kwargs ) </operation_context> </frame> <frame> <module> galaxy.web.controllers.tool_runner </module> <filename> /export/home/galaxy/galaxy-dist/lib/galaxy/web/controllers/tool_runner.py </filename> <line> 53 </line> <function> index </function> <operation> template, vars = tool.handle_input( trans, params.__dict__ ) </operation> <operation_context> # so make sure to create a new history if we've never had one before. history = trans.get_history( create=True ) template, vars = tool.handle_input( trans, params.__dict__ ) if len(params) > 0: trans.log_event( "Tool params: %s" % (str(params)), tool_id=tool_id ) </operation_context> </frame> <frame> <module> galaxy.tools </module> <filename> /export/home/galaxy/galaxy-dist/lib/galaxy/tools/__init__.py </filename> <line> 795 </line> <function> handle_input </function> <operation> _, out_data = self.execute( trans, incoming=params ) </operation> <operation_context> # If we've completed the last page we can execute the tool elif state.page == self.last_page: _, out_data = self.execute( trans, incoming=params ) try: assert isinstance( out_data, odict ) </operation_context> </frame> <frame> <module> galaxy.tools </module> <filename> /export/home/galaxy/galaxy-dist/lib/galaxy/tools/__init__.py </filename> <line> 1067 </line> <function> execute </function> <operation> return self.tool_action.execute( self, trans, incoming=incoming, set_output_hid=set_output_hid ) </operation> <operation_context> when run will build the tool's outputs, e.g. `DefaultToolAction`. """ return self.tool_action.execute( self, trans, incoming=incoming, set_output_hid=set_output_hid ) def params_to_strings( self, params, app ): </operation_context> </frame> <frame> <module> galaxy.tools.actions.upload </module> <filename> /export/home/galaxy/galaxy-dist/lib/galaxy/tools/actions/upload.py </filename> <line> 18 </line> <function> execute </function> <operation> uploaded_datasets = upload_common.get_uploaded_datasets( trans, incoming, precreated_datasets, dataset_upload_inputs ) </operation> <operation_context> precreated_datasets = upload_common.get_precreated_datasets( trans, incoming, trans.app.model.HistoryDatasetAssociation ) incoming = upload_common.persist_uploads( incoming ) uploaded_datasets = upload_common.get_uploaded_datasets( trans, incoming, precreated_datasets, dataset_upload_inputs ) upload_common.cleanup_unused_precreated_datasets( precreated_datasets ) </operation_context> </frame> <frame> <module> galaxy.tools.actions.upload_common </module> <filename> /export/home/galaxy/galaxy-dist/lib/galaxy/tools/actions/upload_common.py </filename> <line> 214 </line> <function> get_uploaded_datasets </function> <operation> uploaded_datasets.extend( dataset_upload_input.get_uploaded_datasets( trans, params ) ) </operation> <operation_context> uploaded_datasets = [] for dataset_upload_input in dataset_upload_inputs: uploaded_datasets.extend( dataset_upload_input.get_uploaded_datasets( trans, params ) ) for uploaded_dataset in uploaded_datasets: data = get_precreated_dataset( precreated_datasets, uploaded_dataset.name ) </operation_context> </frame> <frame> <module> galaxy.tools.parameters.grouping </module> <filename> /export/home/galaxy/galaxy-dist/lib/galaxy/tools/parameters/grouping.py </filename> <line> 301 </line> <function> get_uploaded_datasets </function> <operation> dataset.space_to_tab = file_bunch.space_to_tab </operation> <operation_context> writable_files_offset = 1 dataset.primary_file = file_bunch.path dataset.space_to_tab = file_bunch.space_to_tab dataset.precreated_name = file_bunch.precreated_name dataset.name = file_bunch.precreated_name </operation_context> </frame> </stack> <exception> <type> AttributeError </type> <value> 'Bunch' object has no attribute 'space_to_tab' </value> </exception> </traceback> Thanks and Regards, Amit Modi ------ End of Forwarded Message ----------------------------------------- Confidentiality Notice: The following mail message, including any attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. The recipient is responsible to maintain the confidentiality of this information and to use the information only for authorized purposes. If you are not the intended recipient (or authorized to receive information for the intended recipient), you are hereby notified that any review, use, disclosure, distribution, copying, printing, or action taken in reliance on the contents of this e-mail is strictly prohibited. If you have received this communication in error, please notify us immediately by reply e-mail and destroy all copies of the original message. Thank you.