Skip to content

Commit 8a1feb3

Browse files
authored
Fix Linting and Test Failures (#2191)
* force triggering pr pipeline * fix lint error * RedisJSON/RedisJSON#721 no longer clears strings or boolean scalars
1 parent 428510b commit 8a1feb3

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

redis/commands/search/commands.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ def dropindex(self, delete_documents=False):
167167
### Parameters:
168168
169169
- **delete_documents**: If `True`, all documents will be deleted.
170-
170+
171171
For more information see `FT.DROPINDEX <https://redis.io/commands/ft.dropindex>`_.
172172
""" # noqa
173173
keep_str = "" if delete_documents else "KEEPDOCS"

tests/test_asyncio/test_json.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -899,11 +899,12 @@ async def test_clear_dollar(modclient: redis.Redis):
899899
"nested3": {"a": {"baz": 50}},
900900
},
901901
)
902+
902903
# Test multi
903-
assert await modclient.json().clear("doc1", "$..a") == 4
904+
assert await modclient.json().clear("doc1", "$..a") == 3
904905

905906
assert await modclient.json().get("doc1", "$") == [
906-
{"nested1": {"a": {}}, "a": [], "nested2": {"a": ""}, "nested3": {"a": {}}}
907+
{"nested1": {"a": {}}, "a": [], "nested2": {"a": "claro"}, "nested3": {"a": {}}}
907908
]
908909

909910
# Test single

tests/test_json.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -893,7 +893,6 @@ def test_type_dollar(client):
893893

894894
@pytest.mark.redismod
895895
def test_clear_dollar(client):
896-
897896
client.json().set(
898897
"doc1",
899898
"$",
@@ -905,10 +904,10 @@ def test_clear_dollar(client):
905904
},
906905
)
907906
# Test multi
908-
assert client.json().clear("doc1", "$..a") == 4
907+
assert client.json().clear("doc1", "$..a") == 3
909908

910909
assert client.json().get("doc1", "$") == [
911-
{"nested1": {"a": {}}, "a": [], "nested2": {"a": ""}, "nested3": {"a": {}}}
910+
{"nested1": {"a": {}}, "a": [], "nested2": {"a": "claro"}, "nested3": {"a": {}}}
912911
]
913912

914913
# Test single

0 commit comments

Comments
 (0)