← Back to Pull requests

Add missing `evaluate()` to `multidispatch.__call__()` #130

Merged
s417-lama merged 1 files (2 lines) on Jan 24, 2025 19:17 UTC
View on GitHub
s417-lama s417-lama commented on Jan 23, 2025 15:46 UTC
Author
Diff: 2 lines (+1 / -1) across 1 files Reviewer: coady Review duration: 1651m
All Vouch review confidence checks passed
Residual risk 0.02 = Change Risk (0.10) × (1 − Review Confidence (0.84)). Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.10 · 2 lines diff across 1 files
0.10
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.78 · 4 substantive comment(s)
0.78
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 50%
84%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size diff_size
0.066
Real PR Conversation Timeline
6 items
coady coady commented on code on Jan 23, 2025 18:15 UTC
Code Review
multimethod/__init__.py:1
@@ -400,6 +400,7 @@ def __setitem__(self, types: tuple, func: Callable):
 
     def __call__(self, *args: Any, **kwargs: Any) -> RETURN:
         """Resolve and dispatch to best method."""
+        self.evaluate()

Thanks for the contribution!

Instead of adding this here, I'd rather move the other self.evaluate() to multitmethod.dispatch. Then they're both covered.

codecov[bot] codecov[bot] commented on Jan 23, 2025 18:17 UTC
Bot

Codecov Report


All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 100.00%. Comparing base (50d8ff8) to head (b64ae79).

Report is 1 commits behind head on main.

<details><summary>Additional details and impacted files</summary>

@@            Coverage Diff            @@
##              main      #130   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines          285       285           
  Branches        53        53           
=========================================
  Hits           285       285           

</details>

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

codspeed[bot] codspeed[bot] commented on Jan 23, 2025 18:20 UTC
Bot

<!-- __CODSPEED_PERFORMANCE_REPORT_COMMENT__ -->
<!-- __CODSPEED_INSTRUMENTATION_PERFORMANCE_REPORT_COMMENT__ -->

CodSpeed Performance Report

Merging #130 will not alter performance

<sub>Comparing <code>s417-lama:fix-missing-evaluate</code> (b64ae79) with <code>main</code> (50d8ff8)</sub>

Summary

✅ 4 untouched benchmarks

s417-lama s417-lama commented on code on Jan 24, 2025 11:04 UTC
Code Review
multimethod/__init__.py:1
@@ -400,6 +400,7 @@ def __setitem__(self, types: tuple, func: Callable):
 
     def __call__(self, *args: Any, **kwargs: Any) -> RETURN:
         """Resolve and dispatch to best method."""
+        self.evaluate()

Sounds nice. Fixed in 8c0beadcf093823ab28a065a41c3c540a72b81b4

coady coady approved these changes on Jan 24, 2025 19:16 UTC
Approved Reviewer

Approved these changes.

Reviewers
Assignees
s417-lama s417-lama
Labels
risk: low confidence: 84.5% reviewed
Vouch Risk Breakdown
AI-powered review risk analysis
Change Risk
Change Risk · Model 1 (XGBoost)
Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
Score: 9.6% (LOW) · Higher = larger blast radius
9.6%
Review Confidence
Review Confidence · Models 2 & 3
Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
Score: 84.5% · Lower = rushed or shallow review
84.5%
Residual Risk
Residual Risk · Core Equation
Residual = Change × (1 − Confidence)
Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
Score: 2% · Safe to merge
2%