Skip to content

feat: track sample counts in hierarchical stats - #56

Merged
P403n1x87 merged 1 commit into
mainfrom
feat/stats-sample-count
Oct 9, 2026
Merged

P403n1x87 merged 1 commit into
mainfrom
feat/stats-sample-count

Conversation

@P403n1x87

@P403n1x87 P403n1x87 commented Oct 9, 2026 •

Copy link
Copy Markdown
Owner

HierarchicalStats nodes now have a samples attribute that counts the samples contributing to the node's total. AustinStats.update sets it to 1 on each new node, and __lshift__ adds it up when merging, the same way own and total are merged.

This lets aggregated metrics be reported along with the number of samples behind them. It's groundwork for an upcoming query API on top of AustinStats.

The field defaults to 0, so existing code that builds stats objects keeps working. Tests that compare whole AustinStats objects now include the expected counts.

HierarchicalStats nodes now carry a samples attribute that counts the
samples contributing to their total, so that aggregated metrics can be
reported together with the number of samples backing them.
@P403n1x87
P403n1x87 force-pushed the feat/stats-sample-count branch from 116435e to 79f01c7 Compare October 9, 2026 11:43
@codecov

codecov Bot commented Oct 9, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.08%. Comparing base (bef69f8) to head (79f01c7).

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #56      +/-   ##
==========================================
- Coverage   78.21%   78.08%   -0.13%     
==========================================
  Files          20       20              
  Lines        1983     1985       +2     
  Branches      245      245              
==========================================
- Hits         1551     1550       -1     
- Misses        357      360       +3     
  Partials       75       75              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@P403n1x87
P403n1x87 merged commit 059e78c into main Oct 9, 2026
47 of 49 checks passed
@P403n1x87
P403n1x87 deleted the feat/stats-sample-count branch October 9, 2026 14:34
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.

1 participant