django-constance
django-constance copied to clipboard
Changing value type (for example int -> datetime.timedelta) does not invalidate value, stored in database
Describe the problem
Changing value type (for example int -> datetime.timedelta) does not invalidate value, stored in database
Steps to reproduce
- Create constance_config entry with
int
value - Modify value via admin interface
- Change default value in config to datetime.timedelta instance
- Try to get this value via
costance.<OUR_KEY_NAME>
- it will returnint
instead oftimedelta
System configuration
- Django version: 2.0.x
- Python version: 3.5
Django datamigrations for next version of project solve this issues. There is no robust way to migrate data between different types automatically.