Code review comment for lp://staging/~jamesodhunt/ubiquity/bug-944191

Revision history for this message
Colin Watson (cjwatson) wrote :

The style in ubiquity is to check specifically for OSError, rather than for the more general EnvironmentError. Doing so is safe in this case; you aren't going to get anything else from os.mkdir.

I don't think you need to recheck os.path.isdir; simply having got EEXIST from os.mkdir implies that. I would just write this as 'if e.errno != errno.EEXIST'.

review: Needs Fixing

« Back to merge proposal