Re: [bitpim-cvs-checkins] SF.net SVN: bitpim: [3702] trunk/bitpim/src/phones/com_sanyomedia.py
Roger Binns <[email protected]>
| Newsgroups | gmane.comp.mobile.bitpim.devel |
|---|---|
| Message-ID | <[email protected]> |
[email protected] wrote: > + try: > + res=self.sendpbcommand(req, self.protocolclass.sanyonumfilesresponse) > + except: > + self.log("Skipping directory "+`idir`) It is generally considered good Python practise to catch the explicit exceptions you care about (in this case BrewNoSuchDirectoryException). Otherwise the code above will mask out other exceptions (permission denied, timeouts etc). Roger ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV