def localhost_exception(self): return self.login_user is None and self.login_password is None \ and LooseVersion(PyMongoVersion) >= LooseVersion('3.0') and self.database == "admin"