From e9220161210deacb5cc105c263be9d4616b7387a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Aug 2021 12:25:37 -0400 Subject: [PATCH 1/6] build(deps): Bump technote-space/get-diff-action from 4 to 5 (#6788) Bumps [technote-space/get-diff-action](https://github.com/technote-space/get-diff-action) from 4 to 5. - [Release notes](https://github.com/technote-space/get-diff-action/releases) - [Changelog](https://github.com/technote-space/get-diff-action/blob/main/.releasegarc) - [Commits](https://github.com/technote-space/get-diff-action/compare/v4...v5) --- updated-dependencies: - dependency-name: technote-space/get-diff-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Aleksandr Bezobchuk --- .github/workflows/coverage.yml | 6 +++--- .github/workflows/e2e.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/tests.yml | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/coverage.yml b/.github/workflows/coverage.yml index 7d7ab8113..12dd504e3 100644 --- a/.github/workflows/coverage.yml +++ b/.github/workflows/coverage.yml @@ -46,7 +46,7 @@ jobs: with: go-version: "1.16" - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go @@ -68,7 +68,7 @@ jobs: with: go-version: "1.16" - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go @@ -96,7 +96,7 @@ jobs: needs: tests steps: - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 7fc3cde7a..dd2b44da3 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -18,7 +18,7 @@ jobs: with: go-version: '1.16' - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 4b0092afc..79cb3685b 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -14,7 +14,7 @@ jobs: timeout-minutes: 8 steps: - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 14bb8570b..14d531812 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -19,7 +19,7 @@ jobs: with: go-version: "1.16" - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go @@ -51,7 +51,7 @@ jobs: with: go-version: "1.16" - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go @@ -82,7 +82,7 @@ jobs: with: go-version: "1.16" - uses: actions/checkout@v2.3.4 - - uses: technote-space/get-diff-action@v4 + - uses: technote-space/get-diff-action@v5 with: PATTERNS: | **/**.go From e5f9dd2736db260b7bf223b659c17976d7b2a5b0 Mon Sep 17 00:00:00 2001 From: rene <41963722+renaynay@users.noreply.github.com> Date: Mon, 2 Aug 2021 23:25:59 +0200 Subject: [PATCH 2/6] docs: fix typo (#6789) --- UPGRADING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UPGRADING.md b/UPGRADING.md index cc721af8e..ef0a29fb4 100644 --- a/UPGRADING.md +++ b/UPGRADING.md @@ -27,7 +27,7 @@ This guide provides instructions for upgrading to specific versions of Tendermin * `BootstrapPeers` has been added as part of the new p2p stack. This will eventually replace `Seeds`. Bootstrap peers are connected with on startup if needed for peer discovery. Unlike - persistent peers, there's no gaurantee that the node will remain connected with these peers. + persistent peers, there's no guarantee that the node will remain connected with these peers. * configuration values starting with `priv-validator-` have moved to the new `priv-validator` section, without the `priv-validator-` prefix. From 4cbaf70d1fe5f0a9ee32efcdf6a6d13dde4924f1 Mon Sep 17 00:00:00 2001 From: "M. J. Fromberger" Date: Tue, 3 Aug 2021 12:08:23 -0700 Subject: [PATCH 3/6] docs: fix a typo in the genesis_chunked description (#6792) --- rpc/openapi/openapi.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/rpc/openapi/openapi.yaml b/rpc/openapi/openapi.yaml index bb35d34ac..bfd49b461 100644 --- a/rpc/openapi/openapi.yaml +++ b/rpc/openapi/openapi.yaml @@ -837,7 +837,7 @@ paths: - Info description: | Get genesis document in a paginated/chunked format to make it - easier to iterate through larger gensis structures. + easier to iterate through larger genesis structures. parameters: - in: query name: chunkID @@ -1946,14 +1946,14 @@ components: - "chunk" - "total" - "data" - properties: + properties: chunk: type: integer example: 0 total: type: integer example: 1 - data: + data: type: string example: "Z2VuZXNpcwo=" From e8013281281985e3ada7819f42502b09623d24a0 Mon Sep 17 00:00:00 2001 From: William Banfield <4561443+williambanfield@users.noreply.github.com> Date: Tue, 3 Aug 2021 15:30:05 -0400 Subject: [PATCH 4/6] clist: add simple property tests (#6791) Adds a simple property test to the `clist` package. This test uses the [rapid](https://github.com/flyingmutant/rapid) library and works by modeling the internal clist as a simple array. Follow up from this mornings workshop with the Regen team. --- go.mod | 1 + go.sum | 2 + internal/libs/clist/clist_property_test.go | 72 ++++++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 internal/libs/clist/clist_property_test.go diff --git a/go.mod b/go.mod index b6e0fea38..d13c9ea4b 100644 --- a/go.mod +++ b/go.mod @@ -39,4 +39,5 @@ require ( golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4 google.golang.org/grpc v1.39.0 gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b // indirect + pgregory.net/rapid v0.4.7 // indirect ) diff --git a/go.sum b/go.sum index 55e08e088..ed2f127b2 100644 --- a/go.sum +++ b/go.sum @@ -1437,6 +1437,8 @@ mvdan.cc/lint v0.0.0-20170908181259-adc824a0674b h1:DxJ5nJdkhDlLok9K6qO+5290kphD mvdan.cc/lint v0.0.0-20170908181259-adc824a0674b/go.mod h1:2odslEg/xrtNQqCYg2/jCoyKnw3vv5biOc3JnIcYfL4= mvdan.cc/unparam v0.0.0-20210104141923-aac4ce9116a7 h1:HT3e4Krq+IE44tiN36RvVEb6tvqeIdtsVSsxmNPqlFU= mvdan.cc/unparam v0.0.0-20210104141923-aac4ce9116a7/go.mod h1:hBpJkZE8H/sb+VRFvw2+rBpHNsTBcvSpk61hr8mzXZE= +pgregory.net/rapid v0.4.7 h1:MTNRktPuv5FNqOO151TM9mDTa+XHcX6ypYeISDVD14g= +pgregory.net/rapid v0.4.7/go.mod h1:UYpPVyjFHzYBGHIxLFoupi8vwk6rXNzRY9OMvVxFIOU= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= diff --git a/internal/libs/clist/clist_property_test.go b/internal/libs/clist/clist_property_test.go new file mode 100644 index 000000000..cdc173ee5 --- /dev/null +++ b/internal/libs/clist/clist_property_test.go @@ -0,0 +1,72 @@ +package clist_test + +import ( + "testing" + + "github.com/stretchr/testify/require" + "pgregory.net/rapid" + + "github.com/tendermint/tendermint/internal/libs/clist" +) + +func TestCListProperties(t *testing.T) { + rapid.Check(t, rapid.Run(&clistModel{})) +} + +// clistModel is used by the rapid state machine testing framework. +// clistModel contains both the clist that is being tested and a slice of *clist.CElements +// that will be used to model the expected clist behavior. +type clistModel struct { + clist *clist.CList + + model []*clist.CElement +} + +// Init is a method used by the rapid state machine testing library. +// Init is called when the test starts to initialize the data that will be used +// in the state machine test. +func (m *clistModel) Init(t *rapid.T) { + m.clist = clist.New() + m.model = []*clist.CElement{} +} + +// PushBack defines an action that will be randomly selected across by the rapid state +// machines testing library. Every call to PushBack calls PushBack on the clist and +// performs a similar action on the model data. +func (m *clistModel) PushBack(t *rapid.T) { + value := rapid.String().Draw(t, "value").(string) + el := m.clist.PushBack(value) + m.model = append(m.model, el) +} + +// Remove defines an action that will be randomly selected across by the rapid state +// machine testing library. Every call to Remove selects an element from the model +// and calls Remove on the CList with that element. The same element is removed from +// the model to keep the objects in sync. +func (m *clistModel) Remove(t *rapid.T) { + if len(m.model) == 0 { + return + } + ix := rapid.IntRange(0, len(m.model)-1).Draw(t, "index").(int) + value := m.model[ix] + m.model = append(m.model[:ix], m.model[ix+1:]...) + m.clist.Remove(value) +} + +// Check is a method required by the rapid state machine testing library. +// Check is run after each action and is used to verify that the state of the object, +// in this case a clist.CList matches the state of the objec. +func (m *clistModel) Check(t *rapid.T) { + require.Equal(t, len(m.model), m.clist.Len()) + if len(m.model) == 0 { + return + } + require.Equal(t, m.model[0], m.clist.Front()) + require.Equal(t, m.model[len(m.model)-1], m.clist.Back()) + + iter := m.clist.Front() + for _, val := range m.model { + require.Equal(t, val, iter) + iter = iter.Next() + } +} From 4db71da68e82d5cb732b235eeb2fd69d62114b45 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 5 Aug 2021 10:08:49 -0400 Subject: [PATCH 5/6] build(deps): Bump github.com/BurntSushi/toml from 0.3.1 to 0.4.1 (#6796) Bumps [github.com/BurntSushi/toml](https://github.com/BurntSushi/toml) from 0.3.1 to 0.4.1. - [Release notes](https://github.com/BurntSushi/toml/releases) - [Commits](https://github.com/BurntSushi/toml/compare/v0.3.1...v0.4.1) --- updated-dependencies: - dependency-name: github.com/BurntSushi/toml dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- go.mod | 4 ++-- go.sum | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index d13c9ea4b..cb49f948e 100644 --- a/go.mod +++ b/go.mod @@ -3,7 +3,7 @@ module github.com/tendermint/tendermint go 1.16 require ( - github.com/BurntSushi/toml v0.3.1 + github.com/BurntSushi/toml v0.4.1 github.com/Masterminds/squirrel v1.5.0 github.com/Workiva/go-datastructures v1.0.53 github.com/adlio/schema v1.1.13 @@ -39,5 +39,5 @@ require ( golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4 google.golang.org/grpc v1.39.0 gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b // indirect - pgregory.net/rapid v0.4.7 // indirect + pgregory.net/rapid v0.4.7 ) diff --git a/go.sum b/go.sum index ed2f127b2..0bbb1f3e6 100644 --- a/go.sum +++ b/go.sum @@ -46,8 +46,9 @@ contrib.go.opencensus.io/exporter/stackdriver v0.13.4/go.mod h1:aXENhDJ1Y4lIg4EU dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78 h1:w+iIsaOQNcT7OZ575w+acHgRric5iCyQh+xv+KJ4HB8= github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8= -github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= +github.com/BurntSushi/toml v0.4.1 h1:GaI7EiDXDRfa8VshkTj7Fym7ha+y8/XxIgD2okUIjLw= +github.com/BurntSushi/toml v0.4.1/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/DataDog/zstd v1.4.1 h1:3oxKN3wbHibqx897utPC2LTQU4J+IHWWJO+glkAkpFM= github.com/DataDog/zstd v1.4.1/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= From e5312942e30331e7c42b75426da2c6c9c00ae476 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Aug 2021 14:28:58 +0000 Subject: [PATCH 6/6] build(deps): Bump google.golang.org/grpc from 1.39.0 to 1.39.1 (#6801) Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.39.0 to 1.39.1.
Release notes

Sourced from google.golang.org/grpc's releases.

Release 1.39.1

  • server: fix bug that net.Conn is leaked if the connection is closed (io.EOF) immediately with no traffic (#4642)
  • transport: fix race in transport stream accessing s.recvCompress (#4627)
Commits

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=google.golang.org/grpc&package-manager=go_modules&previous-version=1.39.0&new-version=1.39.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) ---
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
--- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index cb49f948e..a23bc5167 100644 --- a/go.mod +++ b/go.mod @@ -37,7 +37,7 @@ require ( github.com/vektra/mockery/v2 v2.9.0 golang.org/x/crypto v0.0.0-20210314154223-e6e6c4f2bb5b golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4 - google.golang.org/grpc v1.39.0 + google.golang.org/grpc v1.39.1 gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b // indirect pgregory.net/rapid v0.4.7 ) diff --git a/go.sum b/go.sum index 0bbb1f3e6..3e20b60ab 100644 --- a/go.sum +++ b/go.sum @@ -1368,8 +1368,8 @@ google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAG google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= -google.golang.org/grpc v1.39.0 h1:Klz8I9kdtkIN6EpHHUOMLCYhTn/2WAe5a0s1hcBkdTI= -google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= +google.golang.org/grpc v1.39.1 h1:f37vZbBVTiJ6jKG5mWz8ySOBxNqy6ViPgyhSdVnxF3E= +google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM=