code: def login_data_valid(self):
          
          login_working = False
          try:
              with self._login(requests.Session()) as sess:
                  sess.get(self._logout_url)
          except self.LoginError:
              pass
          else:
              login_working = True
          return login_working
docs: Check for working login data.