Skip to content

Commit ea874e2

Browse files
evan-forbesdependabot[bot]mergify[bot]cmwaterstychoish
authored
Pull changes from upstream v0.35.x (#774)
* build(deps): Bump github.com/vektra/mockery/v2 from 2.12.0 to 2.12.1 (#8418) * build(deps): Bump github.com/google/go-cmp from 0.5.7 to 0.5.8 (#8421) * build(deps): Bump github.com/creachadair/tomledit from 0.0.18 to 0.0.19 (#8437) * build(deps): Bump github.com/btcsuite/btcd from 0.22.0-beta to 0.22.1 (#8438) * build(deps): Bump github.com/creachadair/atomicfile from 0.2.5 to 0.2.6 (#8461) Bumps [github.com/creachadair/atomicfile](https://github.com/creachadair/atomicfile) from 0.2.5 to 0.2.6. - [Release notes](https://github.com/creachadair/atomicfile/releases) - [Commits](creachadair/atomicfile@v0.2.5...v0.2.6) --- updated-dependencies: - dependency-name: github.com/creachadair/atomicfile dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * keymigrate: improve filtering for legacy transaction hashes (#8466) (#8467) This is a follow-up to #8352. The check for legacy evidence keys is only based on the prefix of the key. Hashes, which are unprefixed, could easily have this form and be misdiagnosed. Because the conversion for evidence checks the key structure, this should not cause corruption. The probability that a hash is a syntactically valid evidence key is negligible. The tool will report an error rather than storing bad data. But this does mean that such transaction hashes could cause the migration to stop and report an error before it is complete. To ensure we convert all the data, refine the legacy key check to filter these keys more precisely. Update the test cases to exercise this condition. (cherry picked from commit dd4fee8) * build(deps): Bump github.com/vektra/mockery/v2 from 2.12.1 to 2.12.2 (#8473) * build(deps): Bump github.com/golangci/golangci-lint (#8489) Bumps [github.com/golangci/golangci-lint](https://github.com/golangci/golangci-lint) from 1.45.2 to 1.46.0. - [Release notes](https://github.com/golangci/golangci-lint/releases) - [Changelog](https://github.com/golangci/golangci-lint/blob/master/CHANGELOG.md) - [Commits](golangci/golangci-lint@v1.45.2...v1.46.0) --- updated-dependencies: - dependency-name: github.com/golangci/golangci-lint dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * docs: remove developer sessions (#8497) * build(deps): Bump github.com/creachadair/tomledit from 0.0.19 to 0.0.22 (#8503) * statesync: avoid potential race (#8494) * blocksync: validate block before persisting it (backport #8493) (#8496) * Remove backport-specific Dependabot config (v0.35.x). (#8520) After #8518, this separate configuration is no longer needed. The master copy will target updates to this branch. * build(deps): Bump gaurav-nelson/github-action-markdown-link-check from 1.0.13 to 1.0.14 (#8523) * build(deps): Bump gaurav-nelson/github-action-markdown-link-check Bumps [gaurav-nelson/github-action-markdown-link-check](https://github.com/gaurav-nelson/github-action-markdown-link-check) from 1.0.13 to 1.0.14. - [Release notes](https://github.com/gaurav-nelson/github-action-markdown-link-check/releases) - [Commits](gaurav-nelson/github-action-markdown-link-check@1.0.13...1.0.14) --- updated-dependencies: - dependency-name: gaurav-nelson/github-action-markdown-link-check dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Target fork. Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: M. J. Fromberger <fromberger@interchain.io> * build(deps): Bump github.com/prometheus/client_golang (#8542) Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.12.1 to 1.12.2. - [Release notes](https://github.com/prometheus/client_golang/releases) - [Changelog](https://github.com/prometheus/client_golang/blob/v1.12.2/CHANGELOG.md) - [Commits](prometheus/client_golang@v1.12.1...v1.12.2) --- updated-dependencies: - dependency-name: github.com/prometheus/client_golang dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: M. J. Fromberger <fromberger@interchain.io> * build(deps): Bump golangci/golangci-lint-action from 3.1.0 to 3.2.0 (#8526) * build(deps): Bump golangci/golangci-lint-action from 3.1.0 to 3.2.0 Bumps [golangci/golangci-lint-action](https://github.com/golangci/golangci-lint-action) from 3.1.0 to 3.2.0. - [Release notes](https://github.com/golangci/golangci-lint-action/releases) - [Commits](golangci/golangci-lint-action@v3.1.0...v3.2.0) --- updated-dependencies: - dependency-name: golangci/golangci-lint-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump codecov/codecov-action from 2.1.0 to 3.1.0 (#8529) * build(deps): Bump codecov/codecov-action from 2.1.0 to 3.1.0 Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 2.1.0 to 3.1.0. - [Release notes](https://github.com/codecov/codecov-action/releases) - [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md) - [Commits](codecov/codecov-action@v2.1.0...v3.1.0) --- updated-dependencies: - dependency-name: codecov/codecov-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump docker/build-push-action from 2.7.0 to 3.0.0 (#8530) * build(deps): Bump docker/build-push-action from 2.7.0 to 3.0.0 Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 2.7.0 to 3.0.0. - [Release notes](https://github.com/docker/build-push-action/releases) - [Commits](docker/build-push-action@v2.7.0...v3.0.0) --- updated-dependencies: - dependency-name: docker/build-push-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump docker/setup-buildx-action from 1.6.0 to 2.0.0 (#8533) * build(deps): Bump docker/setup-buildx-action from 1.6.0 to 2.0.0 Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 1.6.0 to 2.0.0. - [Release notes](https://github.com/docker/setup-buildx-action/releases) - [Commits](docker/setup-buildx-action@v1.6.0...v2.0.0) --- updated-dependencies: - dependency-name: docker/setup-buildx-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump actions/stale from 4 to 5 (#8534) Bumps [actions/stale](https://github.com/actions/stale) from 4 to 5. - [Release notes](https://github.com/actions/stale/releases) - [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md) - [Commits](actions/stale@v4...v5) --- updated-dependencies: - dependency-name: actions/stale dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump docker/login-action from 1.10.0 to 2.0.0 (#8536) * build(deps): Bump docker/login-action from 1.10.0 to 2.0.0 Bumps [docker/login-action](https://github.com/docker/login-action) from 1.10.0 to 2.0.0. - [Release notes](https://github.com/docker/login-action/releases) - [Commits](docker/login-action@v1.10.0...v2.0.0) --- updated-dependencies: - dependency-name: docker/login-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump google.golang.org/grpc from 1.46.0 to 1.46.2 (#8560) Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.46.0 to 1.46.2. - [Release notes](https://github.com/grpc/grpc-go/releases) - [Commits](grpc/grpc-go@v1.46.0...v1.46.2) --- updated-dependencies: - dependency-name: google.golang.org/grpc dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump github.com/lib/pq from 1.10.5 to 1.10.6 (#8568) * p2p: remove unused get height methods (backport #8569) (#8571) * build(deps): Bump goreleaser/goreleaser-action from 2 to 3 (#8589) Bumps [goreleaser/goreleaser-action](https://github.com/goreleaser/goreleaser-action) from 2 to 3. - [Release notes](https://github.com/goreleaser/goreleaser-action/releases) - [Commits](goreleaser/goreleaser-action@v2...v3) --- updated-dependencies: - dependency-name: goreleaser/goreleaser-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * rpc: fix encoding of block_results responses (backport #8593) (#8594) The block results include validator updates in ABCI protobuf format, which does not encode "correctly" according to the expected Amino style RPC clients expect. - Write a regression test for this issue. - Add JSON marshaling overrides for ABCI ValidatorUpdate messages. Patches for v0.35.x: - Replace jsontypes with tmjson (removed in v0.36) - Regress test data for BeginBlock / EndBlock * p2p: reduce ability of SendError to disconnect peers (backport #8597) (#8603) * build(deps): Bump github.com/vektra/mockery/v2 from 2.12.2 to 2.12.3 (#8608) * migrate: reorder collection ordering (#8613) (#8616) (cherry picked from commit f33722b) Co-authored-by: Sam Kleinman <garen@tychoish.com> * Prepare changelog for release v0.35.5. (#8601) * build(deps): Bump github.com/spf13/viper from 1.11.0 to 1.12.0 (#8631) Bumps [github.com/spf13/viper](https://github.com/spf13/viper) from 1.11.0 to 1.12.0. - [Release notes](https://github.com/spf13/viper/releases) - [Commits](spf13/viper@v1.11.0...v1.12.0) --- updated-dependencies: - dependency-name: github.com/spf13/viper dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * docs: add documentation for undocumented p2p metrics (backport #8640) (#8641) * docs: add documentation for undocumented p2p metrics (#8640) Once merged will backport to v0.35 (cherry picked from commit 3dec4a4) # Conflicts: # docs/nodes/metrics.md * fix merge conflict Co-authored-by: William Banfield <4561443+williambanfield@users.noreply.github.com> Co-authored-by: William Banfield <wbanfield@gmail.com> * build(deps): Bump github.com/vektra/mockery/v2 from 2.12.0 to 2.12.1 (#8418) * build(deps): Bump github.com/google/go-cmp from 0.5.7 to 0.5.8 (#8421) * build(deps): Bump github.com/creachadair/tomledit from 0.0.18 to 0.0.19 (#8437) * build(deps): Bump github.com/btcsuite/btcd from 0.22.0-beta to 0.22.1 (#8438) * build(deps): Bump github.com/creachadair/atomicfile from 0.2.5 to 0.2.6 (#8461) Bumps [github.com/creachadair/atomicfile](https://github.com/creachadair/atomicfile) from 0.2.5 to 0.2.6. - [Release notes](https://github.com/creachadair/atomicfile/releases) - [Commits](creachadair/atomicfile@v0.2.5...v0.2.6) --- updated-dependencies: - dependency-name: github.com/creachadair/atomicfile dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * keymigrate: improve filtering for legacy transaction hashes (#8466) (#8467) This is a follow-up to #8352. The check for legacy evidence keys is only based on the prefix of the key. Hashes, which are unprefixed, could easily have this form and be misdiagnosed. Because the conversion for evidence checks the key structure, this should not cause corruption. The probability that a hash is a syntactically valid evidence key is negligible. The tool will report an error rather than storing bad data. But this does mean that such transaction hashes could cause the migration to stop and report an error before it is complete. To ensure we convert all the data, refine the legacy key check to filter these keys more precisely. Update the test cases to exercise this condition. (cherry picked from commit dd4fee8) * build(deps): Bump github.com/vektra/mockery/v2 from 2.12.1 to 2.12.2 (#8473) * consensus: restructure peer catchup sleep (#8651) * build(deps): Bump github.com/golangci/golangci-lint (#8489) Bumps [github.com/golangci/golangci-lint](https://github.com/golangci/golangci-lint) from 1.45.2 to 1.46.0. - [Release notes](https://github.com/golangci/golangci-lint/releases) - [Changelog](https://github.com/golangci/golangci-lint/blob/master/CHANGELOG.md) - [Commits](golangci/golangci-lint@v1.45.2...v1.46.0) --- updated-dependencies: - dependency-name: github.com/golangci/golangci-lint dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * docs: remove developer sessions (#8497) * build(deps): Bump github.com/creachadair/tomledit from 0.0.19 to 0.0.22 (#8503) * statesync: avoid potential race (#8494) * blocksync: validate block before persisting it (backport #8493) (#8496) * Remove backport-specific Dependabot config (v0.35.x). (#8520) After #8518, this separate configuration is no longer needed. The master copy will target updates to this branch. * build(deps): Bump gaurav-nelson/github-action-markdown-link-check from 1.0.13 to 1.0.14 (#8523) * build(deps): Bump gaurav-nelson/github-action-markdown-link-check Bumps [gaurav-nelson/github-action-markdown-link-check](https://github.com/gaurav-nelson/github-action-markdown-link-check) from 1.0.13 to 1.0.14. - [Release notes](https://github.com/gaurav-nelson/github-action-markdown-link-check/releases) - [Commits](gaurav-nelson/github-action-markdown-link-check@1.0.13...1.0.14) --- updated-dependencies: - dependency-name: gaurav-nelson/github-action-markdown-link-check dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> * Target fork. Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: M. J. Fromberger <fromberger@interchain.io> * build(deps): Bump github.com/prometheus/client_golang (#8542) Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.12.1 to 1.12.2. - [Release notes](https://github.com/prometheus/client_golang/releases) - [Changelog](https://github.com/prometheus/client_golang/blob/v1.12.2/CHANGELOG.md) - [Commits](prometheus/client_golang@v1.12.1...v1.12.2) --- updated-dependencies: - dependency-name: github.com/prometheus/client_golang dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: M. J. Fromberger <fromberger@interchain.io> * build(deps): Bump golangci/golangci-lint-action from 3.1.0 to 3.2.0 (#8526) * build(deps): Bump golangci/golangci-lint-action from 3.1.0 to 3.2.0 Bumps [golangci/golangci-lint-action](https://github.com/golangci/golangci-lint-action) from 3.1.0 to 3.2.0. - [Release notes](https://github.com/golangci/golangci-lint-action/releases) - [Commits](golangci/golangci-lint-action@v3.1.0...v3.2.0) --- updated-dependencies: - dependency-name: golangci/golangci-lint-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump codecov/codecov-action from 2.1.0 to 3.1.0 (#8529) * build(deps): Bump codecov/codecov-action from 2.1.0 to 3.1.0 Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 2.1.0 to 3.1.0. - [Release notes](https://github.com/codecov/codecov-action/releases) - [Changelog](https://github.com/codecov/codecov-action/blob/master/CHANGELOG.md) - [Commits](codecov/codecov-action@v2.1.0...v3.1.0) --- updated-dependencies: - dependency-name: codecov/codecov-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump docker/build-push-action from 2.7.0 to 3.0.0 (#8530) * build(deps): Bump docker/build-push-action from 2.7.0 to 3.0.0 Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 2.7.0 to 3.0.0. - [Release notes](https://github.com/docker/build-push-action/releases) - [Commits](docker/build-push-action@v2.7.0...v3.0.0) --- updated-dependencies: - dependency-name: docker/build-push-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump docker/setup-buildx-action from 1.6.0 to 2.0.0 (#8533) * build(deps): Bump docker/setup-buildx-action from 1.6.0 to 2.0.0 Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 1.6.0 to 2.0.0. - [Release notes](https://github.com/docker/setup-buildx-action/releases) - [Commits](docker/setup-buildx-action@v1.6.0...v2.0.0) --- updated-dependencies: - dependency-name: docker/setup-buildx-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump actions/stale from 4 to 5 (#8534) Bumps [actions/stale](https://github.com/actions/stale) from 4 to 5. - [Release notes](https://github.com/actions/stale/releases) - [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md) - [Commits](actions/stale@v4...v5) --- updated-dependencies: - dependency-name: actions/stale dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump docker/login-action from 1.10.0 to 2.0.0 (#8536) * build(deps): Bump docker/login-action from 1.10.0 to 2.0.0 Bumps [docker/login-action](https://github.com/docker/login-action) from 1.10.0 to 2.0.0. - [Release notes](https://github.com/docker/login-action/releases) - [Commits](docker/login-action@v1.10.0...v2.0.0) --- updated-dependencies: - dependency-name: docker/login-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump google.golang.org/grpc from 1.46.0 to 1.46.2 (#8560) Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.46.0 to 1.46.2. - [Release notes](https://github.com/grpc/grpc-go/releases) - [Commits](grpc/grpc-go@v1.46.0...v1.46.2) --- updated-dependencies: - dependency-name: google.golang.org/grpc dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): Bump github.com/lib/pq from 1.10.5 to 1.10.6 (#8568) * p2p: remove unused get height methods (backport #8569) (#8571) * build(deps): Bump goreleaser/goreleaser-action from 2 to 3 (#8589) Bumps [goreleaser/goreleaser-action](https://github.com/goreleaser/goreleaser-action) from 2 to 3. - [Release notes](https://github.com/goreleaser/goreleaser-action/releases) - [Commits](goreleaser/goreleaser-action@v2...v3) --- updated-dependencies: - dependency-name: goreleaser/goreleaser-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * rpc: fix encoding of block_results responses (backport #8593) (#8594) The block results include validator updates in ABCI protobuf format, which does not encode "correctly" according to the expected Amino style RPC clients expect. - Write a regression test for this issue. - Add JSON marshaling overrides for ABCI ValidatorUpdate messages. Patches for v0.35.x: - Replace jsontypes with tmjson (removed in v0.36) - Regress test data for BeginBlock / EndBlock * p2p: reduce ability of SendError to disconnect peers (backport #8597) (#8603) * build(deps): Bump github.com/vektra/mockery/v2 from 2.12.2 to 2.12.3 (#8608) * migrate: reorder collection ordering (#8613) (#8616) (cherry picked from commit f33722b) Co-authored-by: Sam Kleinman <garen@tychoish.com> * Prepare changelog for release v0.35.5. (#8601) * build(deps): Bump github.com/spf13/viper from 1.11.0 to 1.12.0 (#8631) Bumps [github.com/spf13/viper](https://github.com/spf13/viper) from 1.11.0 to 1.12.0. - [Release notes](https://github.com/spf13/viper/releases) - [Commits](spf13/viper@v1.11.0...v1.12.0) --- updated-dependencies: - dependency-name: github.com/spf13/viper dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * docs: add documentation for undocumented p2p metrics (backport #8640) (#8641) * docs: add documentation for undocumented p2p metrics (#8640) Once merged will backport to v0.35 (cherry picked from commit 3dec4a4) # Conflicts: # docs/nodes/metrics.md * fix merge conflict Co-authored-by: William Banfield <4561443+williambanfield@users.noreply.github.com> Co-authored-by: William Banfield <wbanfield@gmail.com> * docs: add documentation for undocumented p2p metrics (backport #8640) (#8641) * docs: add documentation for undocumented p2p metrics (#8640) Once merged will backport to v0.35 (cherry picked from commit 3dec4a4) * fix merge conflict Co-authored-by: William Banfield <4561443+williambanfield@users.noreply.github.com> Co-authored-by: William Banfield <wbanfield@gmail.com> * consensus: restructure peer catchup sleep (#8651) * align pex max sent address thresholds * remove function * pex: align max address thresholds (#8657) * chore: update version (#8634) * cmd: don't used global config for reset commands (#8668) * build(deps): Bump google.golang.org/grpc from 1.46.2 to 1.47.0 (#8666) Bumps [google.golang.org/grpc](https://github.com/grpc/grpc-go) from 1.46.2 to 1.47.0. - [Release notes](https://github.com/grpc/grpc-go/releases) - [Commits](grpc/grpc-go@v1.46.2...v1.47.0) --- updated-dependencies: - dependency-name: google.golang.org/grpc dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * migrate: provide function for database production (backport #8614) (#8672) (cherry picked from commit d529988) * p2p: shed peers from store from other networks (backport #8678) (#8681) * Prepare Release v0.35.6 (#8685) * p2p: pass maxConns for MaxPeers during node setup (#8684) * pass maxConns for MaxPeers * add upgrade connections to max connections for max peers * change the formula to calculate max peers * increase the timeout for the light client tests Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> Co-authored-by: Callum Waters <cmwaters19@gmail.com> Co-authored-by: Sam Kleinman <garen@tychoish.com> Co-authored-by: M. J. Fromberger <fromberger@interchain.io> Co-authored-by: William Banfield <4561443+williambanfield@users.noreply.github.com> Co-authored-by: William Banfield <wbanfield@gmail.com>
1 parent 52ea672 commit ea874e2

37 files changed

+556
-600
lines changed

.github/dependabot.yml

Lines changed: 0 additions & 24 deletions
This file was deleted.

.github/workflows/docker.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,17 +39,17 @@ jobs:
3939
platforms: all
4040

4141
- name: Set up Docker Build
42-
uses: docker/setup-buildx-action@v1.6.0
42+
uses: docker/setup-buildx-action@v2
4343

4444
- name: Login to DockerHub
4545
if: ${{ github.event_name != 'pull_request' }}
46-
uses: docker/login-action@v1.10.0
46+
uses: docker/login-action@v2
4747
with:
4848
username: ${{ secrets.DOCKERHUB_USERNAME }}
4949
password: ${{ secrets.DOCKERHUB_TOKEN }}
5050

5151
- name: Publish to Docker Hub
52-
uses: docker/build-push-action@v2.7.0
52+
uses: docker/build-push-action@v3
5353
with:
5454
context: .
5555
file: ./DOCKER/Dockerfile

.github/workflows/linkchecker.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v3
10-
- uses: gaurav-nelson/github-action-markdown-link-check@1.0.13
10+
- uses: creachadair/github-action-markdown-link-check@master
1111
with:
1212
folder-path: "docs"

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
**/**.go
2828
go.mod
2929
go.sum
30-
- uses: golangci/golangci-lint-action@v3.1.0
30+
- uses: golangci/golangci-lint-action@v3
3131
with:
3232
# Required: the version of golangci-lint is required and
3333
# must be specified without patch version: we always use the

.github/workflows/proto-docker.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,16 +34,16 @@ jobs:
3434
echo ::set-output name=tags::${TAGS}
3535
3636
- name: Set up Docker Buildx
37-
uses: docker/setup-buildx-action@v1.6.0
37+
uses: docker/setup-buildx-action@v2
3838

3939
- name: Login to DockerHub
40-
uses: docker/login-action@v1.10.0
40+
uses: docker/login-action@v2
4141
with:
4242
username: ${{ secrets.DOCKERHUB_USERNAME }}
4343
password: ${{ secrets.DOCKERHUB_TOKEN }}
4444

4545
- name: Publish to Docker Hub
46-
uses: docker/build-push-action@v2.7.0
46+
uses: docker/build-push-action@v3
4747
with:
4848
context: ./tools/proto
4949
file: ./tools/proto/Dockerfile

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
go-version: '1.17'
2222

2323
- name: Build
24-
uses: goreleaser/goreleaser-action@v2
24+
uses: goreleaser/goreleaser-action@v3
2525
if: ${{ github.event_name == 'pull_request' }}
2626
with:
2727
version: latest
@@ -30,7 +30,7 @@ jobs:
3030
- run: echo https://github.com/tendermint/tendermint/blob/${GITHUB_REF#refs/tags/}/CHANGELOG.md#${GITHUB_REF#refs/tags/} > ../release_notes.md
3131

3232
- name: Release
33-
uses: goreleaser/goreleaser-action@v2
33+
uses: goreleaser/goreleaser-action@v3
3434
if: startsWith(github.ref, 'refs/tags/')
3535
with:
3636
version: latest

.github/workflows/stale.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ jobs:
77
stale:
88
runs-on: ubuntu-latest
99
steps:
10-
- uses: actions/stale@v4
10+
- uses: actions/stale@v5
1111
with:
1212
repo-token: ${{ secrets.GITHUB_TOKEN }}
1313
stale-pr-message: "This pull request has been automatically marked as stale because it has not had

.github/workflows/tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ jobs:
6969
- run: |
7070
cat ./*profile.out | grep -v "mode: set" >> coverage.txt
7171
if: env.GIT_DIFF
72-
- uses: codecov/codecov-action@v2.1.0
72+
- uses: codecov/codecov-action@v3
7373
with:
7474
file: ./coverage.txt
7575
if: env.GIT_DIFF

CHANGELOG.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,32 @@
22

33
Friendly reminder: We have a [bug bounty program](https://hackerone.com/cosmos).
44

5+
## v0.35.6
6+
7+
June 3, 2022
8+
### FEATURES
9+
10+
- [migrate] [\#8672](https://github.com/tendermint/tendermint/pull/8672) provide function for database production (backport #8614) (@tychoish)
11+
12+
### BUG FIXES
13+
14+
- [consensus] [\#8651](https://github.com/tendermint/tendermint/pull/8651) restructure peer catchup sleep (@tychoish)
15+
- [pex] [\#8657](https://github.com/tendermint/tendermint/pull/8657) align max address thresholds (@cmwaters)
16+
- [cmd] [\#8668](https://github.com/tendermint/tendermint/pull/8668) don't used global config for reset commands (@cmwaters)
17+
- [p2p] [\#8681](https://github.com/tendermint/tendermint/pull/8681) shed peers from store from other networks (backport #8678) (@tychoish)
18+
19+
## v0.35.5
20+
21+
May 26, 2022
22+
23+
### BUG FIXES
24+
25+
- [p2p] [\#8371](https://github.com/tendermint/tendermint/pull/8371) fix setting in con-tracker (backport #8370) (@tychoish)
26+
- [blocksync] [\#8496](https://github.com/tendermint/tendermint/pull/8496) validate block against state before persisting it to disk (@cmwaters)
27+
- [statesync] [\#8494](https://github.com/tendermint/tendermint/pull/8494) avoid potential race (@tychoish)
28+
- [keymigrate] [\#8467](https://github.com/tendermint/tendermint/pull/8467) improve filtering for legacy transaction hashes (backport #8466) (@creachadair)
29+
- [rpc] [\#8594](https://github.com/tendermint/tendermint/pull/8594) fix encoding of block_results responses (@creachadair)
30+
531
## v0.35.4
632

733
April 18, 2022

CHANGELOG_PENDING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Friendly reminder: We have a [bug bounty program](https://hackerone.com/cosmos).
44

5-
## v0.35.5
5+
## v0.35.7
66

77
Month DD, YYYY
88

UPGRADING.md

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -66,22 +66,25 @@ This guide provides instructions for upgrading to specific versions of Tendermin
6666

6767
The format of all tendermint on-disk database keys changes in
6868
0.35. Upgrading nodes must either re-sync all data or run a migration
69-
script provided in this release. The script located in
70-
`github.com/tendermint/tendermint/scripts/keymigrate/migrate.go`
71-
provides the function `Migrate(context.Context, db.DB)` which you can
72-
operationalize as makes sense for your deployment.
69+
script provided in this release.
70+
71+
The script located in
72+
`github.com/tendermint/tendermint/scripts/keymigrate/migrate.go` provides the
73+
function `Migrate(context.Context, db.DB)` which you can operationalize as
74+
makes sense for your deployment.
7375

7476
For ease of use the `tendermint` command includes a CLI version of the
7577
migration script, which you can invoke, as in:
7678

7779
tendermint key-migrate
7880

79-
This reads the configuration file as normal and allows the
80-
`--db-backend` and `--db-dir` flags to change database operations as
81-
needed.
81+
This reads the configuration file as normal and allows the `--db-backend` and
82+
`--db-dir` flags to override the database location as needed.
8283

83-
The migration operation is idempotent and can be run more than once,
84-
if needed.
84+
The migration operation is intended to be idempotent, and should be safe to
85+
rerun on the same database multiple times. As a safety measure, however, we
86+
recommend that operators test out the migration on a copy of the database
87+
first, if it is practical to do so, before applying it to the production data.
8588

8689
### CLI Changes
8790

abci/types/result.go

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ import (
55
"encoding/json"
66

77
"github.com/gogo/protobuf/jsonpb"
8+
"github.com/tendermint/tendermint/crypto"
9+
"github.com/tendermint/tendermint/crypto/encoding"
10+
tmjson "github.com/tendermint/tendermint/libs/json"
811
)
912

1013
const (
@@ -119,6 +122,48 @@ func (r *EventAttribute) UnmarshalJSON(b []byte) error {
119122
return jsonpbUnmarshaller.Unmarshal(reader, r)
120123
}
121124

125+
// validatorUpdateJSON is the JSON encoding of a validator update.
126+
//
127+
// It handles translation of public keys from the protobuf representation to
128+
// the legacy Amino-compatible format expected by RPC clients.
129+
type validatorUpdateJSON struct {
130+
PubKey json.RawMessage `json:"pub_key,omitempty"`
131+
Power int64 `json:"power,string"`
132+
}
133+
134+
func (v *ValidatorUpdate) MarshalJSON() ([]byte, error) {
135+
key, err := encoding.PubKeyFromProto(v.PubKey)
136+
if err != nil {
137+
return nil, err
138+
}
139+
jkey, err := tmjson.Marshal(key)
140+
if err != nil {
141+
return nil, err
142+
}
143+
return json.Marshal(validatorUpdateJSON{
144+
PubKey: jkey,
145+
Power: v.GetPower(),
146+
})
147+
}
148+
149+
func (v *ValidatorUpdate) UnmarshalJSON(data []byte) error {
150+
var vu validatorUpdateJSON
151+
if err := json.Unmarshal(data, &vu); err != nil {
152+
return err
153+
}
154+
var key crypto.PubKey
155+
if err := tmjson.Unmarshal(vu.PubKey, &key); err != nil {
156+
return err
157+
}
158+
pkey, err := encoding.PubKeyToProto(key)
159+
if err != nil {
160+
return err
161+
}
162+
v.PubKey = pkey
163+
v.Power = vu.Power
164+
return nil
165+
}
166+
122167
// Some compile time assertions to ensure we don't
123168
// have accidental runtime surprises later on.
124169

cmd/tendermint/commands/key_migrate.go

Lines changed: 46 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@ import (
55
"fmt"
66

77
"github.com/spf13/cobra"
8+
89
cfg "github.com/tendermint/tendermint/config"
10+
"github.com/tendermint/tendermint/libs/log"
911
"github.com/tendermint/tendermint/scripts/keymigrate"
1012
"github.com/tendermint/tendermint/scripts/scmigrate"
1113
)
@@ -15,58 +17,60 @@ func MakeKeyMigrateCommand() *cobra.Command {
1517
Use: "key-migrate",
1618
Short: "Run Database key migration",
1719
RunE: func(cmd *cobra.Command, args []string) error {
18-
ctx, cancel := context.WithCancel(cmd.Context())
19-
defer cancel()
20+
return RunDatabaseMigration(cmd.Context(), logger, config)
21+
},
22+
}
2023

21-
contexts := []string{
22-
// this is ordered to put the
23-
// (presumably) biggest/most important
24-
// subsets first.
25-
"blockstore",
26-
"state",
27-
"peerstore",
28-
"tx_index",
29-
"evidence",
30-
"light",
31-
}
24+
// allow database info to be overridden via cli
25+
addDBFlags(cmd)
3226

33-
for idx, dbctx := range contexts {
34-
logger.Info("beginning a key migration",
35-
"dbctx", dbctx,
36-
"num", idx+1,
37-
"total", len(contexts),
38-
)
27+
return cmd
28+
}
3929

40-
db, err := cfg.DefaultDBProvider(&cfg.DBContext{
41-
ID: dbctx,
42-
Config: config,
43-
})
30+
func RunDatabaseMigration(ctx context.Context, logger log.Logger, conf *cfg.Config) error {
31+
contexts := []string{
32+
// this is ordered to put
33+
// the more ephemeral tables first to
34+
// reduce the possibility of the
35+
// ephemeral data overwriting later data
36+
"tx_index",
37+
"peerstore",
38+
"light",
39+
"blockstore",
40+
"state",
41+
"evidence",
42+
}
4443

45-
if err != nil {
46-
return fmt.Errorf("constructing database handle: %w", err)
47-
}
44+
for idx, dbctx := range contexts {
45+
logger.Info("beginning a key migration",
46+
"dbctx", dbctx,
47+
"num", idx+1,
48+
"total", len(contexts),
49+
)
4850

49-
if err = keymigrate.Migrate(ctx, db); err != nil {
50-
return fmt.Errorf("running migration for context %q: %w",
51-
dbctx, err)
52-
}
51+
db, err := cfg.DefaultDBProvider(&cfg.DBContext{
52+
ID: dbctx,
53+
Config: conf,
54+
})
5355

54-
if dbctx == "blockstore" {
55-
if err := scmigrate.Migrate(ctx, db); err != nil {
56-
return fmt.Errorf("running seen commit migration: %w", err)
56+
if err != nil {
57+
return fmt.Errorf("constructing database handle: %w", err)
58+
}
5759

58-
}
59-
}
60-
}
60+
if err = keymigrate.Migrate(ctx, db); err != nil {
61+
return fmt.Errorf("running migration for context %q: %w",
62+
dbctx, err)
63+
}
6164

62-
logger.Info("completed database migration successfully")
65+
if dbctx == "blockstore" {
66+
if err := scmigrate.Migrate(ctx, db); err != nil {
67+
return fmt.Errorf("running seen commit migration: %w", err)
6368

64-
return nil
65-
},
69+
}
70+
}
6671
}
6772

68-
// allow database info to be overridden via cli
69-
addDBFlags(cmd)
73+
logger.Info("completed database migration successfully")
7074

71-
return cmd
75+
return nil
7276
}

0 commit comments

Comments
 (0)