Skip to content

Commit

Permalink
Fix tool panel views for versionless tool ids
Browse files Browse the repository at this point in the history
  • Loading branch information
mvdbeek committed Oct 7, 2023
1 parent 11110c2 commit 612f1d6
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion lib/galaxy/tool_util/toolbox/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,12 @@ def __init__(self, toolbox: "AbstractToolBox"):

def has_tool(self, tool_id: str) -> bool:
toolbox = self.__toolbox
return tool_id in toolbox._tools_by_id or tool_id in toolbox._tools_by_old_id
# tool_id could be full guid, old tool id (no toolshed and version info) or versionless guid.
return (
tool_id in toolbox._tools_by_id
or tool_id in toolbox._tools_by_old_id
or bool(toolbox._lineage_map.lineage_map.get(tool_id))
)

def get_tool(self, tool_id: str):
return self.__toolbox.get_tool(tool_id)
Expand Down

0 comments on commit 612f1d6

Please sign in to comment.