U
U
un1t2015-07-14 21:47:00
Django
un1t, 2015-07-14 21:47:00

Django live settings - what to choose?

Once used django-preferences - not bad thing but there were glitches.
Looked for similar things - django-dynamic-preferences looks good.
Here are some more alternatives:
https://www.djangopackages.com/grids/g/live-setting/
Who uses what for similar purposes? What do you recommend?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
sim3x, 2015-07-15
@un1t

https://pypi.python.org/pypi/django-constance
but IMO it's better to have a key-val model for this, write tests and not depend on someone else's solution

INSTALLED_APPS += (
'constance',
'constance.backends.database', )

CONSTANCE_BACKEND = 'constance.backends.database.DatabaseBackend'

CACHES = {
    'default': {
        'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
    }
}

CONSTANCE_DATABASE_CACHE_BACKEND = 'default'

CONSTANCE_CONFIG = {
'FOO': ('bar', 'FOO should be bar'),
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question