خرید بک لینک

Vote count: 0

I have a source code of 500Mb having more than 5K of files written in Python. Sometimes I get exception messages but no idea about the line number and file name of exception. Even sometimes exceptions are not seen on terminal unlit I specifically use pdb.

Is there any convenient way to get to know about the exception location ?

Thanks.

asked 8 mins ago

1 Answer

Vote count: 0

Try the traceback module: https://docs.python.org/3/library/traceback.html

It contains the tb_lineno function which takes the traceback as a parameter, retuing the line number of the exception.

answered 1 min ago

برچسب: نویسنده: استخدام کار تاريخ: دوشنبه 17 خرداد 1395 ساعت: 21:33

صفحه بندی