#34435: JSONField with string default raises fields.E010 warning.
--------------------------------------+------------------------------------
     Reporter:  Tobias Krönke         |                    Owner:  stimver
         Type:  Bug                   |                   Status:  assigned
    Component:  Core (System checks)  |                  Version:  4.1
     Severity:  Normal                |               Resolution:
     Keywords:                        |             Triage Stage:  Accepted
    Has patch:  0                     |      Needs documentation:  0
  Needs tests:  0                     |  Patch needs improvement:  0
Easy pickings:  0                     |                    UI/UX:  0
--------------------------------------+------------------------------------

Comment (by Tobias Krönke):

 Replying to [comment:5 stimver]:
 > Can you suggest what changes should be done?

 That's a good question, because python offers no simple check a la
 `ismutable(x)`. It would be easy to just do a check like `isinstance(x,
 (bool, int, float, tuple, str, frozenset))`, if you can live with the
 "danger" of users sub-classing those types and making them mutable. But I
 guess those can't be helped with this check.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/34435#comment:6>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/010701878e9f5b3d-04254845-8c15-493d-ae52-30c55de25c69-000000%40eu-central-1.amazonses.com.

Reply via email to