try except block for hipchat connection