mirror of
https://github.com/long2ice/fastapi-cache.git
synced 2026-03-25 04:57:54 +00:00
Add flake8-bandit linting (#156)
The linter has been used in the past, so most assertions for these were already there but needed to be updated to use `noqa: S` instead of `nosec: B` annotations.
This commit is contained in:
@@ -14,7 +14,7 @@ def default_key_builder(
|
||||
args: Tuple[Any, ...],
|
||||
kwargs: Dict[str, Any],
|
||||
) -> str:
|
||||
cache_key = hashlib.md5( # nosec:B303
|
||||
cache_key = hashlib.md5( # noqa: S324
|
||||
f"{func.__module__}:{func.__name__}:{args}:{kwargs}".encode()
|
||||
).hexdigest()
|
||||
return f"{namespace}:{cache_key}"
|
||||
|
||||
Reference in New Issue
Block a user