PyQt 文件错误处理的各种方法 记录博文 第一种 错误处理 error = None fh = None try: # open file and read data except (IOError, OSError) as e: error = e finally: if fh is