getting 401 for invalid token not 403

2018-02-06 Thread Hamed Salimian
Hi in documents you is mentioned *"By default this exception results in a response with the HTTP status code "401 Unauthenticated", but it may also result in a "403 Forbidden" response, depending on the authentication scheme in use."* I am using *token**authenticate *and getting 403 for invalid

Django REST framework Postgresql Heroku : Operational Error - 'FATAL too many connections for role “usename”'

2018-02-06 Thread Tomiwa Ademidun
I am running a web application using Django and Django Rest Framework on Heroku with a postgresql and redis datastore. I am on the free postgresql tier which is limited to 20 connections. This hasn't been an issue in the past, but recently I started using django channels 2.