Skip to content

Feature request: Support for psycopg2 cursors in _ex methods. #86

Description

@rkofman

The readme advertises that Chancy's psycopg3 dependency can be installed alongside psycopg2:

Minimal dependencies - Core functionality requires only psycopg3 - which can be installed side-by-side with psycopg2.

This is exciting because it allows usage on legacy projects that may have dependencies on old versions of sqlAlchemy and/or psycopg.

However: Chancy's _ex interfaces currently seem to require psycopg3 cursors -- which limits interactions from legacy code. I'm especially interested in: push_ex, push_many_ex, and sync_push_many_ex which would be used to support a key function: the ability to use Chancy as a transactional outbox (from legacy code).

For ease of compatibility on projects that currently use psycopg2, it may be useful to provide interfaces that can take a psycopg2 cursor optionally instead of a psycopg3 cursor.

I'm curious if there is interest in providing such a compatibility layer.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions