Skip to content

Commit

Permalink
one more #nosec
Browse files Browse the repository at this point in the history
  • Loading branch information
lene committed Aug 22, 2023
1 parent f8801c5 commit 98046ff
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions duplicate_images/hash_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def load(self) -> None:

def dump(self) -> None:
with self.store_path.open('wb') as file:
pickle.dump(self.values, file)
pickle.dump(self.values, file) # nosec


class JSONHashStore(FileHashStore):
Expand All @@ -87,7 +87,7 @@ def dump(self) -> None:


def checked_load(file: IO, load: Callable[[IO], Cache]) -> Cache:
values = load(file) # noqa: S301
values = load(file) # nosec
if not isinstance(values, dict):
raise ValueError(f'Not a dict: {values}')
bad_keys = [key for key in values.keys() if not isinstance(key, Path)]
Expand Down

0 comments on commit 98046ff

Please sign in to comment.