8000 Update package for new protobuf · Issue #20 · ptt/pttweb · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Update package for new protobuf #20

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

Open
PichuChen opened this issue Apr 13, 2025 · 0 comments · May be fixed by #21
Open

Update package for new protobuf #20

PichuChen opened this issue Apr 13, 2025 · 0 comments · May be fixed by #21

Comments

@PichuChen
Copy link

OS version:

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 24.04.1 LTS
Release:        24.04
Codename:       noble

Golang version

$ go version
go version go1.24.0 linux/amd64

protoc-gen-go-grpc Version

$ protoc-gen-go-grpc -version
protoc-gen-go-grpc 1.5.1

protoc version:

$ protoc --version
libprotoc 3.21.12

Error message:

# github.com/ptt/pttweb/proto/man
proto/man/man.pb.go:463:57: unsafe.Slice requires go1.17 or later (-lang was set to go1.15; check go.mod)
proto/man/man.pb.go:463:70: unsafe.StringData requires go1.20 or later (-lang was set to go1.15; check go.mod)
proto/man/man.pb.go:470:32: predeclared any requires go1.18 or later (-lang was set to go1.15; check go.mod)
proto/man/man.pb.go:501:19: unsafe.Slice requires go1.17 or later (-lang was set to go1.15; check go.mod)
proto/man/man.pb.go:501:32: unsafe.StringData requires go1.20 or later (-lang was set to go1.15; check go.mod)
proto/man/man_grpc.pb.go:24:16: undefined: grpc.SupportPackageIsVersion9
proto/man/man_grpc.pb.go:48:41: undefined: grpc.StaticMethod
proto/man/man_grpc.pb.go:58:41: undefined: grpc.StaticMethod
proto/man/man_grpc.pb.go:99:38: undefined: grpc.ServiceRegistrar
# github.com/ptt/pttweb/proto/api
proto/api/board.pb.go:1282:59: unsafe.Slice requires go1.17 or later (-lang was set to go1.15; check go.mod)
proto/api/board.pb.go:1282:72: unsafe.StringData requires go1.20 or later (-lang was set to go1.15; check go.mod)
proto/api/board.pb.go:1289:34: predeclared any requires go1.18 or later (-lang was set to go1.15; check go.mod)
proto/api/board.pb.go:1346:49: predeclared any requires go1.18 or later (-lang was set to go1.15; check go.mod)
proto/api/board.pb.go:1354:19: unsafe.Slice requires go1.17 or later (-lang was set to go1.15; check go.mod)
proto/api/board.pb.go:1354:32: unsafe.StringData requires go1.20 or later (-lang was set to go1.15; check go.mod)
proto/api/board_grpc.pb.go:24:16: undefined: grpc.SupportPackageIsVersion9
proto/api/board_grpc.pb.go:54:41: undefined: grpc.StaticMethod
proto/api/board_grpc.pb.go:64:41: undefined: grpc.StaticMethod
proto/api/board_grpc.pb.go:147:40: undefined: grpc.ServiceRegistrar
proto/api/board_grpc.pb.go:64:41: too many errors

Planned repair steps:

  1. Update go.mod golang version to 1.23
  2. Update google.golang.org/grpc from v1.31.1 to v1.64.0
  3. Build binary

Opt. 4. Update deprecated func grpc.Dial

@PichuChen PichuChen changed the title Upgrade package for new protobuf Update package for new protobuf Apr 13, 2025
PichuChen added a commit to PichuChen/pttweb that referenced this issue Apr 13, 2025
@PichuChen PichuChen linked a pull request Apr 13, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant
0