From 7d9b23ac9aa3c7f8993a1db05feadcc1195ecf9a Mon Sep 17 00:00:00 2001 From: mvdbeek Date: Mon, 18 May 2026 17:16:00 +0200 Subject: [PATCH] tool_source_store: extract discover.py from scripts/tool_source/_discover.py Pure refactor: the conf walker now lives at ``lib/galaxy/tool_source_store/discover.py`` and is importable via ``from galaxy.tool_source_store.discover import discover_tools``. No sys.path injection needed for in-process callers (cold-start auto-populate, shed-install reroute, test driver in upcoming commits). ``populate_store.py`` updates its two import sites; behaviour unchanged. --- .../galaxy/tool_source_store/discover.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) rename scripts/tool_source/_discover.py => lib/galaxy/tool_source_store/discover.py (97%) diff --git a/scripts/tool_source/_discover.py b/lib/galaxy/tool_source_store/discover.py similarity index 97% rename from scripts/tool_source/_discover.py rename to lib/galaxy/tool_source_store/discover.py index cca35ee4f22..8e6af982ba8 100644 --- a/scripts/tool_source/_discover.py +++ b/lib/galaxy/tool_source_store/discover.py @@ -1,8 +1,11 @@ """ Tool discovery utilities. -Used by ``populate_store.py`` to walk Galaxy's tool configuration without -booting a full ToolBox. +Walks Galaxy's tool configuration files to enumerate every ```` referenced +from any tool_conf without booting a full ``ToolBox``. Used by the populator +(``galaxy.tool_source_store.populator``) and by callers that need to compare +on-disk confs against the indexed tool set (cold-start auto-populate, +``reset_shed_tools``). """ import logging