(self, body, exc)
return {'data': None, 'errors': [{
            'message': str(exc),
            'exception': exc,
            'body': body,
        }]}
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
Log a :exc:`json.JSONDecodeError`, converting to
        GraphQL's ``{"data": null, "errors": [{"message": str(exc)...}]}``
Log a : exc : json . JSONDecodeError converting to GraphQL s { data : null errors : [ { message : str ( exc ) ... } ] }
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,
        }]}
def _log_json_error ( self , body , exc ) : self . logger . error ( 'could not decode JSON response: %s' , exc ) return { 'data' : None , 'errors' : [ { 'message' : str ( exc ) , 'exception' : exc , 'body' : body , } ] }