Skip to content

Commit

Permalink
Re-add uncategorized
Browse files Browse the repository at this point in the history
  • Loading branch information
hexylena committed Oct 30, 2020
1 parent 2c4f039 commit 6b49ed4
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions lib/galaxy/tools/toolbox/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -528,7 +528,7 @@ def _load_tool_panel_edam(self):
if tool_id in self._tools_by_id:
for term, label in self._get_edam_sec(section_val):
if term == 'uncategorized':
uncategorized.append((tool_id, key, val, val.name))
uncategorized.append((tool_id, key, section_val, val.name))
else:
for path in self.edam[term]['path']:
if len(path) == 1:
Expand All @@ -551,10 +551,6 @@ def _load_tool_panel_edam(self):
log.debug(f"Loaded workflow: {workflow_id} {workflow.name}")
log.debug("Loading tool panel finished %s", execution_timer)

# print(operations.keys())
# print([self._sort_edam_key(x) for x in operations.keys()])
# print(sorted(operations.keys(), lambda x: self._sort_edam_key(x)))

for term in sorted(operations.keys(), key=lambda x: self._sort_edam_key(x)):
if len(operations[term].keys()) == 0:
continue
Expand Down Expand Up @@ -584,9 +580,10 @@ def _load_tool_panel_edam(self):
self._integrated_section_by_tool[tool_id] = key, val_name

section = self._get_section('uncategorized', 'Uncategorized')
# for (tool_id, key, val, val_name) in uncategorized:
# self.__add_tool_to_tool_panel(val, section, section=True)
# self._integrated_section_by_tool[tool_id] = key, val_name
for (tool_id, key, val, val_name) in uncategorized:
print(tool_id, key, val, val_name)
self.__add_tool_to_tool_panel(val, section, section=True)
self._integrated_section_by_tool[tool_id] = key, val_name

def _sort_edam_key(self, x):
if x in ('operation_0004', 'topic_0003'):
Expand Down

0 comments on commit 6b49ed4

Please sign in to comment.