[issue15335] IDLE - debugger steps through run.py internals
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.5 -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15335 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15335] IDLE - debugger steps through run.py internals
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 2.7, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15335 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15335] IDLE - debugger steps through run.py internals
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: -serhiy.storchaka versions: +Python 3.4 -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15335 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15335] IDLE - debugger steps through run.py internals
Roger Serwy roger.se...@gmail.com added the comment: I suggest to add a decorator @Debugger.internal for all methods that the debugger should not step into. It should set a function attribute that the debugger then checks for. The decorator idea may work. I'll need to see how to make it work with the existing debugging code. OTOH, I fail to see the problem. Stepping through the standard library may be useful, and if you don't want to do that, you can choose to step over still. I'm not sure why stepping through an IDE's internals is desirable when debugging one's own program. As it stands, the _RPCFile patch represents an unintended behavior change to the debugger. That needs to be either corrected or documented. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15335 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15335] IDLE - debugger steps through run.py internals
New submission from Roger Serwy roger.se...@gmail.com: The IDLE debugger steps through the internals of _RPCFile. To reproduce this bug, create a new .py file with a few print statements, enable the debugger, and then run the file. Stepping through the print statement enters into _RPCFile. -- components: IDLE messages: 165321 nosy: loewis, serwy, storchaka, terry.reedy priority: normal severity: normal status: open title: IDLE - debugger steps through run.py internals type: behavior versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15335 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15335] IDLE - debugger steps through run.py internals
Roger Serwy roger.se...@gmail.com added the comment: Debugger.py has a method in_rpc_code which ultimately prevents stepping though code from rpc.py. (Presently an external file named rpc.py can not be debugged using IDLE.) Adding run.py to the check would prevent run.py from being stepped, but it applies to *any* run.py in the filename string: elif frame.f_code.co_filename.count('run.py'): return True Or, you could check the name: elif frame.f_globals.get('__name__','') == 'idlelib.run': return True Any additional logic for in_rpc_code can slow down code performance when debugging. Another possible approach is to move the _RPCFile into rpc.py add additional methods to RPCHandler, like get_remote_stdout_proxy. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15335 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15335] IDLE - debugger steps through run.py internals
Martin v. Löwis mar...@v.loewis.de added the comment: I suggest to add a decorator @Debugger.internal for all methods that the debugger should not step into. It should set a function attribute that the debugger then checks for. OTOH, I fail to see the problem. Stepping through the standard library may be useful, and if you don't want to do that, you can choose to step over still. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15335 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com