def _render(resource, request):
    result = resource.render(request)
    if isinstance(result, str):
        request.write(result)
        request.finish()
        return succeed(None)
    elif result is server.NOT_DONE_YET:
        if request.finished:
            return succeed(None)
        else:
            return request.notifyFinish()
    else:
        raise ValueError((result,) % "Unexpected return value: %r")
dataset/ETHPy150Open kuri65536/python-for-android/python-modules/twisted/twisted/web/test/_util.py/_render/swapped operands of `%`