code: def _log_json_error(self, body, exc):
          '''Log a :exc:`json.JSONDecodeError`, converting to
          GraphQL's ``{"data": null, "errors": [{"message": str(exc)...}]}``
  
          :param body: the string with JSON document.
          :type body: str
  
          :param exc: the :exc:`json.JSONDecodeError`
          :type exc: :exc:`json.JSONDecodeError`
  
          :return: GraphQL-compliant dict with keys ``data`` and ``errors``.
          :rtype: dict
          '''
          self.logger.error('could not decode JSON response: %s', exc)
          return {'data': None, 'errors': [{
              'message': str(exc),
              'exception': exc,
              'body': body,
          }]f _log_json_error(self, body, exc):
          '''Log a :exc:`json.JSONDecodeError`, converting to
          GraphQL's ``{"data": null, "errors": [{"message": str(exc)...}]}``
  
          :param body: the string with JSON document.
          :type body: str
  
          :param exc: the :exc:`json.JSONDecodeError`
          :type exc: :exc:`json.JSONDecodeError`
  
          :return: GraphQL-compliant dict with keys ``data`` and ``errors``.
          :rtype: dict
          '''
          self.logger.error('could not decode JSON response: %s', exc)
          return {'data': None, 'errors': [{
              'message': str(exc),
              'exception': exc,
              'body': body,
          }]}
docs: Log a :exc:`json.JSONDecodeError`, converting to
          GraphQL's ``{"data": null, "errors": [{"message": str(exc)...}]}``
  
          :param body: the string with JSON document.
          :type body: str
  
          :param exc: the :exc:`json.JSONDecodeError`
          :type exc: :exc:`json.JSONDecodeError`
  
          :return: GraphQL-compliant dict with keys ``data`` and ``errors``.
          :rtype: dict