cloudwego / kitex-examples

Examples for Kitex.
Apache License 2.0
363 stars 230 forks source link

go 1.22 kitex-mux protobuf example build error #121

Closed ouvaa closed 2 months ago

ouvaa commented 7 months ago

did go mod init and go get -u

this is in kitex-benchmark, sorry i posted in "wrong" issue. but possible to resolve here?

ubuntu@ubuntu:~/kitex-benchmark/protobuf/kitex-mux$ go build main.go 
# github.com/cloudwego/kitex/pkg/utils
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:54:54: not enough arguments in call to t.tProt.WriteMessageBegin
    have (string, thrift.TMessageType, int32)
    want (context.Context, string, thrift.TMessageType, int32)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:57:21: not enough arguments in call to msg.Write
    have (thrift.TProtocol)
    want (context.Context, thrift.TProtocol)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:60:11: not enough arguments in call to t.tProt.WriteMessageEnd
    have ()
    want (context.Context)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:74:35: not enough arguments in call to t.tProt.ReadMessageBegin
    have ()
    want (context.Context)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:79:27: not enough arguments in call to exception.Read
    have (thrift.TProtocol)
    want (context.Context, thrift.TProtocol)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:82:12: not enough arguments in call to t.tProt.ReadMessageEnd
    have ()
    want (context.Context)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:88:20: not enough arguments in call to msg.Read
    have (thrift.TProtocol)
    want (context.Context, thrift.TProtocol)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:91:2: not enough arguments in call to t.tProt.ReadMessageEnd
    have ()
    want (context.Context)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:100:21: not enough arguments in call to msg.Write
    have (thrift.TProtocol)
    want (context.Context, thrift.TProtocol)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:114:20: not enough arguments in call to msg.Read
    have (thrift.TProtocol)
    want (context.Context, thrift.TProtocol)
../../../go/pkg/mod/github.com/cloudwego/kitex@v0.9.1/pkg/utils/thrift.go:114:20: too many errors
GuangmingLuo commented 7 months ago

Try replace github.com/apache/thrift => github.com/apache/thrift v0.13.0 in go.mod