diff --git a/k4FWCore/scripts/k4run b/k4FWCore/scripts/k4run index 92802c74..9427ef86 100755 --- a/k4FWCore/scripts/k4run +++ b/k4FWCore/scripts/k4run @@ -27,8 +27,9 @@ def load_file(file): def add_arguments(parser, app_mgr): - configurables = app_mgr.allConfigurables.values() - for conf in configurables: + # length increases when properties of an algorithm with tools are inspected + # see https://github.com/key4hep/k4FWCore/pull/138 + for conf in tuple(app_mgr.allConfigurables.values()): # skip public tools and the applicationmgr itself if "ToolSvc" in conf.name() or "ApplicationMgr" in conf.name(): continue