danni / django-postgres-composite-types

Postgres composite types support for Django
BSD 3-Clause "New" or "Revised" License
51 stars 13 forks source link

psycopg 3.x support #33

Open jleclanche opened 1 month ago

jleclanche commented 1 month ago

Django 4.2+ support psycopg (which is psycopg 3.x). If psycopg2 is installed this creates weird conflicts such as TypeError: Connection.cursor() got an unexpected keyword argument 'cursor_factory'.

This library should support psycopg 3.x to give recent versions of django proper support.

jleclanche commented 1 month ago

With that said, this may become irrelevant soon, as we're getting some movement on it in django core.

https://forum.djangoproject.com/t/postgres-composite-types/32667/2

Paging @csirmazbendeguz in case you haven't seen this library.

csirmazbendeguz commented 1 month ago

Hey @jleclanche, thanks for the ping!

I agree this would be a nice addition to Django 👍

The project I'm working on right now is composite primary keys, it's not related to Postgres composite types.

Sorry for the confusion it's my bad for derailing that forum discussion.

jleclanche commented 1 month ago

@csirmazbendeguz I noticed yeah -- I'm highlighting this as I believe the original ticket talks about composite fields, not composite PKs. Either way discussion seems to mix itself up so might as well link things back.