human
I wrote the below code

    if ((not isinstance(request_type, basestring)) and ((not isinstance(request_type, type)) or (not issubclass(request_type, messages.Message)) or (request_type is messages.Message))):
        raise TypeError('Must    provide    message    class    for    request-type.        Found    %s', request_type)
    if ((not isinstance(response_type, basestring)) and ((not isinstance(response_type, type)) or (not issubclass(response_type, messages.Message)) or (response_type is messages.Message))):
        raise TypeError('Must    provide    message    class    for    response-type.        Found    %s', response_type)
    def remote_method_wrapper(method):
        "Decorator    used    to    wrap    method.\n\n                Args:\n                        method:    Original    method    being    wrapped.\n\n                Returns:\n                        'invoke_remote_method'    function    responsible    for    actual    invocation.\n                        This    invocation    function    instance    is    assigned    an    attribute    'remote'\n                        which    contains    information    about    the    remote    method:\n                                request_type:    Expected    request    type    for    remote    method.\n                                response_type:    Response    type    returned    from    remote    method.\n\n                Raises:\n                        TypeError:    If    request_type    or    response_type    is    not    a    subclass    of    Message\n                                or    is    the    Message    class    itself.\n                "
        def invoke_remote_method(service_instance, request):
            "Function    used    to    replace    original    method.\n\n                        Invoke    wrapped    remote    method.        Checks    to    ensure    that    request    and\n                        response    objects    are    the    correct    types.\n\n                        Does    not    check    whether    messages    are   ...

What's a good function header?
assistant
#Here's a good function header.

def method(request_type=message_types.VoidMessage, response_type=message_types.VoidMessage):