fdutils/files.py
def md5_checksum_stream(s, buffer_size=8192):
    """ calculate md5 for a stream in case of a large file that cannot be hold in memory

    :param s: stream
    :return:
    """
    import hashlib
    m = hashlib.md5()
    while True:
        data = s.read(buffer_size)
        if not data:
            break
        m.update(data)
    return m.hexdigest()
 calculate md5 for a stream in case of a large file that cannot be hold in memory

    :param s: stream
    :return:
    
calculate md5 for a stream in case of a large file that cannot be hold in memory
calculate md5 for a stream in case of a large file that cannot be hold in memory
def md5_checksum_stream(s, buffer_size=8192):
    import hashlib
    m = hashlib.md5()
    while True:
        data = s.read(buffer_size)
        if not data:
            break
        m.update(data)
    return m.hexdigest()
def md5_checksum_stream ( s , buffer_size = 8192 ) : import hashlib m = hashlib . md5 ( ) while True : data = s . read ( buffer_size ) if not data : break m . update ( data ) return m . hexdigest ( )
calculate md5 for a stream in case of a large file that cannot be hold in memory
calculate md5 for a stream in case of a large file that cannot be hold in memory
""" calculate md5 for a stream in case of a large file that cannot be hold in memory

    :param s: stream
    :return:
    """
None
s
None
buffer_size