docs: def calc_remove(request, calc_id):
      """
      Remove the calculation id
      """
      # Only the owner can remove a job
      user = utils.get_user(request)
      try:
          message = logs.dbcmd('del_calc', calc_id, user)
      except dbapi.NotFound:
          return HttpResponseNotFound()
  
      if 'success' in message:
          return HttpResponse(content=json.dumps(message),
                              content_type=JSON, status=200)
      elif 'error' in message:
          logging.error(message['error'])
          return HttpResponse(content=json.dumps(message),
                              content_type=JSON, status=403)
      else:
          # This is an untrapped server error
          logging.error(message)
          return HttpResponse(content=message,
                              content_type='text/plain', status=500)