bpo-30022: Get rid of using EnvironmentError and IOError (except test… (#1051)
This commit is contained in:
@@ -579,7 +579,7 @@ if __name__ == '__main__':
|
||||
if self.stats:
|
||||
try:
|
||||
self.stats.add(line)
|
||||
except IOError as e:
|
||||
except OSError as e:
|
||||
print("Failed to load statistics for %s: %s" % (line, e), file=self.stream)
|
||||
else:
|
||||
print("No statistics object is loaded.", file=self.stream)
|
||||
|
||||
Reference in New Issue
Block a user