chtd / psycopg2cffi

Port to cffi with some speed improvements
Other
177 stars 43 forks source link

JSONB support? #36

Closed rouge8 closed 9 years ago

rouge8 commented 9 years ago

Does psycopg2cffi have JSONB support? Psycopg2 added it in 2.5.4, but I'm not sure how the versions correspond.

lopuhin commented 9 years ago

No, there is no JSONB support in psycopg2cffi at the moment. I think this is the most important missing feature. I will be glad if you are willing to contribute it, or I will do it some day, maybe in the first half of May.

rouge8 commented 9 years ago

That's what I thought. Is there a general comparison to what's available in psycopg2?

On Monday, April 20, 2015, Konstantin Lopuhin notifications@github.com wrote:

No, there is no JSONB support in psycopg2cffi at the moment. I think this is the most important missing feature. I will be glad if you are willing to contribute it, or I will do it some day, maybe in the first half of May.

— Reply to this email directly or view it on GitHub https://github.com/chtd/psycopg2cffi/issues/36#issuecomment-94365046.

lopuhin commented 9 years ago

Feature-wise current release is on par with psycopg2 2.5 (thanks to Daniele Varrazzo https://github.com/chtd/psycopg2cffi/pull/10), and has no extra features beyond that.

tebanep commented 9 years ago

Any ETA for this? I think this is a great feature that can put python on par with "modern" web stacks: nodejs + mongodb ~ pypy3.3 + tornado(asyncio) + postgresql(jsonb).

Thanks for this awesome work!

lopuhin commented 9 years ago

Thank you! I think some time this summe, maybe june or july.

pmarti commented 9 years ago

:+1: please support jsonb

Natim commented 9 years ago

We are pending on this issue in order to add PyPy support for Cliquet and Kinto. (https://github.com/mozilla-services/cliquet/issues/325)

lopuhin commented 9 years ago

Cool :) I hope I will start this weekend, and will have a better estimate, and maybe something working.

Natim commented 9 years ago

Feel free to ask if you need help or can point us to something we can do to help.

lopuhin commented 9 years ago

Thank you for the support! In theory, it should be easy - just registering a new type, serialization/deserialization, and porting (mostly copying) tests from psycopg2. Moreover, there is psycopg2 code that already implements this feature. So, I hope there will be something to test soon.

Natim commented 9 years ago

Great thanks a lot :+1:

lopuhin commented 9 years ago

It turned out that psycopg2 implementation of jsonb support could be reused as-is, so I just merged jsonb support to master - tests pass, I'm going to run django 1.9 tests too to be sure. @Natim this is not on pypi yet, but if you can test on you side, this would be great! If all is well, I will put release to pypi on the weekend.

brouberol commented 9 years ago

On behalf of @Natim, I can tell you that our tests pass thanks to your merge. Thanks!

Natim commented 9 years ago

This is really great !!! Thanks a lot !

lopuhin commented 9 years ago

Great, thank you! Django 1.9 jsonb tests also pass, will release later today.

lopuhin commented 9 years ago

Release 2.7.1 to pypi

brouberol commented 9 years ago

Thanks again for being so reactive.

tebanep commented 9 years ago

Great news, thanks a lot!