adamchainz / gargoyle

:radio_button: Feature switches in Django
Apache License 2.0
109 stars 19 forks source link

Support native Postgres JSON fields #128

Closed codeadict closed 7 years ago

codeadict commented 7 years ago

If using PostgreSQL as a database, the package django-jsonfield shouldn't be installed and use the native Django fields for Postgres. Perhaps try to use native ones by default and raise and exception saying you need to install django-jsonfield in order to store data. Can install this one for unit tests.

adamchainz commented 7 years ago

This is very hard/impossible to do because Django Models should have single model classes, especially for migrations. Even if you could invent a way, I don't think I'd like to see it complicating this package. Also I don't see the advantage, gargoyle does not need to query attributes inside the JSON.

Sorry, closing.