def check_key ( self , key : str ) -> bool : keys = self . get_keys ( ) return key in keys
how to check if key exists in python
Checks if key exists in datastore . True if yes False if no .
def check_key(self, key: str) -> bool:
        """
        Checks if key exists in datastore. True if yes, False if no.

        :param: SHA512 hash key

        :return: whether or key not exists in datastore
        """
        keys = self.get_keys()
        return key in keys