Skip to content

Commit

Permalink
Merge pull request #239 from mattip/fix-show-all
Browse files Browse the repository at this point in the history
  • Loading branch information
joerick committed May 6, 2023
2 parents 19c86c2 + 8dcba69 commit 63f8191
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 1 deletion.
13 changes: 13 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2

build:
os: ubuntu-22.04
tools:
python: "3.11"

sphinx:
configuration: docs/conf.py

python:
install:
- requirements: requirements-dev.txt
2 changes: 2 additions & 0 deletions pyinstrument/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,8 @@ def compute_render_options(

if options.timeline:
render_options["timeline"] = True
if options.show_all:
render_options["show_all"] = True

# apply user options
if options.render_options is not None:
Expand Down
13 changes: 12 additions & 1 deletion pyinstrument/renderers/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,18 @@ def __init__(
self.processor_options = processor_options or {}

if show_all:
self.processors.remove(processors.group_library_frames_processor)
for p in (
processors.group_library_frames_processor,
processors.remove_importlib,
processors.remove_irrelevant_nodes,
processors.remove_tracebackhide,
# note: we're not removing these processors
# processors.remove_unnecessary_self_time_nodes,
# (still hide the inner pyinstrument synthetic frames)
# processors.remove_first_pyinstrument_frames_processor,
# (still hide the outer pyinstrument calling frames)
):
self.processors.remove(p)
if timeline:
self.processors.remove(processors.aggregate_repeated_calls)

Expand Down

0 comments on commit 63f8191

Please sign in to comment.