-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Open
Labels
Milestone
@deorth-kku Output of
Description
Go version
go 1.25.0 linux/amd64
Output of go env
in your module/workspace:
AR='ar' CC='gcc' CGO_CFLAGS='-O2 -g' CGO_CPPFLAGS='' CGO_CXXFLAGS='-O2 -g' CGO_ENABLED='0' CGO_FFLAGS='-O2 -g' CGO_LDFLAGS='-O2 -g' CXX='g++' GCCGO='gccgo' GO111MODULE='on' GOAMD64='v3' GOARCH='amd64' GOAUTH='netrc' GOBIN='' GOCACHE='/home/deorth/.cache/go-build' GOCACHEPROG='' GODEBUG='' GOENV='/home/deorth/.config/go/env' GOEXE='' GOEXPERIMENT='jsonv2,greenteagc' GOFIPS140='off' GOFLAGS='' GOGCCFLAGS='-fPIC -m64 -Wl,--no-gc-sections -fmessage-length=0 -ffile-prefix-map=/tmp/go-build3589554910=/tmp/go-build -gno-record-gcc-switches' GOHOSTARCH='amd64' GOHOSTOS='linux' GOINSECURE='' GOMOD='/home/deorth/go-jsonrpc/go.mod' GOMODCACHE='/home/deorth/go/pkg/mod' GONOPROXY='' GONOSUMDB='' GOOS='linux' GOPATH='/home/deorth/go' GOPRIVATE='' GOPROXY='https://goproxy.cn,direct' GOROOT='/home/deorth/sdk/go1.25.0' GOSUMDB='sum.golang.org' GOTELEMETRY='local' GOTELEMETRYDIR='/home/deorth/.config/go/telemetry' GOTMPDIR='' GOTOOLCHAIN='auto' GOTOOLDIR='/home/deorth/sdk/go1.25.0/pkg/tool/linux_amd64' GOVCS='' GOVERSION='go1.25.0' GOWORK='' PKG_CONFIG='pkg-config'
What did you do?
try to retrive Marshalers/Unmarshalers from DefaultOptionsV1/DefaultOptionsV2, for example:
json.GetOption(json.DefaultOptionsV2(), json.WithMarshalers)
playground link
What did you see happen?
panic: interface conversion: interface {} is nil, not *json.typedArshalers[encoding/json/jsontext.Encoder]
What did you expect to see?
no panic