Re: Facing issue with Python loggin logger for printing object value
On 12/29/2012 03:50 PM, Morten Engvoldsen wrote:
> Hi Dave,
> It is able to log the message with:
> logger.debug("value of payment_line is " +repr(payment_line))
> The output is:
> value of payment_line is 
> So it means payment_line is an empty list, so may be it could be
reason it's not able to enter into the loop since the message in the for
loop is not logged in the log file.
> Thanks and good night.. :)
You can easily test how iteration over empty list works:
>>> for x in l: print(x)
i.e. nothing is printed because loop runs 0 times.
Lark's Tongue Guide to Python: http://lightbird.net/larks/
|All times are GMT. The time now is 07:59 AM.|
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.