Created
August 30, 2017 05:01
-
-
Save mortymacs/b16bec8b09632cf8583106b243cbb693 to your computer and use it in GitHub Desktop.
Sample Code For Debug Situation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import inspect | |
| print("LINE NUMBER:{} {}".format(__file__, inspect.getframeinfo(inspect.currentframe()).lineno)) | |
| # __file__ : shows current file name | |
| # inspect.getframeinfo(inspect.currentframe()).lineno: shows current line number |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment