bugfix; several minor fixes for
* pep8
* migration from ts to labs

Change-Id: I766b4ef92fb36b6ba755481117e62be61bfba58b