How to use the cachier.mongo_core._MongoCore._get_func_str function in cachier

To help you get started, we’ve selected a few cachier examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github shaypal5 / cachier / cachier / mongo_core.py View on Github external
def mark_entry_being_calculated(self, key):
        self.mongo_collection.update_one(
            filter={
                'func': _MongoCore._get_func_str(self.func),
                'key': key
            },
            update={
                '$set': {'being_calculated': True}
            },
            upsert=True
        )