langsmith.utils.LangSmithRetry#

class langsmith.utils.LangSmithRetry(total: bool | int | None = 10, connect: int | None = None, read: int | None = None, redirect: bool | int | None = None, status: int | None = None, other: int | None = None, allowed_methods: Collection[str] | None = frozenset({'DELETE', 'GET', 'HEAD', 'OPTIONS', 'PUT', 'TRACE'}), status_forcelist: Collection[int] | None = None, backoff_factor: float = 0, backoff_max: float = 120, raise_on_redirect: bool = True, raise_on_status: bool = True, history: tuple[urllib3.util.retry.RequestHistory, ...] | None = None, respect_retry_after_header: bool = True, remove_headers_on_redirect: Collection[str] = frozenset({'Authorization', 'Cookie', 'Proxy-Authorization'}), backoff_jitter: float = 0.0)[source]#

Wrapper to filter logs with this name.

Parameters:
  • total (bool | int | None) –

  • connect (int | None) –

  • read (int | None) –

  • redirect (bool | int | None) –

  • status (int | None) –

  • other (int | None) –

  • allowed_methods (Collection[str] | None) –

  • status_forcelist (Collection[int] | None) –

  • backoff_factor (float) –

  • backoff_max (float) –

  • raise_on_redirect (bool) –

  • raise_on_status (bool) –

  • history (tuple[RequestHistory, ...] | None) –

  • respect_retry_after_header (bool) –

  • remove_headers_on_redirect (Collection[str]) –

  • backoff_jitter (float) –