def METHOD_NAME(operation):
    """
    Workaround for docstrings to work for operations in a sane way.
    Docstrings can only be specified for modules, classes, and functions. Hence,
    the docstring for an Operation is static as defined by the Operation class.
    To make the docstring for an Operation invocation work correctly, it has
    to be masqueraded as a function. The docstring will then be attached to the
    function which works quite nicely. Example in REPL:
    >> petstore = SwaggerClient.from_url('http://url_to_petstore/')
    >> pet = petstore.pet
    >> help(pet.getPetById)
    Help on function getPetById in module bravado_core.resource:
    getPetById(**kwargs)
        [GET] Find pet by ID
        Returns a pet when ID < 10.  ID > 10 or non-integers will simulate API error conditions  # noqa
        :param petId: ID of pet that needs to be fetched
        :type petId: integer
        :returns: 200: successful operation
        :rtype: #/definitions/Pet
        :returns: 400: Invalid ID supplied
        :returns: 404: Pet not found
    :param operation: :class:`Operation`
    :return: callable that executes the operation
    """
    def wrapper(**kwargs):
        return operation(**kwargs)
    # TODO: make docstring lazy by using 'docstring_property'
    wrapper.__doc__ = create_operation_docstring(operation)
    wrapper.__name__ = str(operation.operation_id)
    return wrapper