Skip to content

Commit

Permalink
Remove unused arguments and fix typing
Browse files Browse the repository at this point in the history
  • Loading branch information
schobbejak committed Aug 26, 2024
1 parent 356bc7e commit 7ad843a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions epochalyst/caching/cacher.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ class CacheArgs(TypedDict):


LoaderFunction = Callable[[str, Path, str, Any], Any]
StoreFunction = Callable[[str, Path, Any, str, Any], Any]


class Cacher(Logger):
Expand Down Expand Up @@ -283,7 +284,7 @@ def _store_cache(self, name: str, data: Any, cache_args: CacheArgs | None = None
output_data_type = cache_args["output_data_type"]
store_args = cache_args.get("store_args", {})

store_functions: Dict[str, LoaderFunction] = {
store_functions: Dict[str, StoreFunction] = {
".npy": self._store_npy,
".parquet": self._store_parquet,
".csv": self._store_csv,
Expand Down Expand Up @@ -355,7 +356,7 @@ def _store_npy_stack(self, name: str, storage_path: Path, data: Any, output_data
else:
raise ValueError("output_data_type must be dask_array")

def _store_pkl(self, name: str, storage_path: Path, data: Any, output_data_type: str, store_args: Any) -> None: # noqa: ANN401
def _store_pkl(self, name: str, storage_path: Path, data: Any, _output_data_type: str, store_args: Any) -> None: # noqa: ANN401
file_path = storage_path / f"{name}.pkl"
self.log_to_debug(f"Storing pickle file to {file_path}")
with open(file_path, "wb") as f:
Expand Down

0 comments on commit 7ad843a

Please sign in to comment.