Skip to content

Conversation

@ktowen
Copy link
Contributor

@ktowen ktowen commented Aug 28, 2025

This PR adds two new commands to ignore (and unignore) specific modules when navigating frames in the IPython debugger, similar to how the debugger already skips hidden frames. It will work with all the commands that implies moving between frames like up, down, step and next.
It is useful when you don't want the debugger to enter third party code.

Closes #1665

@ktowen ktowen marked this pull request as draft August 28, 2025 11:37
@ktowen ktowen force-pushed the debugger-ignore-modules branch from f4c9cdb to 5f599d3 Compare August 28, 2025 12:31
@ktowen ktowen marked this pull request as ready for review August 28, 2025 12:51
@krassowski krassowski added this to the 9.5 milestone Aug 29, 2025
@krassowski
Copy link
Member

I think this closes #1665. The proposal there was to expose skip option from https://docs.python.org/3/library/bdb.html but I think this achieves similar end result.

Copy link
Member

@krassowski krassowski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR @ktowen!

This looks mostly fine, the only thing missing is tests. Can you add tests for both ignore_module and unignore_module with and without wildcard usage?

@krassowski krassowski modified the milestones: 9.5, 9.6 Aug 29, 2025
ktowen and others added 2 commits August 29, 2025 16:46
Co-authored-by: Michał Krassowski <5832902+krassowski@users.noreply.github.com>
@ktowen ktowen force-pushed the debugger-ignore-modules branch 3 times, most recently from 1b30a21 to de4bf44 Compare August 30, 2025 12:52
@ktowen ktowen force-pushed the debugger-ignore-modules branch from de4bf44 to 21de9fc Compare August 30, 2025 14:35
@ktowen ktowen requested a review from krassowski August 30, 2025 15:04
Copy link
Member

@krassowski krassowski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@krassowski krassowski merged commit cc81ca1 into ipython:main Sep 26, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

continue until reaching your own code

2 participants