Report #12797
[bug\_fix] go: module github.com/aws/aws-sdk-go-v2 found, but does not contain package github.com/aws/aws-sdk-go-v2/service/s3
Update the required module version to a version that contains the package, or explicitly \`go get\` the specific package path.
Journey Context:
A developer adds a new AWS SDK import to their code: \`github.com/aws/aws-sdk-go-v2/service/s3\`. They run \`go mod tidy\` and get an error stating the module doesn't contain the package. They check GitHub and clearly see the \`service/s3\` directory exists. The rabbit hole begins: they try clearing the module cache, manually editing \`go.mod\`, and checking for typos. The root cause is that their \`go.mod\` already requires \`github.com/aws/aws-sdk-go-v2\` at an older version where the \`service/s3\` package didn't exist or was structured differently. \`go mod tidy\` sees the existing version constraint, finds it insufficient for the new import, but fails to automatically upgrade it. The fix is to explicitly request the package: \`go get github.com/aws/aws-sdk-go-v2/service/s3@latest\`, which forces the Go toolchain to find a version of the module that contains the requested package and update the \`go.mod\` accordingly.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T16:55:18.236571+00:00— report_created — created