Re: Verifying Variable value

2013-08-14 Thread Terry Reedy
On 8/14/2013 12:36 PM, Prasad, Ramit wrote: chandan kumar wrote: Is there a way to validate variable values while debugging any python code. In addition to pdb, I would imagine most Python IDEs would support debugging in this manner. Idle also has a debugger. It uses the same bdb base debu

RE: Verifying Variable value

2013-08-14 Thread Prasad, Ramit
chandan kumar wrote: > Hi , > > Is there a way to validate variable values while debugging any python > code.Run below example  in > debugging mode and i would like to know the value of c (I know print is an > option) with any other > option other than printing. > In C# or some other tools we c

Re: Verifying Variable value

2013-08-14 Thread Krishnan Shankar
You can even use logging module in python to validate the variable values. You can import the module and use any of the following levels in your program import logging logging.CRITICAL, logging.ERROR, logging.WARNING, logging.INFO, logging.DEBUG For more you can refer to, http://docs.python.or

Re: Verifying Variable value

2013-08-14 Thread Dave Angel
chandan kumar wrote: > Hi , > > Is there a way to validate variable values while debugging any python > code.Run below example  in debugging mode and i would like to know the value > of c (I know print is an option) with any other option other than printing. > In C# or some other tools we can v

Re: Verifying Variable value

2013-08-14 Thread Krishnan Shankar
Hi Chandan, Python has built-in module called pdb which can be used for debugging. Importing it in the right place will be like setting break point in code and will change the execution to debugging mode. We can use different debugging commands ((n)ext, (c)ontinue, (s)tep etc) to evaluate through