> > > - line 159: merge this if with the actual lookup in a try/except block > > > (and return if you catch a KeyError). > > > > Testing this condition prevents us from raising an exception. I thought > > code tended to perform faster if it didn't have to do exception > > handling. (This is the case for C++ and Java). I'm inclined to leave > > this as is. > > Okay. I think it's typically Pythonic to ask for forgivness rather than > permission, but I'm not sure what the actual performance implications are. > We haven't been terribly consistent here across the codebase; I'll leave it > up to you to make filelist more consistent or not.
Nor is it really clear that we have a performance sensitive code path. If it really is more Pythonic to wrap these things in exception handlers, I'll go ahead and do that. This just goes against the teachings of other OO programming languages, so I found that a little surprising. > > > - line 494: I'm not sure that TransferInterruptedException is really the > > > right name here. TransferTimedOutException, maybe? > > > > If the name annoys you, I can change it to something else. > > If you're going to use it for interruptions other than timeouts, keep it; > if it's just going to be timeouts (for the foreseeable future, at least) > then rename it. IMHO. As far as I can figure, this should just be for timeouts, at least for now. I'll go ahead and change this. -j _______________________________________________ pkg-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/pkg-discuss
