bloomberg / memray

Memray is a memory profiler for Python
https://bloomberg.github.io/memray/
Apache License 2.0
13.17k stars 392 forks source link

Fix reporting of "Own Memory" in TUI reporters #617

Closed godlygeek closed 4 months ago

godlygeek commented 4 months ago

The live and summary reporters include a column for the number of bytes directly allocated by a particular function (called "Own Bytes" or "Own Memory", with a corresponding column for the percentage of memory directly allocated by that function).

A bug in our summation led to us undercounting and misreporting these columns.

codecov-commenter commented 4 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 92.79%. Comparing base (41248ed) to head (ea1e5f8). Report is 61 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #617 +/- ## ========================================== + Coverage 92.55% 92.79% +0.24% ========================================== Files 91 92 +1 Lines 11304 11236 -68 Branches 1581 2058 +477 ========================================== - Hits 10462 10427 -35 + Misses 837 809 -28 + Partials 5 0 -5 ``` | [Flag](https://app.codecov.io/gh/bloomberg/memray/pull/617/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=bloomberg) | Coverage Δ | | |---|---|---| | [cpp](https://app.codecov.io/gh/bloomberg/memray/pull/617/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=bloomberg) | `92.79% <100.00%> (+6.85%)` | :arrow_up: | | [python_and_cython](https://app.codecov.io/gh/bloomberg/memray/pull/617/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=bloomberg) | `92.79% <100.00%> (-2.93%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=bloomberg#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.