MCPcopy Create free account
hub / github.com/omkarcloud/botasaurus / refresh

Method refresh

botasaurus/botasaurus_storage.py:36–44  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

34 self.refresh()
35
36 def refresh(self):
37 self.json_path = get_cache_file_path()
38 self.json_data = {}
39
40 if not os.path.isfile(self.json_path):
41 self.commit_to_disk()
42
43 with open(self.json_path, "r") as json_file:
44 self.json_data = json.load(json_file)
45
46 def commit_to_disk(self):
47 with open(self.json_path, "w") as json_file:

Callers 1

__init__Method · 0.95

Calls 3

commit_to_diskMethod · 0.95
get_cache_file_pathFunction · 0.70
loadMethod · 0.45

Tested by

no test coverage detected