Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!1.eu.feeder.erje.net!newsfeed.pionier.net.pl!feed.xsnews.nl!border03.ams.xsnews.nl!feeder04.ams.xsnews.nl!abp001.ams.xsnews.nl!frontend-F09-08.ams.news.kpn.nl From: Cecil Westerhof Newsgroups: comp.lang.python Subject: Re: Retrying to send message Organization: Decebal Computing References: <87egltht87.fsf@Equus.decebal.nl> <876174ix9n.fsf@Equus.decebal.nl> <556F4766.5090500@stoneleaf.us> X-Face: "(y8cC@tg_12{">GF'UXTW]FHI2wMiZNrnf'1EFQ&O#$m:f#O7+7}kR,v+Pti8=Vi/Z"g^?b"E X-Homepage: http://www.decebal.nl/ Date: Thu, 04 Jun 2015 07:13:23 +0200 Message-ID: <87r3psgioc.fsf@Equus.decebal.nl> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) Cancel-Lock: sha1:K/+10zghB/L35NTEyAC0dRrV+8k= MIME-Version: 1.0 Content-Type: text/plain Lines: 31 NNTP-Posting-Host: 81.207.62.244 X-Trace: 1433395793 news.kpn.nl 18976 81.207.62.244@kpn/81.207.62.244:42368 Xref: csiph.com comp.lang.python:92029 Op Thursday 4 Jun 2015 01:15 CEST schreef Ethan Furman: > On 06/03/2015 01:37 PM, Mark Lawrence wrote: >> On 03/06/2015 19:28, Ethan Furman wrote: >>> On 06/03/2015 09:15 AM, Cecil Westerhof wrote: >>> >>>> I kept the except. I like to see the message that went wrong. ;-) >>> >>> That's fine, but then add a `raise` after you print the error so >>> you can see the reason that message failed. >>> >> >> Why bother in the first place, especially when you're developing? >> Far easier to let the exception bubble up, or are we talking cross >> purposes? > > I think Cecil means he wants to see which twitter message failed to > send. The rest of us would like to also have the error itself > displayed. ;) Correct. I display the error in the function I call. I also quit the program in the function I call. Is the correct thing to do, but if someone just want to continue after displaying the error, that should be possible also. That is why I choose to implement it this way. I should produce some docstring. ;-) -- Cecil Westerhof Senior Software Engineer LinkedIn: http://www.linkedin.com/in/cecilwesterhof