fix: use configured checkpoint timeout for wait warning #10680
+5
−3
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
Fixes #10657
The checkpoint initialization warning was using a hardcoded 5-second value (
WARNING_THRESHOLD_MS / 1000) for the timeout parameter in the warning message, regardless of the user's actual configured checkpoint timeout.This PR updates the code to use
task.checkpointTimeoutfor the warning message parameter, ensuring the message correctly reflects the configured timeout (e.g., "taking longer than 15 seconds...").Changes
src/core/checkpoints/index.ts: Passtask.checkpointTimeoutinstead of hardcoded 5s tosendCheckpointInitWarn.src/core/checkpoints/__tests__/checkpoint.test.ts: Updated test case to verify that the warning message receives the configured timeout value.Testing
should send warning message when initialization is slowtest case now explicitly checks for matchingtask.checkpointTimeout.Important
Fixes hardcoded timeout in checkpoint warning message to use
task.checkpointTimeoutinindex.ts.sendCheckpointInitWarninindex.tsnow usestask.checkpointTimeoutinstead of a hardcoded 5s for warning messages.checkpoint.test.tsto verify warning message usestask.checkpointTimeout.should send warning message when initialization is slowchecks for correct timeout value in warning message.This description was created by
for ff9bc99. You can customize this summary. It will automatically update as commits are pushed.