
In Train we will switch to use py37 for tests. There is a breaking change between Python 3.6 and 3.7 that is making it an error to raise a StopIteration exception from a function or generator(https://www.python.org/dev/peps/pep-0479/). So we need to fix it in code. Change-Id: I003be4193944bc4176768c488f2f71b58fcbd58d Closes-Bug: #1837856 Story: #2005924 Task: #34258