BUG: invalid json on post should return 500 with a message, not nuke the server