@@ -517,6 +517,7 @@ def client_list(
517517 """
518518 Returns a list of currently connected clients.
519519 If type of client specified, only that type will be returned.
520+
520521 :param _type: optional. one of the client types (normal, master,
521522 replica, pubsub)
522523 :param client_id: optional. a list of client ids
@@ -559,16 +560,17 @@ def client_reply(
559560 ) -> ResponseT :
560561 """
561562 Enable and disable redis server replies.
563+
562564 ``reply`` Must be ON OFF or SKIP,
563- ON - The default most with server replies to commands
564- OFF - Disable server responses to commands
565- SKIP - Skip the response of the immediately following command.
565+ ON - The default most with server replies to commands
566+ OFF - Disable server responses to commands
567+ SKIP - Skip the response of the immediately following command.
566568
567569 Note: When setting OFF or SKIP replies, you will need a client object
568570 with a timeout specified in seconds, and will need to catch the
569571 TimeoutError.
570- The test_client_reply unit test illustrates this, and
571- conftest.py has a client with a timeout.
572+ The test_client_reply unit test illustrates this, and
573+ conftest.py has a client with a timeout.
572574
573575 See https://redis.io/commands/client-reply
574576 """
@@ -724,19 +726,21 @@ def client_unblock(
724726
725727 def client_pause (self , timeout : int , all : bool = True , ** kwargs ) -> ResponseT :
726728 """
727- Suspend all the Redis clients for the specified amount of time
728- :param timeout: milliseconds to pause clients
729+ Suspend all the Redis clients for the specified amount of time.
730+
729731
730732 For more information see https://redis.io/commands/client-pause
733+
734+ :param timeout: milliseconds to pause clients
731735 :param all: If true (default) all client commands are blocked.
732- otherwise, clients are only blocked if they attempt to execute
733- a write command.
734- For the WRITE mode, some commands have special behavior:
735- EVAL/EVALSHA: Will block client for all scripts.
736- PUBLISH: Will block client.
737- PFCOUNT: Will block client.
738- WAIT: Acknowledgments will be delayed, so this command will
739- appear blocked.
736+ otherwise, clients are only blocked if they attempt to execute
737+ a write command.
738+ For the WRITE mode, some commands have special behavior:
739+ EVAL/EVALSHA: Will block client for all scripts.
740+ PUBLISH: Will block client.
741+ PFCOUNT: Will block client.
742+ WAIT: Acknowledgments will be delayed, so this command will
743+ appear blocked.
740744 """
741745 args = ["CLIENT PAUSE" , str (timeout )]
742746 if not isinstance (timeout , int ):
@@ -1215,9 +1219,11 @@ def quit(self, **kwargs) -> ResponseT:
12151219 def replicaof (self , * args , ** kwargs ) -> ResponseT :
12161220 """
12171221 Update the replication settings of a redis replica, on the fly.
1222+
12181223 Examples of valid arguments include:
1219- NO ONE (set no replication)
1220- host port (set to the host and port of a redis server)
1224+
1225+ NO ONE (set no replication)
1226+ host port (set to the host and port of a redis server)
12211227
12221228 For more information see https://redis.io/commands/replicaof
12231229 """
@@ -3603,27 +3609,37 @@ def xclaim(
36033609 ) -> ResponseT :
36043610 """
36053611 Changes the ownership of a pending message.
3612+
36063613 name: name of the stream.
3614+
36073615 groupname: name of the consumer group.
3616+
36083617 consumername: name of a consumer that claims the message.
3618+
36093619 min_idle_time: filter messages that were idle less than this amount of
36103620 milliseconds
3621+
36113622 message_ids: non-empty list or tuple of message IDs to claim
3623+
36123624 idle: optional. Set the idle time (last time it was delivered) of the
3613- message in ms
3625+ message in ms
3626+
36143627 time: optional integer. This is the same as idle but instead of a
3615- relative amount of milliseconds, it sets the idle time to a specific
3616- Unix time (in milliseconds).
3628+ relative amount of milliseconds, it sets the idle time to a specific
3629+ Unix time (in milliseconds).
3630+
36173631 retrycount: optional integer. set the retry counter to the specified
3618- value. This counter is incremented every time a message is delivered
3619- again.
3632+ value. This counter is incremented every time a message is delivered
3633+ again.
3634+
36203635 force: optional boolean, false by default. Creates the pending message
3621- entry in the PEL even if certain specified IDs are not already in the
3622- PEL assigned to a different client.
3636+ entry in the PEL even if certain specified IDs are not already in the
3637+ PEL assigned to a different client.
3638+
36233639 justid: optional boolean, false by default. Return just an array of IDs
3624- of messages successfully claimed, without returning the actual message
3640+ of messages successfully claimed, without returning the actual message
36253641
3626- For more information see https://redis.io/commands/xclaim
3642+ For more information see https://redis.io/commands/xclaim
36273643 """
36283644 if not isinstance (min_idle_time , int ) or min_idle_time < 0 :
36293645 raise DataError ("XCLAIM min_idle_time must be a non negative integer" )
@@ -3875,11 +3891,15 @@ def xrange(
38753891 ) -> ResponseT :
38763892 """
38773893 Read stream values within an interval.
3894+
38783895 name: name of the stream.
3896+
38793897 start: first stream ID. defaults to '-',
38803898 meaning the earliest available.
3899+
38813900 finish: last stream ID. defaults to '+',
38823901 meaning the latest available.
3902+
38833903 count: if set, only return this many items, beginning with the
38843904 earliest available.
38853905
@@ -3902,10 +3922,13 @@ def xread(
39023922 ) -> ResponseT :
39033923 """
39043924 Block and monitor multiple streams for new data.
3925+
39053926 streams: a dict of stream names to stream IDs, where
39063927 IDs indicate the last ID already seen.
3928+
39073929 count: if set, only return this many items, beginning with the
39083930 earliest available.
3931+
39093932 block: number of milliseconds to wait, if nothing already present.
39103933
39113934 For more information see https://redis.io/commands/xread
@@ -3940,12 +3963,17 @@ def xreadgroup(
39403963 ) -> ResponseT :
39413964 """
39423965 Read from a stream via a consumer group.
3966+
39433967 groupname: name of the consumer group.
3968+
39443969 consumername: name of the requesting consumer.
3970+
39453971 streams: a dict of stream names to stream IDs, where
39463972 IDs indicate the last ID already seen.
3973+
39473974 count: if set, only return this many items, beginning with the
39483975 earliest available.
3976+
39493977 block: number of milliseconds to wait, if nothing already present.
39503978 noack: do not add messages to the PEL
39513979
@@ -3980,11 +4008,15 @@ def xrevrange(
39804008 ) -> ResponseT :
39814009 """
39824010 Read stream values within an interval, in reverse order.
4011+
39834012 name: name of the stream
4013+
39844014 start: first stream ID. defaults to '+',
39854015 meaning the latest available.
4016+
39864017 finish: last stream ID. defaults to '-',
39874018 meaning the earliest available.
4019+
39884020 count: if set, only return this many items, beginning with the
39894021 latest available.
39904022
@@ -5301,8 +5333,10 @@ def script_flush(
53015333 self , sync_type : Union [Literal ["SYNC" ], Literal ["ASYNC" ]] = None
53025334 ) -> ResponseT :
53035335 """Flush all scripts from the script cache.
5336+
53045337 ``sync_type`` is by default SYNC (synchronous) but it can also be
53055338 ASYNC.
5339+
53065340 For more information see https://redis.io/commands/script-flush
53075341 """
53085342
@@ -5615,11 +5649,14 @@ def geosearch(
56155649 area specified by a given shape. This command extends the
56165650 GEORADIUS command, so in addition to searching within circular
56175651 areas, it supports searching within rectangular areas.
5652+
56185653 This command should be used in place of the deprecated
56195654 GEORADIUS and GEORADIUSBYMEMBER commands.
5655+
56205656 ``member`` Use the position of the given existing
56215657 member in the sorted set. Can't be given with ``longitude``
56225658 and ``latitude``.
5659+
56235660 ``longitude`` and ``latitude`` Use the position given by
56245661 this coordinates. Can't be given with ``member``
56255662 ``radius`` Similar to GEORADIUS, search inside circular
@@ -5628,17 +5665,23 @@ def geosearch(
56285665 ``height`` and ``width`` Search inside an axis-aligned
56295666 rectangle, determined by the given height and width.
56305667 Can't be given with ``radius``
5668+
56315669 ``unit`` must be one of the following : m, km, mi, ft.
56325670 `m` for meters (the default value), `km` for kilometers,
56335671 `mi` for miles and `ft` for feet.
5672+
56345673 ``sort`` indicates to return the places in a sorted way,
56355674 ASC for nearest to furthest and DESC for furthest to nearest.
5675+
56365676 ``count`` limit the results to the first count matching items.
5677+
56375678 ``any`` is set to True, the command will return as soon as
56385679 enough matches are found. Can't be provided without ``count``
5680+
56395681 ``withdist`` indicates to return the distances of each place.
56405682 ``withcoord`` indicates to return the latitude and longitude of
56415683 each place.
5684+
56425685 ``withhash`` indicates to return the geohash string of each place.
56435686
56445687 For more information see https://redis.io/commands/geosearch
0 commit comments