Repository navigation
Conversation
They waited with the SDK's WaitGetResults, whose maxRetries counts only errors, so a query that kept running was waited on forever. They now wait with execution.WaitForExecution, the status poll execution results uses, and fetch the rows once it finishes. Amp-Thread-ID: https://ampcode.com/threads/T-01a1f46d-4de8-7404-a66a-7e2a8be6632a Co-authored-by: Amp <amp@ampcode.com>
Contributor
|
@claude review |
…in test Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
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.
dune query runanddune query run-sqlnow stop waiting at--timeoutand fail withexecution <id> is still EXECUTING after <n>s; .... Before, a query that kept running was waited on forever. Follow-up from Norbert's review of #69.Impact
query runandquery run-sqlwithout--no-wait. They used the SDK'sWaitGetResults, whosemaxRetriescounts only errors.execution.WaitForExecution(exported fromcmd/execution, the status pollexecution resultsuses since Enforce --timeout when waiting for unshaped execution results #69) and then fetch the rows once withGetResults. So the same rules apply: a still-running query fails at the deadline, transient errors (network, 5xx, 429) are retried with a note on stderr, and any other 4xx fails at once.WaitForExecutionnow takes a status function, soexecution resultspassesclient.QueryStatusandquery runpassesexec.GetStatus.Context for reviewers
TestRunStopsAtTheTimeoutchecks that a query stuck in EXECUTING fails within about--timeout, after several status polls.The query test mock now implements
GetStatus/GetResultsinstead ofWaitGetResults; the existing run and run-sql tests are otherwise unchanged and pass.No visual surface: CLI change with no rendered UI; verified with unit tests (
go vet ./...,go test -race ./...).