Request authentication token from keystone before if connection to ApiSe...

...rver fails
pep8 issues. please fix