add warning msg

This commit is contained in:
Casper da Costa-Luis 2019-08-27 16:50:07 +01:00
parent a3477060f1
commit 6c5fb3bcdc
No known key found for this signature in database
GPG Key ID: 986B408043AE090D
1 changed files with 2 additions and 1 deletions

View File

@ -1027,8 +1027,9 @@ class tqdm(Comparable):
self.close()
except AttributeError:
# maybe eager thread cleanup upon external error
if exc_type is None:
if (exc_type, exc_value, traceback) == (None, None, None):
raise
warn("AttributeError ignored", TqdmWarning)
def __del__(self):
self.close()