def validate_json(value):
    try:
        json.loads(value)
    except:
        raise ValidationError(_('Ivalid JSON syntax'))
Validates a JSON snippet.
dataset/ETHPy150Open django-erp/django-erp/djangoerp/core/models.py/validate_json