Skip to content

parity(client): add db.retry option to disable transient PostgREST retries [from supabase-js] #1561

Description

@grdsdev

Warning

Auto-generated parity issue — may be a false positive.

This issue was created automatically by /sync-sdk-parity from a heuristic
analysis of recent supabase-js commits. The tooling has limited insight
into language-specific idioms and may have:

  • misidentified a JS-only change as cross-language relevant,
  • missed an existing implementation in this SDK under a different name,
  • or proposed an API shape that doesn't fit this language's conventions.

It is the SDK author's responsibility to validate the need before
implementing.
If this change does not apply to this SDK, please close the
issue with a short note explaining why.


SDK Parity: Python implementation needed

A change was made in supabase-js that needs to be implemented in this repository for SDK parity.

Reference Implementation (supabase-js)

What Changed

New boolean client option db.retry (default true) forwarded to the underlying PostgREST client, letting callers disable automatic retries for transient (network/5xx) PostgREST errors.

Code Reference

this.rest = new PostgrestClient(...)
// SupabaseClientOptions.db.retry?: boolean — defaults to true

Implementation Guidance

Expected API Surface

supabase-py's client_options.py has postgrest_client_timeout but no retry toggle per prior investigation. Add a postgrest_client_retry (or similarly named, matching existing option naming style) boolean option to ClientOptions, defaulting to True, and forward it to the underlying postgrest-py client's retry behavior.

Key Behaviors to Match

Boolean option on client construction, default True (preserves current behavior) · When False, transient/5xx PostgREST errors are not automatically retried

Acceptance Criteria

  • Feature/fix implemented matching supabase-js behavior
  • Public API follows Python naming conventions (snake_case) and idioms
  • Unit tests cover happy path and edge cases
  • Documentation updated
  • No breaking changes to existing API (or clearly documented)

Context

  • supabase-js version: v3.0.0-next.29
  • Parity tracking: This issue was auto-generated by SDK parity analysis

Generated with Claude Code /sync-sdk-parity

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions