Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

storage: v1.31.0 fails tests in conjunction with cloud.google.com/go/httpreplay where v1.30.1 did not #8233

Closed
gannett-ggreer opened this issue Jul 7, 2023 · 3 comments · Fixed by #8260
Assignees
Labels
api: storage Issues related to the Cloud Storage API. priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@gannett-ggreer
Copy link

Client

go test

Environment

macOS Monterey 12.6.3

Go Environment

$ go version

go version go1.20.5 darwin/amd64

$ go env

GO111MODULE="on"
GOARCH="amd64"
GOBIN=""
GOCACHE="/Users/ggreer/Library/Caches/go-build"
GOENV="/Users/ggreer/Library/Application Support/go/env"
GOEXE=""
GOEXPERIMENT=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOINSECURE=""
GOMODCACHE="/Users/ggreer/p/go/pkg/mod"
GONOPROXY="github.com/GannettDigital"
GONOSUMDB="github.com/GannettDigital"
GOOS="darwin"
GOPATH="/Users/ggreer/p/go"
GOPRIVATE="github.com/GannettDigital"
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/Cellar/go/1.20.5/libexec"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/Cellar/go/1.20.5/libexec/pkg/tool/darwin_amd64"
GOVCS=""
GOVERSION="go1.20.5"
GCCGO="gccgo"
GOAMD64="v1"
AR="ar"
CC="cc"
CXX="c++"
CGO_ENABLED="1"
GOMOD="/Users/ggreer/p/go/src/github.com/GannettDigital/content-api/go.mod"
GOWORK=""
CGO_CFLAGS="-O2 -g"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-O2 -g"
CGO_FFLAGS="-O2 -g"
CGO_LDFLAGS="-O2 -g"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -arch x86_64 -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/p6/7bbg8bnn0ys4581_ssb8zkz00000gp/T/go-build377390741=/tmp/go-build -gno-record-gcc-switches -fno-common"

Code

https://gist.github.com/gannett-ggreer/9e1a2a19380ac3e1da526a9cad79f4e2

Expected behavior

Recorded traffic can be replayed by cloud.google.com/go/httpreplay

Actual behavior

Fails with "ERROR: martian: failed to round trip: no matching request".

Screenshots

There is sample output in the linked gist.

Additional context

v1.30.1 is fine, v1.31.0 is not.

@gannett-ggreer gannett-ggreer added the triage me I really want to be triaged. label Jul 7, 2023
@product-auto-label product-auto-label bot added the api: storage Issues related to the Cloud Storage API. label Jul 7, 2023
@tritone tritone added type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. priority: p2 Moderately-important priority. Fix may not be included in next release. and removed triage me I really want to be triaged. labels Jul 13, 2023
@tritone
Copy link
Contributor

tritone commented Jul 13, 2023

Thanks for the detailed repro. I will try running this today and let you know what I find.

tritone added a commit to tritone/google-cloud-go that referenced this issue Jul 13, 2023
New GCS header x-goog-gcs-idempotency-token should be on the list
to be ignored by default. Also change the integration test so that
the test isn't explicitly requesting that it be ignored.

Fixes googleapis#8233
@tritone
Copy link
Contributor

tritone commented Jul 13, 2023

I found that a header that should be ignored by httpreplay currently isn't. Made a PR to fix which should go out in the next release of cloud.google.com/go (storage version should not matter). In the mean time you can also do a workaround in your example by adding rep.IgnoreHeader("X-Goog-Gcs-Idempotency-Token")

gcf-merge-on-green bot pushed a commit that referenced this issue Jul 13, 2023
New GCS header x-goog-gcs-idempotency-token should be on the list to be ignored by default. Also change the integration test so that the test isn't explicitly requesting that it be ignored.

Fixes #8233
@codyoss
Copy link
Member

codyoss commented Jul 13, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: storage Issues related to the Cloud Storage API. priority: p2 Moderately-important priority. Fix may not be included in next release. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants