feat: allow skipIf to return a promise #2732
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.36) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.36 · 204 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
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.318
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #2732"
general
weight: 0.35
kamilmysliwiec
There are cases where retrieving details from Redis or a database is required to determine whether throttling should be skipped. Making
skipIfawaitable allows asynchronous checks to be performed before deciding whether to skip throttling.PR Checklist
Please check if your PR fulfils the following requirements:
PR Type
What kind of change does this PR introduce?
<!-- Please check the one that applies to this PR using "x". -->
What is the current behavior?
The
skipIfoption only supports synchronous checks, preventing conditions that require asynchronous operations, such as retrieving data from Redis or a database.Issue Number: N/A
What is the new behavior?
The
skipIfoption supports asynchronous checks, allowing it to return a Promise. This enables throttling decisions to depend on data retrieved from external or asynchronous sources.Does this PR introduce a breaking change?
<!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below. -->
Other information
Existing synchronous
skipIfcallbacks remain supported. No migration is required.