This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2017年06月26日 10:10 by louielu, last changed 2022年04月11日 14:58 by admin.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 2399 | open | louielu, 2017年06月26日 10:12 | |
| Messages (4) | |||
|---|---|---|---|
| msg296869 - (view) | Author: Louie Lu (louielu) * | Date: 2017年06月26日 10:10 | |
This propose to add *count* times on step and next instruction in pdb. step [count] next [count] User can use `next [count]` to run next *count* times, or `step [count]` to run step *count* times, until it countdown, or occure a breakpoint. Similar function has been implemented in gdb[1] before. [1]: https://sourceware.org/gdb/onlinedocs/gdb/Continuing-and-Stepping.html |
|||
| msg296871 - (view) | Author: STINNER Victor (vstinner) * (Python committer) | Date: 2017年06月26日 10:14 | |
@Xavier: Would you mind to review this enhancement? Thanks. |
|||
| msg296906 - (view) | Author: Xavier de Gaye (xdegaye) * (Python triager) | Date: 2017年06月26日 15:20 | |
Thanks for this PR Louie, adding count to the pdb commands is useful. With gdb a very common use case is to set a breakpoint where the code runs very frequently and when only interested in the N(th) execution of this code, to enter the breakpoint command list: (gdb) commands Type commands for breakpoint(s) 1, one per line. End with a line saying just "end". >silent >continue <N - 1> >end (gdb) PR 2399 does not handle this case for pdb: * The 'count' option for the 'continue' command is not implemented. * The implementation of the 'count' option for 'next' and 'step' does not handle breakpoint command lists (I think). IMO it is difficult to handle this option for breakpoint command lists directly in pdb.py, but it could be done in bdb.py, adding a keyword argument to set_continue() et al. |
|||
| msg296930 - (view) | Author: Raymond Hettinger (rhettinger) * (Python committer) | Date: 2017年06月26日 18:42 | |
FWIW, I've never needed this ever. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:58:48 | admin | set | github: 74946 |
| 2017年08月26日 19:29:59 | barry | set | nosy:
+ barry |
| 2017年06月26日 18:42:27 | rhettinger | set | nosy:
+ rhettinger messages: + msg296930 |
| 2017年06月26日 15:20:29 | xdegaye | set | messages: + msg296906 |
| 2017年06月26日 10:14:07 | vstinner | set | nosy:
+ xdegaye, vstinner messages: + msg296871 |
| 2017年06月26日 10:12:00 | louielu | set | pull_requests: + pull_request2446 |
| 2017年06月26日 10:10:13 | louielu | create | |