def headers_size(request_or_reply):
    # XXX: this is not 100% correct, but should be a good approximation.
    size = 0
    for name, value in qt_header_items(request_or_reply):
        size += name.size() + 2 + value.size() + 2  # 2==len(": ")==len("\n\r")
    return size
Ensure passing None as function raises.
dataset/ETHPy150Open scrapinghub/splash/splash/har/qt.py/headers_size--crossover with--dataset/ETHPy150Open Workiva/furious/furious/tests/test_async.py/TestAsync.test_none_function