Fix multiple execution of python do ... end blocks

Only run the `python do ... end` loop once even if
multiple `depends_on :python => 'module-name'` are
present.