diff --git a/docs/examples/asyncio_examples.ipynb b/docs/examples/asyncio_examples.ipynb index f8869708..b3160ae5 100644 --- a/docs/examples/asyncio_examples.ipynb +++ b/docs/examples/asyncio_examples.ipynb @@ -333,7 +333,7 @@ "metadata": {}, "source": [ "## Connecting to Valkey instances by specifying a URL scheme.\n", - "Parameters are passed to the following schems, as parameters to the url scheme.\n", + "Parameters are passed to the following schemes, as parameters to the url scheme.\n", "\n", "Three URL schemes are supported:\n", "\n", diff --git a/docs/examples/connection_examples.ipynb b/docs/examples/connection_examples.ipynb index 48347d6e..a88c446f 100644 --- a/docs/examples/connection_examples.ipynb +++ b/docs/examples/connection_examples.ipynb @@ -349,7 +349,7 @@ "metadata": {}, "source": [ "## Connecting to Valkey instances by specifying a URL scheme.\n", - "Parameters are passed to the following schems, as parameters to the url scheme.\n", + "Parameters are passed to the following schemes, as parameters to the url scheme.\n", "\n", "Three URL schemes are supported:\n", "\n", diff --git a/docs/examples/pipeline_examples.ipynb b/docs/examples/pipeline_examples.ipynb index c513a2fe..cd9e81b8 100644 --- a/docs/examples/pipeline_examples.ipynb +++ b/docs/examples/pipeline_examples.ipynb @@ -123,7 +123,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "The responses of the three commands are stored in a list. In the above example, the two first boolean indicates that the `set` commands were successful and the last element of the list is the result of the `get(\"a\")` comand." + "The responses of the three commands are stored in a list. In the above example, the two first boolean indicates that the `set` commands were successful and the last element of the list is the result of the `get(\"a\")` command." ] }, { @@ -132,7 +132,7 @@ "source": [ "## Chained call\n", "\n", - "The same result as above can be obtained in one line of code by chaining the opperations." + "The same result as above can be obtained in one line of code by chaining the operations." ] }, { @@ -162,7 +162,7 @@ "source": [ "## Performance comparison\n", "\n", - "Using pipelines can improve performance, for more informations, see [Valkey documentation about pipelining](https://valkey.io/docs/manual/pipelining/). Here is a simple comparison test of performance between basic and pipelined commands (we simply increment a value and measure the time taken by both method)." + "Using pipelines can improve performance, for more information, see [Valkey documentation about pipelining](https://valkey.io/docs/manual/pipelining/). Here is a simple comparison test of performance between basic and pipelined commands (we simply increment a value and measure the time taken by both method)." ] }, { diff --git a/docs/examples/set_and_get_examples.ipynb b/docs/examples/set_and_get_examples.ipynb index a96d2ac0..f4ce969f 100644 --- a/docs/examples/set_and_get_examples.ipynb +++ b/docs/examples/set_and_get_examples.ipynb @@ -139,7 +139,7 @@ } ], "source": [ - "r.set(\"full_name\", \"overridee!\")" + "r.set(\"full_name\", \"override!\")" ] }, { diff --git a/docs/examples/timeseries_examples.ipynb b/docs/examples/timeseries_examples.ipynb index 9effd68a..eb4cbd42 100644 --- a/docs/examples/timeseries_examples.ipynb +++ b/docs/examples/timeseries_examples.ipynb @@ -300,7 +300,7 @@ "source": [ "### Get the last sample matching specific label\n", "\n", - "Get the last sample that matches \"label1=1\", see [Valkey documentation](https://valkey.io/commands/ts.mget/) to see the posible filter values." + "Get the last sample that matches \"label1=1\", see [Valkey documentation](https://valkey.io/commands/ts.mget/) to see the possible filter values." ] }, { @@ -521,7 +521,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "For more informations about duplicate policies, see [Valkey documentation](https://valkey.io/commands/ts.add/)." + "For more information about duplicate policies, see [Valkey documentation](https://valkey.io/commands/ts.add/)." ] }, { diff --git a/tests/test_asyncio/test_search.py b/tests/test_asyncio/test_search.py index 20c9799f..554521ec 100644 --- a/tests/test_asyncio/test_search.py +++ b/tests/test_asyncio/test_search.py @@ -485,7 +485,7 @@ async def test_example(decoded_r: valkey.Valkey): "doc1", mapping={ "title": "RediSearch", - "body": "RediSearch impements a search engine on top of valkey", + "body": "RediSearch implements a search engine on top of valkey", }, ) @@ -1121,7 +1121,7 @@ async def test_aggregations_groupby(decoded_r: valkey.Valkey): "search", mapping={ "title": "RediSearch", - "body": "RediSearch impements a search engine on top of valkey", + "body": "RediSearch implements a search engine on top of valkey", "parent": "valkey", "random_num": 10, }, diff --git a/tests/test_search.py b/tests/test_search.py index 7e119058..b4193152 100644 --- a/tests/test_search.py +++ b/tests/test_search.py @@ -459,7 +459,7 @@ def test_example(client): "doc1", mapping={ "title": "RediSearch", - "body": "RediSearch impements a search engine on top of valkey", + "body": "RediSearch implements a search engine on top of valkey", }, ) @@ -1026,7 +1026,7 @@ def test_aggregations_groupby(client): "search", mapping={ "title": "RediSearch", - "body": "RediSearch impements a search engine on top of valkey", + "body": "RediSearch implements a search engine on top of valkey", "parent": "valkey", "random_num": 10, }, diff --git a/valkey/_parsers/commands.py b/valkey/_parsers/commands.py index 0f4409e4..ee64a1cd 100644 --- a/valkey/_parsers/commands.py +++ b/valkey/_parsers/commands.py @@ -101,7 +101,7 @@ def get_keys(self, valkey_conn, *args): cmd_name_split = cmd_name.split() cmd_name = cmd_name_split[0] if cmd_name in self.commands: - # save the splitted command to args + # save the split command to args args = cmd_name_split + list(args[1:]) else: # We'll try to reinitialize the commands cache, if the engine @@ -153,8 +153,8 @@ def _get_moveable_keys(self, valkey_conn, *args): So, don't use this function with EVAL or EVALSHA. """ - # The command name should be splitted into separate arguments, - # e.g. 'MEMORY USAGE' will be splitted into ['MEMORY', 'USAGE'] + # The command name should be split into separate arguments, + # e.g. 'MEMORY USAGE' will be split into ['MEMORY', 'USAGE'] pieces = args[0].split() + list(args[1:]) try: keys = valkey_conn.execute_command("COMMAND GETKEYS", *pieces) @@ -223,7 +223,7 @@ async def get_keys(self, *args: Any) -> Optional[Tuple[str, ...]]: cmd_name_split = cmd_name.split() cmd_name = cmd_name_split[0] if cmd_name in self.commands: - # save the splitted command to args + # save the split command to args args = cmd_name_split + list(args[1:]) else: # We'll try to reinitialize the commands cache, if the engine diff --git a/valkey/_parsers/helpers.py b/valkey/_parsers/helpers.py index 67557044..45016988 100644 --- a/valkey/_parsers/helpers.py +++ b/valkey/_parsers/helpers.py @@ -499,7 +499,7 @@ def parse_geosearch_generic(response, **options): """ try: if options["store"] or options["store_dist"]: - # `store` and `store_dist` cant be combined + # `store` and `store_dist` can't be combined # with other command arguments. # relevant to 'GEORADIUS' and 'GEORADIUSBYMEMBER' return response diff --git a/valkey/commands/core.py b/valkey/commands/core.py index 80a71be6..03b96717 100644 --- a/valkey/commands/core.py +++ b/valkey/commands/core.py @@ -706,7 +706,7 @@ def client_setname(self, name: str, **kwargs) -> ResponseT: def client_setinfo(self, attr: str, value: str, **kwargs) -> ResponseT: """ Sets the current connection library name or version - For mor information see https://valkey.io/commands/client-setinfo + For more information see https://valkey.io/commands/client-setinfo """ return self.execute_command("CLIENT SETINFO", attr, value, **kwargs) @@ -5651,7 +5651,7 @@ def _georadiusgeneric( raise DataError("GEORADIUS invalid sort") if kwargs["store"] and kwargs["store_dist"]: - raise DataError("GEORADIUS store and store_dist cant be set together") + raise DataError("GEORADIUS store and store_dist can't be set together") if kwargs["store"]: pieces.extend([b"STORE", kwargs["store"]]) @@ -5801,7 +5801,7 @@ def _geosearchgeneric( if kwargs["member"]: if kwargs["longitude"] or kwargs["latitude"]: raise DataError( - "GEOSEARCH member and longitude or latitude cant be set together" + "GEOSEARCH member and longitude or latitude can't be set together" ) pieces.extend([b"FROMMEMBER", kwargs["member"]]) if kwargs["longitude"] is not None and kwargs["latitude"] is not None: @@ -5818,7 +5818,7 @@ def _geosearchgeneric( if kwargs["radius"]: if kwargs["width"] or kwargs["height"]: raise DataError( - "GEOSEARCH radius and width or height cant be set together" + "GEOSEARCH radius and width or height can't be set together" ) pieces.extend([b"BYRADIUS", kwargs["radius"], kwargs["unit"]]) if kwargs["width"] and kwargs["height"]: @@ -6061,7 +6061,7 @@ def function_list( ) -> Union[Awaitable[List], List]: """ Return information about the functions and libraries. - :param library: pecify a pattern for matching library names + :param library: specify a pattern for matching library names :param withcode: cause the server to include the libraries source implementation in the reply """ diff --git a/valkey/commands/helpers.py b/valkey/commands/helpers.py index 08790637..12089865 100644 --- a/valkey/commands/helpers.py +++ b/valkey/commands/helpers.py @@ -114,7 +114,7 @@ def random_string(length=10): def quote_string(v): """ RedisGraph strings must be quoted, - quote_string wraps given v with quotes incase + quote_string wraps given v with quotes in case v is a string. """