Skip to content

Commit 4355695

Browse files
use lru_cache during tests
1 parent 80edce8 commit 4355695

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/helper.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
from __future__ import annotations
1010

11-
from functools import cache
11+
from functools import lru_cache
1212

1313
import numpy as np
1414
import xarray as xr
@@ -47,7 +47,7 @@ def is_3d_rmse_better(result, obsp, simp) -> bool:
4747
return (rmse_values_new_ds < rmse_values_old_ds).all()
4848

4949

50-
@cache
50+
@lru_cache(maxsize=None)
5151
def get_datasets(kind: str) -> tuple[xr.Dataset, xr.Dataset, xr.Dataset, xr.Dataset]:
5252
historical_time = xr.cftime_range(
5353
"1971-01-01",

0 commit comments

Comments
 (0)