localwiki / localwiki-backend-server

Primary LocalWiki backend server environment
GNU General Public License v2.0
48 stars 16 forks source link

Deleting a page via API gets 500 response. KeyError at /api/v4/pages/17/ #9

Open philipn opened 9 years ago

philipn commented 9 years ago

From @sethvincent on August 7, 2014 17:41

But it still successfully deletes the page.

Here's the test I'm running in the js client that gets the 500 response: https://github.com/codeforseattle/javascript-localwiki-client/blob/master/test.js#L70

Copied from original issue: localwiki/localwiki#708

philipn commented 9 years ago

Thanks for catching this! It seems it was an issue with django-honeypot and empty Content-Type headers. I've fixed django-honeypot and added a test case for delete(), which wasn't there before.

If you pull the hub branch you should see this fix and should be able to verify a fix there, but I won't be able to push it to production for a few days (I'm in a remote area of the island of Borneo with unreliable 3G service :P)

philipn commented 9 years ago

@sethvincent Updated server with latest hub branch, so let me know if you're seeing this there right now (if you're not testing this locally).