parameters: (file: BinaryIO)
docstring: Generator function to read from a file BLOCK_SIZE bytes.
  
    Args:
      file: The file object to read from.
  
    Yields:
      Returns up to BLOCK_SIZE bytes from the file.
docstring_summary: Generator function to read from a file BLOCK_SIZE bytes.
docstring_tokens: Generator function to read from a file BLOCK_SIZE bytes .
function: def read_as_blocks(file: BinaryIO):
    """Generator function to read from a file BLOCK_SIZE bytes.
  
    Args:
      file: The file object to read from.
  
    Yields:
      Returns up to BLOCK_SIZE bytes from the file.
    """
    while True:
      data = file.read(BLOCK_SIZE)
      # If file was opened in rawIO, EOF is only reached when b'' is returned.
      # pylint: disable=g-explicit-bool-comparison
      if data == b'':
        break
      # pylint: enable=g-explicit-bool-comparison
      yield data
function_tokens: def read_as_blocks ( file : BinaryIO ) : while True : data = file . read ( BLOCK_SIZE ) # If file was opened in rawIO, EOF is only reached when b'' is returned. # pylint: disable=g-explicit-bool-comparison if data == b'' : break # pylint: enable=g-explicit-bool-comparison yield data