jpadilla / django-rest-framework-jwt

JSON Web Token Authentication support for Django REST Framework
http://jpadilla.github.io/django-rest-framework-jwt/
MIT License
3.19k stars 649 forks source link

is_valid() should raise exception #386

Open bendavis78 opened 6 years ago

bendavis78 commented 6 years ago

The call to serializer.is_valid() in the view should raise an exception. In DRF, most is_valid calls are written as serializer.is_valid(raise_exception=True). This allows custom error handlers to be used via the EXCEPTION_HANDLER setting.

blueyed commented 6 years ago

See https://github.com/GetBlimp/django-rest-framework-jwt/pull/374.