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

bump google.golang.org/protobuf v1.34.2 #4898

Merged
merged 1 commit into from
Jun 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions core/chaincode/lifecycle/scc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@ import (
"encoding/gob"
"fmt"

"github.com/hyperledger/fabric/core/ledger"

"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric-chaincode-go/shim"
mspprotos "github.com/hyperledger/fabric-protos-go/msp"
Expand All @@ -25,11 +23,11 @@ import (
"github.com/hyperledger/fabric/core/chaincode/lifecycle/mock"
"github.com/hyperledger/fabric/core/chaincode/persistence"
"github.com/hyperledger/fabric/core/dispatcher"
"github.com/hyperledger/fabric/core/ledger"
"github.com/hyperledger/fabric/msp"
"github.com/pkg/errors"

. "github.com/onsi/ginkgo/v2"
. "github.com/onsi/gomega"
"github.com/pkg/errors"
)

var _ = Describe("SCC", func() {
Expand Down Expand Up @@ -1247,6 +1245,8 @@ var _ = Describe("SCC", func() {
chname, ccname, cd, pubState, orgStates := fakeSCCFuncs.CheckCommitReadinessArgsForCall(0)
Expect(chname).To(Equal("test-channel"))
Expect(ccname).To(Equal("name"))
colls, ok := proto.Clone(arg.Collections).(*pb.CollectionConfigPackage)
Expect(ok).To(BeTrue())
Expect(cd).To(Equal(&lifecycle.ChaincodeDefinition{
Sequence: 7,
EndorsementInfo: &lb.ChaincodeEndorsementInfo{
Expand All @@ -1258,7 +1258,7 @@ var _ = Describe("SCC", func() {
ValidationPlugin: "validation-plugin",
ValidationParameter: []byte("validation-parameter"),
},
Collections: arg.Collections,
Collections: colls,
}))
Expect(pubState).To(Equal(fakeStub))
Expect(orgStates).To(HaveLen(2))
Expand Down
5 changes: 4 additions & 1 deletion core/policy/application_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ package policy
import (
"testing"

"github.com/golang/protobuf/proto"
"github.com/hyperledger/fabric-protos-go/common"
"github.com/hyperledger/fabric-protos-go/peer"
"github.com/hyperledger/fabric/common/cauthdsl"
Expand Down Expand Up @@ -80,9 +81,11 @@ func TestEvaluator(t *testing.T) {
// SCENARIO: signature policy supplied - good and bad path

spenv := &common.SignaturePolicyEnvelope{}
spenvTmp, ok := proto.Clone(spenv).(*common.SignaturePolicyEnvelope)
require.True(t, ok)
mspenv := protoutil.MarshalOrPanic(&peer.ApplicationPolicy{
Type: &peer.ApplicationPolicy_SignaturePolicy{
SignaturePolicy: spenv,
SignaturePolicy: spenvTmp,
},
})
spp.On("NewPolicy", spenv).Return(okEval, nil).Once()
Expand Down
3 changes: 1 addition & 2 deletions discovery/client/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -418,8 +418,7 @@ func TestClient(t *testing.T) {
mychannel := r.ForChannel("mychannel")
conf, err := mychannel.Config()
require.NoError(t, err)
require.Equal(t, expectedConf.Msps, conf.Msps)
require.Equal(t, expectedConf.Orderers, conf.Orderers)
require.True(t, proto.Equal(expectedConf, conf))
peers, err := mychannel.Peers()
require.NoError(t, err)
// We should see all peers as provided above
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ require (
go.etcd.io/etcd/server/v3 v3.5.9
go.uber.org/zap v1.27.0
google.golang.org/grpc v1.61.0
google.golang.org/protobuf v1.33.0
google.golang.org/protobuf v1.34.2
gopkg.in/alecthomas/kingpin.v2 v2.2.6
gopkg.in/yaml.v2 v2.4.0
)
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -944,8 +944,8 @@ google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlba
google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw=
google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc=
google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc=
google.golang.org/protobuf v1.33.0 h1:uNO2rsAINq/JlFpSdYEKIZ0uKD/R9cpdv0T+yoGwGmI=
google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos=
google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg=
google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw=
gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc=
gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
Expand Down
2 changes: 1 addition & 1 deletion protoutil/commonutils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ func TestEnvelopeToConfigUpdate(t *testing.T) {
result, err := EnvelopeToConfigUpdate(env)

require.NoError(t, err, "EnvelopeToConfigUpdate runs without error for valid CONFIG_UPDATE envelope")
require.Equal(t, configUpdateEnv, result, "Correct configUpdateEnvelope returned")
require.True(t, proto.Equal(configUpdateEnv, result), "Correct configUpdateEnvelope returned")

// scenario 2: for invalid envelopes
env = makeEnv([]byte("test bytes"))
Expand Down
4 changes: 2 additions & 2 deletions protoutil/txutils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,7 @@ func TestCreateSignedEnvelope(t *testing.T) {
data := &cb.ConfigEnvelope{}
err = proto.Unmarshal(payload.Data, data)
require.NoError(t, err, "Expected payload data to be a config envelope")
require.Equal(t, msg, data, "Payload data does not match expected value")
require.True(t, proto.Equal(msg, data), "Payload data does not match expected value")

_, err = protoutil.CreateSignedEnvelope(cb.HeaderType_CONFIG, channelID,
id, &cb.ConfigEnvelope{}, int32(1), uint64(1))
Expand All @@ -378,7 +378,7 @@ func TestCreateSignedEnvelopeNilSigner(t *testing.T) {
data := &cb.ConfigEnvelope{}
err = proto.Unmarshal(payload.Data, data)
require.NoError(t, err, "Expected payload data to be a config envelope")
require.Equal(t, msg, data, "Payload data does not match expected value")
require.True(t, proto.Equal(msg, data), "Payload data does not match expected value")
}

func TestGetSignedProposal(t *testing.T) {
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 12 additions & 8 deletions vendor/google.golang.org/protobuf/encoding/protojson/encode.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 12 additions & 8 deletions vendor/google.golang.org/protobuf/encoding/prototext/encode.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 18 additions & 3 deletions vendor/google.golang.org/protobuf/internal/errors/errors.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading