Skip to content

Commit

Permalink
Hide unused labels, remove logging
Browse files Browse the repository at this point in the history
  • Loading branch information
hexylena committed Oct 30, 2020
1 parent fcdaeb8 commit 2c4f039
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/galaxy/tools/toolbox/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -510,7 +510,6 @@ def _load_tool_panel_edam(self):
t = term
else:
t = path[0]
print('HXR', tool_id, term, path, t)

if path[0].startswith('operation_'):
operations[t][tool_id] = (term, tool_id, key, val, val.name)
Expand Down Expand Up @@ -557,6 +556,9 @@ def _load_tool_panel_edam(self):
# 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

elem = etree.Element('label')
elem.attrib['text'] = self.edam[term]['label']
elem.attrib['id'] = term
Expand All @@ -568,6 +570,9 @@ def _load_tool_panel_edam(self):
self._integrated_section_by_tool[tool_id] = key, val_name

for term in sorted(topics.keys(), key=lambda x: self._sort_edam_key(x)):
if len(topics[term].keys()) == 0:
continue

elem = etree.Element('label')
elem.attrib['text'] = self.edam[term]['label']
elem.attrib['id'] = term
Expand Down

0 comments on commit 2c4f039

Please sign in to comment.