Skip to content

Analyze: Handle Case Where Name is None and New Intersection Option#898

Merged
pearce8 merged 5 commits intodevelopfrom
fix-analyze
Jul 21, 2025
Merged

Analyze: Handle Case Where Name is None and New Intersection Option#898
pearce8 merged 5 commits intodevelopfrom
fix-analyze

Conversation

@michaelmckinsey1
Copy link
Collaborator

@michaelmckinsey1 michaelmckinsey1 commented Jul 14, 2025

Description

  • Currently, if profiles contain any different regions benchpark analyze will fail with error:
    return lib.map_infer(values, mapper, convert=convert)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "pandas/_libs/lib.pyx", line 2999, in pandas._libs.lib.map_infer
  File "/Users/mckinsey1/Documents/repos/benchpark/lib/benchpark/cmd/analyze.py", line 232, in <lambda>
    ".", lambda row: row["name"].apply(lambda n: "MPI_" not in n).all()
                                                 ^^^^^^^^^^^^^^^
TypeError: argument of type 'NoneType' is not iterable

because of the check in the Thicket Query. Modifiying the check to not check against None fixes this issue

  • Additionally, add the option to take the intersection of the calltree instead of the union which is an alternative way to address this issue, but also a feature.

Adding/modifying core functionality, CI, or documentation:

  • Update `lib/benchpark/cmd/analyze.py

@github-actions github-actions bot added the feature New feature or request label Jul 14, 2025
@codecov-commenter
Copy link

codecov-commenter commented Jul 14, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 41.40%. Comparing base (eb33dca) to head (4844ee3).
Report is 51 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #898      +/-   ##
===========================================
+ Coverage    40.30%   41.40%   +1.09%     
===========================================
  Files           15       22       +7     
  Lines         1119     1512     +393     
  Branches       152      214      +62     
===========================================
+ Hits           451      626     +175     
- Misses         632      841     +209     
- Partials        36       45       +9     
Flag Coverage Δ
unittests 41.40% <ø> (+1.09%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 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.

@michaelmckinsey1 michaelmckinsey1 changed the title Add intersection option and handle none Analyze: Handle Case Where Name is None and New Intersection Option Jul 14, 2025
@michaelmckinsey1 michaelmckinsey1 self-assigned this Jul 14, 2025
@michaelmckinsey1 michaelmckinsey1 added the ready for review Ready for review label Jul 14, 2025
@michaelmckinsey1
Copy link
Collaborator Author

michaelmckinsey1 commented Jul 14, 2025

Make sure gitlab unit test for analyze passing (good if all dane tests passing) ready

@pearce8 pearce8 added this pull request to the merge queue Jul 21, 2025
Merged via the queue into develop with commit a6be43e Jul 21, 2025
50 checks passed
@pearce8 pearce8 deleted the fix-analyze branch July 21, 2025 20:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New feature or request ready for review Ready for review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants