bare excepts
Robert Collins
robertc at robertcollins.net
Tue Jan 3 05:17:06 GMT 2006
What do you guys think of a test for bare excepts? I just spent ~ 30
minutes tracking down a bug that was hidden by:
try:
path = self._basis_inventory_name(old_revision)
path = self.branch._rel_controlfilename(path)
self.branch._transport.delete(path)
except:
pass
I'd be happy to extend my code-practices tests to check for:
except:
except Exception[ ,].*
What do you think? (They are persistent little buggers, keep coming
back.)
Rob
--
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060103/9b7f6f9b/attachment.pgp
More information about the bazaar
mailing list