valkey-glide 1.2.0rc14__cp311-cp311-macosx_11_0_arm64.whl → 2.2.3__cp311-cp311-macosx_11_0_arm64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. glide/__init__.py +169 -104
  2. glide/async_commands/cluster_commands.py +367 -172
  3. glide/async_commands/core.py +1808 -1026
  4. glide/async_commands/{server_modules/ft.py → ft.py} +91 -21
  5. glide/async_commands/{server_modules/glide_json.py → glide_json.py} +161 -146
  6. glide/async_commands/standalone_commands.py +204 -136
  7. glide/glide.cpython-311-darwin.so +0 -0
  8. glide/glide.pyi +26 -1
  9. glide/glide_client.py +355 -136
  10. glide/logger.py +34 -22
  11. glide/opentelemetry.py +185 -0
  12. glide_shared/__init__.py +330 -0
  13. glide_shared/commands/__init__.py +0 -0
  14. glide/async_commands/transaction.py → glide_shared/commands/batch.py +1845 -1059
  15. glide_shared/commands/batch_options.py +261 -0
  16. {glide/async_commands → glide_shared/commands}/bitmap.py +96 -86
  17. {glide/async_commands → glide_shared/commands}/command_args.py +7 -6
  18. glide_shared/commands/core_options.py +407 -0
  19. {glide/async_commands → glide_shared/commands}/server_modules/ft_options/ft_aggregate_options.py +18 -11
  20. {glide/async_commands → glide_shared/commands}/server_modules/ft_options/ft_create_options.py +27 -13
  21. {glide/async_commands → glide_shared/commands}/server_modules/ft_options/ft_profile_options.py +16 -11
  22. {glide/async_commands → glide_shared/commands}/server_modules/ft_options/ft_search_options.py +17 -9
  23. glide_shared/commands/server_modules/json_batch.py +820 -0
  24. glide_shared/commands/server_modules/json_options.py +93 -0
  25. {glide/async_commands → glide_shared/commands}/sorted_set.py +42 -32
  26. {glide/async_commands → glide_shared/commands}/stream.py +95 -88
  27. glide_shared/config.py +975 -0
  28. {glide → glide_shared}/constants.py +11 -7
  29. {glide → glide_shared}/exceptions.py +27 -1
  30. glide_shared/protobuf/command_request_pb2.py +56 -0
  31. glide_shared/protobuf/connection_request_pb2.py +56 -0
  32. {glide → glide_shared}/protobuf/response_pb2.py +6 -6
  33. {glide → glide_shared}/protobuf_codec.py +7 -6
  34. glide_shared/routes.py +161 -0
  35. valkey_glide-2.2.3.dist-info/METADATA +211 -0
  36. valkey_glide-2.2.3.dist-info/RECORD +40 -0
  37. {valkey_glide-1.2.0rc14.dist-info → valkey_glide-2.2.3.dist-info}/WHEEL +1 -1
  38. glide/config.py +0 -521
  39. glide/protobuf/command_request_pb2.py +0 -54
  40. glide/protobuf/command_request_pb2.pyi +0 -1161
  41. glide/protobuf/connection_request_pb2.py +0 -52
  42. glide/protobuf/connection_request_pb2.pyi +0 -287
  43. glide/protobuf/response_pb2.pyi +0 -101
  44. glide/routes.py +0 -114
  45. valkey_glide-1.2.0rc14.dist-info/METADATA +0 -122
  46. valkey_glide-1.2.0rc14.dist-info/RECORD +0 -36
  47. {glide/async_commands → glide_shared/commands}/server_modules/ft_options/ft_constants.py +0 -0
@@ -2,8 +2,10 @@
2
2
 
3
3
  from typing import List, Mapping, Optional
4
4
 
5
- from glide.async_commands.server_modules.ft_options.ft_constants import FtSearchKeywords
6
- from glide.constants import TEncodable
5
+ from glide_shared.commands.server_modules.ft_options.ft_constants import (
6
+ FtSearchKeywords,
7
+ )
8
+ from glide_shared.constants import TEncodable
7
9
 
8
10
 
9
11
  class FtSearchLimit:
@@ -49,7 +51,8 @@ class ReturnField:
49
51
  Initialize a new ReturnField instance.
50
52
 
51
53
  Args:
52
- field_identifier (TEncodable): The identifier for the field of the key that has to returned as a result of FT.SEARCH command.
54
+ field_identifier (TEncodable): The identifier for the field of the key that has to returned as a result of
55
+ FT.SEARCH command.
53
56
  alias (Optional[TEncodable]): The alias to override the name of the field in the FT.SEARCH result.
54
57
  """
55
58
  self.field_identifier = field_identifier
@@ -87,11 +90,16 @@ class FtSearchOptions:
87
90
  Initialize the FT.SEARCH optional fields.
88
91
 
89
92
  Args:
90
- return_fields (Optional[List[ReturnField]]): The fields of a key that are returned by FT.SEARCH command. See `ReturnField`.
91
- timeout (Optional[int]): This value overrides the timeout parameter of the module. The unit for the timout is in milliseconds.
92
- params (Optional[Mapping[TEncodable, TEncodable]]): Param key/value pairs that can be referenced from within the query expression.
93
- limit (Optional[FtSearchLimit]): This option provides pagination capability. Only the keys that satisfy the offset and count values are returned. See `FtSearchLimit`.
94
- count (Optional[bool]): This flag option suppresses returning the contents of keys. Only the number of keys is returned.
93
+ return_fields (Optional[List[ReturnField]]): The fields of a key that are returned by FT.SEARCH command.
94
+ See `ReturnField`.
95
+ timeout (Optional[int]): This value overrides the timeout parameter of the module.
96
+ The unit for the timout is in milliseconds.
97
+ params (Optional[Mapping[TEncodable, TEncodable]]): Param key/value pairs that can be referenced from within the
98
+ query expression.
99
+ limit (Optional[FtSearchLimit]): This option provides pagination capability. Only the keys that satisfy the offset
100
+ and count values are returned. See `FtSearchLimit`.
101
+ count (Optional[bool]): This flag option suppresses returning the contents of keys.
102
+ Only the number of keys is returned.
95
103
  """
96
104
  self.return_fields = return_fields
97
105
  self.timeout = timeout
@@ -120,7 +128,7 @@ class FtSearchOptions:
120
128
  args.append(str(self.timeout))
121
129
  if self.params:
122
130
  args.append(FtSearchKeywords.PARAMS)
123
- args.append(str(len(self.params)))
131
+ args.append(str(len(self.params) * 2))
124
132
  for name, value in self.params.items():
125
133
  args.append(name)
126
134
  args.append(value)