Repository navigation
gh-161008: Fix missing statistics in heatmap replay output - #161010
deadlovelll wants to merge 4 commits into
Conversation
| content = pathlib.Path(tmp, "index.html").read_text( | ||
| encoding="utf-8" | ||
| ) | ||
| if with_stats: |
There was a problem hiding this comment.
The with_stats=False branch doesn't assert anything.
Maybe we could assert what we expect for a file without the stats extension? I think that here it'd be 0.0 sec, 0.0, N/A, N/A. If that's the case, do we want to show 0.0 sec for old files, instead of N/A?
| } | ||
| self.stats.update(kwargs) | ||
|
|
||
| def set_replay_stats(self, info): |
There was a problem hiding this comment.
This is a verbatim copy of
cpython/Lib/profiling/sampling/stack_collector.py
Lines 155 to 167 in 1259f16
I wonder how we can avoid this?
There's an interesting disprepancy:
cpython/Lib/profiling/sampling/cli.py
Lines 796 to 799 in 1259f16
cpython/Lib/profiling/sampling/sample.py
Lines 244 to 245 in 1259f16
There was a problem hiding this comment.
Thanks for the review! I’ve taken all your comments into account, and it’s true that I didn’t quite finish writing the test...
Fix missing statistics in heatmap replay output
For details see gh-161008