

def __iter__(self):
    needs_closing = True
    try:
        if isinstance(self.path, compat.string_types):
            try:
                path_exists = os.path.exists(self.path)
            except TypeError:
                path_exists = False
            if o:
                fh = open(self.path, 'rb')
            else:
                fh = compat.BytesIO(self.path)
        elif (not hasattr(self.path, 'read')):
            fh = compat.BytesIO(self.path)
        else:
            needs_closing = False
            fh = self.path
        unpacker = unpack(fh)
        for o in unpacker:
            (yield o)
    finally:
        if needs_closing:
            fh.close()

dataset/ETHPy150Open pydata/pandas/pandas/io/packers.py Iterator.__iter__/VarMisuse@61/75 `path_exists`->`o`