Retain cancellation at the final readiness handoff

This commit is contained in:
2026-11-28 16:15:57 +00:00
parent 4801d0aac1
commit 460d368d8e
4 changed files with 25 additions and 2 deletions

View File

@@ -39,10 +39,14 @@ func RunSmokeChecksObserved(ctx context.Context, engine *promptkit.Engine, targe
observation := SmokeObservation{Kind: kind, ProfileID: profile, BackendID: backend, Bindings: bindings, Report: report}
observation.Applicable, observation.Err = evaluateSmoke(kind, report, err)
observations = append(observations, observation)
operationErr := observation.Err
if observe != nil {
return errors.Join(observation.Err, observe(observation))
operationErr = errors.Join(operationErr, observe(observation))
}
return observation.Err
if ctxErr := ctx.Err(); ctxErr != nil && !errors.Is(operationErr, ctxErr) {
operationErr = errors.Join(operationErr, ctxErr)
}
return operationErr
}
for _, target := range targets.Access {
for _, kind := range []promptkit.SmokeTestKind{promptkit.SmokeTestReachability, promptkit.SmokeTestAuthentication} {