def make_error_response(self, cond):
if self.stanza_type == "<STR_LIT:error>":<EOL><INDENT>raise ValueError("<STR_LIT>"<EOL>"<STR_LIT>")<EOL><DEDENT>msg = Message(stanza_type = "<STR_LIT:error>", from_jid = self.to_jid,<EOL>to_jid = self.from_jid, stanza_id = self.stanza_id,<EOL>error_cond = cond,<EOL>subject = self._subject, body = self._body,<EOL>thread = self._thread)<EOL>if self._payload is None:<EOL><INDENT>self.decode_payload()<EOL><DEDENT>for payload in self._payload:<EOL><INDENT>msg.add_payload(payload.copy())<EOL><DEDENT>return msg<EOL>
Create error response for any non-error message stanza.

        :Parameters:
            - `cond`: error condition name, as defined in XMPP specification.

        :return: new message stanza with the same "id" as self, "from" and
            "to" attributes swapped, type="error" and containing <error />
            element plus payload of `self`.
        :returntype: `Message`