Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
saramsey committed Apr 17, 2024
1 parent 96dbc42 commit 8dfee21
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion code/ARAX/test/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,10 @@ def pytest_sessionstart(session):
# Refresh KP info cache if it hasn't been updated in more than an hour
kp_info_cacher = KPInfoCacher()
cache_exists = os.path.exists(kp_info_cacher.smart_api_and_meta_map_cache)
cache_is_stale = time.time() - os.path.getmtime(kp_info_cacher.smart_api_and_meta_map_cache) > 3600
if cache_exists:
cache_is_stale = time.time() - os.path.getmtime(kp_info_cacher.smart_api_and_meta_map_cache) > 3600
else:
cache_is_stale = True
if cache_exists and not cache_is_stale:
print(f"KP info cache is up to date.")
else:
Expand Down

0 comments on commit 8dfee21

Please sign in to comment.