def readfrom(fpath, aslines=False, errors='<STR_LIT:replace>', verbose=None):
if verbose:<EOL><INDENT>print('<STR_LIT>' % (fpath,))<EOL><DEDENT>if not exists(fpath):<EOL><INDENT>raise IOError('<STR_LIT>' % (fpath,))<EOL><DEDENT>with open(fpath, '<STR_LIT:rb>') as file:<EOL><INDENT>if aslines:<EOL><INDENT>text = [line.decode('<STR_LIT:utf8>', errors=errors)<EOL>for line in file.readlines()]<EOL>if sys.platform.startswith('<STR_LIT:win32>'):  <EOL><INDENT>text = [<EOL>line[:-<NUM_LIT:2>] + '<STR_LIT:\n>' if line.endswith('<STR_LIT:\r\n>') else line<EOL>for line in text<EOL>]<EOL><DEDENT><DEDENT>else:<EOL><INDENT>text = file.read().decode('<STR_LIT:utf8>', errors=errors)<EOL><DEDENT><DEDENT>return text<EOL>
Reads (utf8) text from a file.

Args:
    fpath (PathLike): file path
    aslines (bool): if True returns list of lines
    verbose (bool): verbosity flag

Returns:
    str: text from fpath (this is unicode)