MCPcopy
hub / github.com/alibaba/freeline / load_json_cache

Function load_json_cache

freeline_core/utils.py:133–143  ·  view source on GitHub ↗
(fpath)

Source from the content-addressed store, hash-verified

131
132
133def load_json_cache(fpath):
134 cache = {}
135 if not os.path.exists(fpath):
136 pass
137 if os.path.isfile(fpath):
138 try:
139 with open(fpath, 'r') as fp:
140 cache = json.load(fp)
141 except Exception:
142 pass
143 return cache
144
145
146def write_json_cache(fpath, cache):

Callers 12

executeMethod · 0.90
executeMethod · 0.90
load_path_mapMethod · 0.90
get_project_infoFunction · 0.90
executeMethod · 0.90
run_apt_onlyMethod · 0.90
run_retrolambdaMethod · 0.90
read_freeline_configFunction · 0.90

Calls 1

loadMethod · 0.80

Tested by

no test coverage detected