code: def etag_stream(input_stream):
      
      array = [_sha1(block) for block in _file_iter(input_stream, _BLOCK_SIZE)]
      if len(array) == 0:
          array = [_sha1(b'')]
      if len(array) == 1:
          data = array[0]
          prefix = b'\x16'
      else:
          sha1_str = b('').join(array)
          data = _sha1(sha1_str)
          prefix = b'\x96'
      return urlsafe_base64_encode(prefix + data)
docs: 计算输入流的etag:
  
      etag规格参考 https://developer.qiniu.com/kodo/manual/1231/appendix#3
  
      Args:
          input_stream: 待计算etag的二进制流
  
      Returns:
          输入流的etag值