mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-06 04:04:25 +08:00
update init stubs for Redis and redis Connection (#4648)
This commit is contained in:
5
third_party/2and3/redis/client.pyi
vendored
5
third_party/2and3/redis/client.pyi
vendored
@@ -67,7 +67,12 @@ class Redis(object):
|
||||
ssl_certfile: Optional[Text] = ...,
|
||||
ssl_cert_reqs: Optional[Union[str, int]] = ...,
|
||||
ssl_ca_certs: Optional[Text] = ...,
|
||||
ssl_check_hostname: bool = ...,
|
||||
max_connections: Optional[int] = ...,
|
||||
single_connection_client: bool = ...,
|
||||
health_check_interval: float = ...,
|
||||
client_name: Optional[Text] = ...,
|
||||
username: Optional[Text] = ...,
|
||||
) -> None: ...
|
||||
def set_response_callback(self, command, callback): ...
|
||||
def pipeline(self, transaction: bool = ..., shard_hint: Any = ...) -> Pipeline: ...
|
||||
|
||||
34
third_party/2and3/redis/connection.pyi
vendored
34
third_party/2and3/redis/connection.pyi
vendored
@@ -1,4 +1,4 @@
|
||||
from typing import Any, Optional, Text
|
||||
from typing import Any, Mapping, Optional, Text, Union
|
||||
|
||||
ssl_available: Any
|
||||
hiredis_version: Any
|
||||
@@ -70,20 +70,24 @@ class Connection:
|
||||
decode_responses: Any
|
||||
def __init__(
|
||||
self,
|
||||
host=...,
|
||||
port=...,
|
||||
db=...,
|
||||
password=...,
|
||||
socket_timeout=...,
|
||||
socket_connect_timeout=...,
|
||||
socket_keepalive=...,
|
||||
socket_keepalive_options=...,
|
||||
retry_on_timeout=...,
|
||||
encoding=...,
|
||||
encoding_errors=...,
|
||||
decode_responses=...,
|
||||
parser_class=...,
|
||||
socket_read_size=...,
|
||||
host: Text = ...,
|
||||
port: int = ...,
|
||||
db: int = ...,
|
||||
password: Optional[Text] = ...,
|
||||
socket_timeout: Optional[float] = ...,
|
||||
socket_connect_timeout: Optional[float] = ...,
|
||||
socket_keepalive: bool = ...,
|
||||
socket_keepalive_options: Optional[Mapping[str, Union[int, str]]] = ...,
|
||||
socket_type: int = ...,
|
||||
retry_on_timeout: bool = ...,
|
||||
encoding: Text = ...,
|
||||
encoding_errors: Text = ...,
|
||||
decode_responses: bool = ...,
|
||||
parser_class: Optional[BaseParser] = ...,
|
||||
socket_read_size: int = ...,
|
||||
health_check_interval: int = ...,
|
||||
client_name: Optional[Text] = ...,
|
||||
username: Optional[Text] = ...,
|
||||
) -> None: ...
|
||||
def __del__(self): ...
|
||||
def register_connect_callback(self, callback): ...
|
||||
|
||||
Reference in New Issue
Block a user