Repository navigation
Conversation
queryMajorEngineVersionsWithClient downgraded every per-engine error to a warning, so a cancelled context or expired deadline produced a partial version map with a nil error and callers treated it as a complete query. The loop now checks ctx.Err() before each engine and after each failed fetch, returning nil plus the context error instead of continuing. The caller's context is checked rather than the wrapped API error so SDK-internal timeouts (e.g. credential-fetch deadlines) still degrade to the pre-existing per-engine warning. Closes #1325
Contributor
|
Warning Review limit reached
This review includes 2 billable files and costs up to $0.50.
Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing. Or wait 16 minutes for your next included review. View limit detailsLimit details: You’ve used the included review currently available. Your 68 included PR review attempts over the past 7 days set your current allowance at 1 review per hour. Review configuration: ⚙️ Run configuration
📒 Files selected for processing (2)
Comment |
Member
Author
|
@coderabbitai review |
Contributor
|
This branch has not been deployed
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.
Why
queryMajorEngineVersionsWithClientdowngraded every per-engine error to awarning, so a cancelled context or expired deadline produced a partial
version map with a
nilerror. Callers then treated incompleteextended-support data as a complete query — the exact silent-partial-result
class flagged before on this codebase (PR #1225 surfaced this instance).
What
ctx.Err()before each engine and after eachfailed fetch; a cancelled caller context returns
nilplus the contexterror instead of continuing the fan-out.
ctx.Err(), noterrors.Ison the APIerror: the AWS SDK wraps its own internal timeouts (credential-fetch
deadlines) as
context.DeadlineExceeded, and those must still degrade tothe pre-existing per-engine warning.
Tests
New cases in
cmd/multi_service_engine_versions_paginate_test.go:context.Canceledmid-fan-out stops after the first engine%w)context.Canceledbehaves the sameFull
cmdpackage suite green locally (ok ... 459s),gofmt/go vet/pre-commit hooks clean. Test evidence is mock-based; the fan-out loop has no
real-AWS path to exercise locally.
Closes #1325