test(core): tolerate grader timing jitter#1355
Merged
Merged
Conversation
Deploying agentv with
|
| Latest commit: |
60e4eb6
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://a04bb565.agentv.pages.dev |
| Branch Preview URL: | https://fix-orchestrator-timing-flak.agentv.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
setTimeoutdelays.duration_msis internally consistent withstarted_at/ended_attiming.Root cause
Main CI failed in GitHub Actions run https://github.com/EntityProcess/agentv/actions/runs/27316820557/job/80699130076 because
packages/core/test/evaluation/orchestrator.test.tsasserteddurationMs >= 50after awaiting a 50ms timer. CI recorded 49ms. The orchestrator records millisecond wall-clock timestamps before and after the evaluator call, so timer/clock granularity can make the measured elapsed time one millisecond below the requested delay even though timing metadata is present and correct.Verification
cd packages/core && bun test test/evaluation/orchestrator.test.ts -t "includes per-grader timing in scores"repeated 30xcd packages/core && bun test test/evaluation/orchestrator.test.ts -t "includes per-grader timing even when evaluator fails"repeated 30xcd packages/core && bun test test/evaluation/orchestrator.test.tsbun --filter @agentv/core testbiome check .