Re-use logic from StrategyBase._load_included_file in StrategyModule.run for free and linear (#36470)

This improves include_role performance and recursion limits
This commit is contained in:
Matt Martz 2018-02-21 09:53:15 -06:00 committed by GitHub
parent 7a55fe99ef
commit 10fefc7156
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 18 additions and 11 deletions

View file

@ -324,8 +324,7 @@ class StrategyModule(StrategyBase):
# list of noop tasks, to make sure that they continue running in lock-step
try:
if included_file._is_role:
new_ir = included_file._task.copy()
new_ir.vars.update(included_file._args)
new_ir = self._copy_included_file(included_file)
new_blocks, handler_blocks = new_ir.get_block_list(
play=iterator._play,