pep8 compliance fixes

Almost all of this is simple indentation or line continuation fixes, there's one change (see inline comments) that is a combination of readability and making something more pythonic.

Signed-off-by: Michael McCracken <mike.mccracken@canonical.com>