invalidate ideas (untested) and some pep8