You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I see this error in the django admin in the constance section.
TypeError at /admin/constance/config/
from_db_value() missing 1 required positional argument: 'context'
Steps to reproduce
First I see all the constants in the admin with the default values setted, I see in the DB and there is no data in the constance_config table. Until here is all normal I think that is the default behavior.
Second I press save without modify any constant and all the constants are saved in the DB, after this action I can't see the admin again and this error is raised:
TypeError at /admin/constance/config/
from_db_value() missing 1 required positional argument: 'context'
System configuration
Django version: 3.1.4
Python version: 3.8
Django-Constance version: 2.8.0
The text was updated successfully, but these errors were encountered:
Actually, the problem only appears with django-picklefield versions prior to 2.0 after which the "context" argument was removed from the from_db_value field method. This ensures compatibility with Django 2.0 and upper versions.
So the solution is to upgrade django-picklefield 2.0 and higher.
Actually, the problem only appears with django-picklefield versions prior to 2.0 after which the "context" argument was removed from the from_db_value field method. This ensures compatibility with Django 2.0 and upper versions.
So the solution is to upgrade django-picklefield 2.0 and higher.
totally, I upgrade django-picklefield to the last version and it works! thanks!
Describe the problem
Im using DB backend(mysql:5.7.22).
I see this error in the django admin in the constance section.
Steps to reproduce
First I see all the constants in the admin with the default values setted, I see in the DB and there is no data in the
constance_config
table. Until here is all normal I think that is the default behavior.Second I press save without modify any constant and all the constants are saved in the DB, after this action I can't see the admin again and this error is raised:
TypeError at /admin/constance/config/
from_db_value() missing 1 required positional argument: 'context'
System configuration
The text was updated successfully, but these errors were encountered: