4

While working with Django Rest Framework, the Post and Delete requests were giving me 403 error. With no help from stack overflow, I decided in vain to check it with Firefox browser instead of Chrome.

IT FUCKING WORKS ON FIREFOX!! HOW THE FUCK??

Things like this are responsible for my mid life crisis.

Comments
  • 0
    What extensions do you have enabled on Chrome? Any ad-blocking or CORS extensions? I'll wait...
  • 0
    Chrome does weird stuff if you don't have a favicon in root. Not sure if that was ever changed.
  • 0
    If your local host name is one name (for example 'localhost') this can be quirky as well in chrome.
  • 0
    @korengali just AdBlocker. No help even after disabling it
  • 0
    @Theo20185 favicon can't be possibly the case for my API throwing 403 error
  • 0
    @kanduvisla nope. It's running on '127.0.0.1'. But we don't worry about that anymore after our great ancestor CGI went extinct . Do we?
  • 0
    Did you try actually removing adblocker? I've literally had this exact same problem because of it.
  • 0
    What do the chrome dev tools say in network response?
  • 1
    @korengali I tried pausing it and disabling it, didn't solve the problem. First it won't show anything but after fiddling around a bit, it gave me 400 error so I knew I was close. Actually I didn't pay much attention and gave different names for my model objects and serialized objects and thus was getting an error. It's resolved now 😇
  • 0
    @varundey good to hear!!
  • 0
    It works for me in Incognito mode but always throws a 403 when normal, even with all the extensions disabled. smh
  • 0
    @Mabdou My problem was that I was logged in with the default Django Admin. logging out solved the problem for me.
Add Comment