summaryrefslogtreecommitdiff
path: root/redis/commands/json/commands.py
diff options
context:
space:
mode:
authorAarni Koskela <akx@iki.fi>2022-10-30 13:31:03 +0200
committerGitHub <noreply@github.com>2022-10-30 13:31:03 +0200
commit842634e7fddeb32ba20aab0dacf557a958a4b00b (patch)
tree8b4a69503a650ab723963fc84f2357c7968054eb /redis/commands/json/commands.py
parent9cf8e028863c79904d9536465e5844184109d209 (diff)
downloadredis-py-842634e7fddeb32ba20aab0dacf557a958a4b00b.tar.gz
Remove `deprecated` dependency (#2386)
No need for an external library just for 5 annotations.
Diffstat (limited to 'redis/commands/json/commands.py')
-rw-r--r--redis/commands/json/commands.py11
1 files changed, 5 insertions, 6 deletions
diff --git a/redis/commands/json/commands.py b/redis/commands/json/commands.py
index 9391c2a..7fd4039 100644
--- a/redis/commands/json/commands.py
+++ b/redis/commands/json/commands.py
@@ -2,9 +2,8 @@ import os
from json import JSONDecodeError, loads
from typing import Dict, List, Optional, Union
-from deprecated import deprecated
-
from redis.exceptions import DataError
+from redis.utils import deprecated_function
from ._util import JsonType
from .decoders import decode_dict_keys
@@ -137,7 +136,7 @@ class JSONCommands:
"JSON.NUMINCRBY", name, str(path), self._encode(number)
)
- @deprecated(version="4.0.0", reason="deprecated since redisjson 1.0.0")
+ @deprecated_function(version="4.0.0", reason="deprecated since redisjson 1.0.0")
def nummultby(self, name: str, path: str, number: int) -> str:
"""Multiply the numeric (integer or floating point) JSON value under
``path`` at key ``name`` with the provided ``number``.
@@ -368,19 +367,19 @@ class JSONCommands:
pieces.append(str(path))
return self.execute_command("JSON.DEBUG", *pieces)
- @deprecated(
+ @deprecated_function(
version="4.0.0", reason="redisjson-py supported this, call get directly."
)
def jsonget(self, *args, **kwargs):
return self.get(*args, **kwargs)
- @deprecated(
+ @deprecated_function(
version="4.0.0", reason="redisjson-py supported this, call get directly."
)
def jsonmget(self, *args, **kwargs):
return self.mget(*args, **kwargs)
- @deprecated(
+ @deprecated_function(
version="4.0.0", reason="redisjson-py supported this, call get directly."
)
def jsonset(self, *args, **kwargs):