Skip to content

Commit

Permalink
Merge branch 'master' into bugfix/rosetta-genensis-block-loading
Browse files Browse the repository at this point in the history
  • Loading branch information
yun-yeo committed Oct 19, 2021
2 parents e9bb140 + 573d6b2 commit ef42cff
Show file tree
Hide file tree
Showing 112 changed files with 14,954 additions and 1,029 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Expand Up @@ -39,6 +39,7 @@ Ref: https://keepachangelog.com/en/1.0.0/

### Features

* [\#10393](https://github.com/cosmos/cosmos-sdk/pull/10393) Add `HasSupply` method to bank keeper to ensure that input denom actually exists on chain.
* [\#9933](https://github.com/cosmos/cosmos-sdk/pull/9933) Introduces the notion of a Cosmos "Scalar" type, which would just be simple aliases that give human-understandable meaning to the underlying type, both in Go code and in Proto definitions.
* [\#9884](https://github.com/cosmos/cosmos-sdk/pull/9884) Provide a new gRPC query handler, `/cosmos/params/v1beta1/subspaces`, that allows the ability to query for all registered subspaces and their respective keys.
* [\#9860](https://github.com/cosmos/cosmos-sdk/pull/9860) Emit transaction fee in ante handler fee decorator. The event type is `tx` and the attribute is `fee`.
Expand All @@ -48,6 +49,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* [\#9837](https://github.com/cosmos/cosmos-sdk/issues/9837) `--generate-only` flag will accept the keyname now.
* [\#10045](https://github.com/cosmos/cosmos-sdk/pull/10045) Revert [#8549](https://github.com/cosmos/cosmos-sdk/pull/8549). Do not route grpc queries through Tendermint.
* [\#10326](https://github.com/cosmos/cosmos-sdk/pull/10326) `x/authz` add query all grants by granter query.
* [\#10024](https://github.com/cosmos/cosmos-sdk/pull/10024) `store/cachekv` performance improvement by reduced growth factor for iterator ranging by using binary searches to find dirty items when unsorted key count >= 1024

### API Breaking Changes

Expand Down Expand Up @@ -96,7 +98,9 @@ Ref: https://keepachangelog.com/en/1.0.0/
* Replace `baseapp.SetAnteHandler` with `baseapp.SetTxHandler`.
* Move Msg routers from BaseApp to middlewares.
* Move Baseapp panic recovery into a middleware.
* Rename simulation helper methods `baseapp.{Check,Deliver}` to `baseapp.Sim{Check,Deliver}`.
* Rename simulation helper methods `baseapp.{Check,Deliver}` to `baseapp.Sim{Check,Deliver}**.
* (x/gov) [\#10373](https://github.com/cosmos/cosmos-sdk/pull/10373) Removed gov `keeper.{MustMarshal, MustUnmarshal}`.


### Client Breaking Changes

Expand Down Expand Up @@ -126,6 +130,8 @@ Ref: https://keepachangelog.com/en/1.0.0/
* [\#9699](https://github.com/cosmos/cosmos-sdk/pull/9699) Add `:`, `.`, `-`, and `_` as allowed characters in the default denom regular expression.
* (genesis) [\#9697](https://github.com/cosmos/cosmos-sdk/pull/9697) Ensure `InitGenesis` returns with non-empty validator set.
* [\#10262](https://github.com/cosmos/cosmos-sdk/pull/10262) Remove unnecessary logging in `x/feegrant` simulation.
* [\#10339](https://github.com/cosmos/cosmos-sdk/pull/10339) Improve performance of `removeZeroCoins` by only allocating memory when necessary
* [\#10341](https://github.com/cosmos/cosmos-sdk/pull/10341) Move from `io/ioutil` to `io` and `os` packages.

### Bug Fixes

Expand Down
20 changes: 18 additions & 2 deletions CONTRIBUTING.md
@@ -1,6 +1,7 @@
# Contributing

- [Contributing](#contributing)
- [Dev Calls](#dev-calls)
- [Architecture Decision Records (ADR)](#architecture-decision-records-adr)
- [Development Procedure](#development-procedure)
- [Testing](#testing)
Expand All @@ -12,8 +13,6 @@
- [Protobuf](#protobuf)
- [Branching Model and Release](#branching-model-and-release)
- [PR Targeting](#pr-targeting)
- [Major Release Procedure](#major-release-procedure)
- [Patch Release Procedure](#patch-release-procedure)
- [Code Owner Membership](#code-owner-membership)
- [Concept & Feature Approval Process](#concept--feature-approval-process)

Expand Down Expand Up @@ -44,6 +43,23 @@ not required to an open issue to submit a PR, but be aware that for more complex
problems/features, if a PR is opened before an adequate design discussion has
taken place in a GitHub issue, that PR runs a high likelihood of being rejected.

## Teams Dev Calls

The Cosmos SDK has many stakeholders contributing and shaping the project. Regen Network Development leads the Cosmos SDK R&D, and welcomes long-term contributors and additional maintainers from other projects. We use self-organizing principles to coordinate and collaborate across organizations in structured "Working Groups" that focus on specific problem domains or architectural components of the Cosmos SDK.

The developers are organized in working groups which are listed on a ["Working Groups & Arch Process" Github Issue](https://github.com/cosmos/cosmos-sdk/issues/9058) (pinned at the top of the [issues list](https://github.com/cosmos/cosmos-sdk/issues)).

The important development announcements are shared on [Discord](https://discord.com/invite/cosmosnetwork) in the \#dev-announcements channel.

To synchronize we have few major meetings:
+ Architecture calls: bi-weekly on Fridays at 14:00 UTC (alternating with the grooming meeting below).
+ Grooming / Planning: bi-weekly on Fridays at 14:00 UTC (alternating with the architecture meeting above).
+ Cosmos Community SDK Development Call on the last Wednesday of every month at 17:00 UTC.
+ Cosmos Roadmap Prioritization every 4 weeks on Tuesday at 15:00 UTC (limited participation).

If you would like to join one of those calls, then please contact us on [Discord](https://discord.com/invite/cosmosnetwork) or reach out directly to Cory Levinson from Regen Network (cory@regen.network).


## Architecture Decision Records (ADR)

When proposing an architecture decision for the Cosmos SDK, please start by opening an [issue](https://github.com/cosmos/cosmos-sdk/issues/new/choose) or a [discussion](https://github.com/cosmos/cosmos-sdk/discussions/new) with a summary of the proposal. Once the proposal has been discussed and there is rough alignment on a high-level approach to the design, the [ADR creation process](https://github.com/cosmos/cosmos-sdk/blob/master/docs/architecture/PROCESS.md) can begin. We are following this process to ensure all involved parties are in agreement before any party begins coding the proposed implementation. If you would like to see examples of how these are written, please refer to the current [ADRs](https://github.com/cosmos/cosmos-sdk/tree/master/docs/architecture).
Expand Down
4 changes: 2 additions & 2 deletions Makefile
Expand Up @@ -125,7 +125,7 @@ build-simd-all: go.sum
--env VERSION=$(VERSION) \
--env COMMIT=$(COMMIT) \
--env LEDGER_ENABLED=$(LEDGER_ENABLED) \
--name latest-build cosmossdk/rbuilder:latest
--name latest-build tendermintdev/rbuilder:latest
$(DOCKER) cp -a latest-build:/home/builder/artifacts/ $(CURDIR)/

build-simd-linux: go.sum $(BUILDDIR)/
Expand All @@ -136,7 +136,7 @@ build-simd-linux: go.sum $(BUILDDIR)/
--env VERSION=$(VERSION) \
--env COMMIT=$(COMMIT) \
--env LEDGER_ENABLED=false \
--name latest-build cosmossdk/rbuilder:latest
--name latest-build tendermintdev/rbuilder:latest
$(DOCKER) cp -a latest-build:/home/builder/artifacts/ $(CURDIR)/
cp artifacts/simd-*-linux-amd64 $(BUILDDIR)/simd

Expand Down
156 changes: 84 additions & 72 deletions README.md
@@ -1,72 +1,84 @@
<!--
parent:
order: false
-->

<div align="center">
<h1> Cosmos SDK </h1>
</div>

![banner](docs/cosmos-sdk-image.jpg)

<div align="center">
<a href="https://github.com/cosmos/cosmos-sdk/releases/latest">
<img alt="Version" src="https://img.shields.io/github/tag/cosmos/cosmos-sdk.svg" />
</a>
<a href="https://github.com/cosmos/cosmos-sdk/blob/master/LICENSE">
<img alt="License: Apache-2.0" src="https://img.shields.io/github/license/cosmos/cosmos-sdk.svg" />
</a>
<a href="https://pkg.go.dev/github.com/cosmos/cosmos-sdk?tab=doc">
<img alt="GoDoc" src="https://godoc.org/github.com/cosmos/cosmos-sdk?status.svg" />
</a>
<a href="https://goreportcard.com/report/github.com/cosmos/cosmos-sdk">
<img alt="Go report card" src="https://goreportcard.com/badge/github.com/cosmos/cosmos-sdk" />
</a>
<a href="https://codecov.io/gh/cosmos/cosmos-sdk">
<img alt="Code Coverage" src="https://codecov.io/gh/cosmos/cosmos-sdk/branch/master/graph/badge.svg" />
</a>
</div>
<div align="center">
<a href="https://github.com/cosmos/cosmos-sdk">
<img alt="Lines Of Code" src="https://tokei.rs/b1/github/cosmos/cosmos-sdk" />
</a>
<a href="https://discord.gg/AzefAFd">
<img alt="Discord" src="https://img.shields.io/discord/669268347736686612.svg" />
</a>
<a href="https://sourcegraph.com/github.com/cosmos/cosmos-sdk?badge">
<img alt="Imported by" src="https://sourcegraph.com/github.com/cosmos/cosmos-sdk/-/badge.svg" />
</a>
<img alt="Sims" src="https://github.com/cosmos/cosmos-sdk/workflows/Sims/badge.svg" />
<img alt="Lint Satus" src="https://github.com/cosmos/cosmos-sdk/workflows/Lint/badge.svg" />
</div>

The Cosmos SDK is a framework for building blockchain applications. [Tendermint Core (BFT Consensus)](https://github.com/tendermint/tendermint) and the Cosmos SDK are written in the Golang programming language. Cosmos SDK is used to build [Gaia](https://github.com/cosmos/gaia), the first implementation of the Cosmos Hub.

**WARNING**: The Cosmos SDK has mostly stabilized, but we are still making some
breaking changes.

**Note**: Requires [Go 1.17+](https://golang.org/dl/)

## Quick Start

To learn how the Cosmos SDK works from a high-level perspective, see the Cosmos SDK [High-Level Intro](./docs/intro/overview.md).

If you want to get started quickly and learn how to build on top of Cosmos SDK, visit [Cosmos SDK Tutorials](https://tutorials.cosmos.network). You can also fork the tutorial's repository to get started building your own Cosmos SDK application.

For more information, see the [Cosmos SDK Documentation](./docs/).

## Cosmos Hub Mainnet

The Cosmos Hub application, `gaia`, has moved to its own [cosmos/gaia repository](https://github.com/cosmos/gaia). Go there to join the Cosmos Hub mainnet and more.

## Inter-Blockchain Communication (IBC)

The IBC module for the Cosmos SDK has moved to its own [cosmos/ibc-go repository](https://github.com/cosmos/ibc-go). Go there to build and integrate with the IBC module.

## Starport

Starport is the all-in-one platform to build, launch, and maintain any crypto application on a sovereign and secured blockchain. If you are building a new app or a new module, use [Starport](https://github.com/tendermint/starport) to get started and speed up development.

## Disambiguation

This Cosmos SDK project is not related to the [React-Cosmos](https://github.com/react-cosmos/react-cosmos) project (yet). Many thanks to Evan Coury and Ovidiu (@skidding) for this Github organization name. As per our agreement, this disambiguation notice will stay here.
<!--
parent:
order: false
-->

<div align="center">
<h1> Cosmos SDK </h1>
</div>

![banner](docs/cosmos-sdk-image.jpg)

<div align="center">
<a href="https://github.com/cosmos/cosmos-sdk/releases/latest">
<img alt="Version" src="https://img.shields.io/github/tag/cosmos/cosmos-sdk.svg" />
</a>
<a href="https://github.com/cosmos/cosmos-sdk/blob/master/LICENSE">
<img alt="License: Apache-2.0" src="https://img.shields.io/github/license/cosmos/cosmos-sdk.svg" />
</a>
<a href="https://pkg.go.dev/github.com/cosmos/cosmos-sdk?tab=doc">
<img alt="GoDoc" src="https://godoc.org/github.com/cosmos/cosmos-sdk?status.svg" />
</a>
<a href="https://goreportcard.com/report/github.com/cosmos/cosmos-sdk">
<img alt="Go report card" src="https://goreportcard.com/badge/github.com/cosmos/cosmos-sdk" />
</a>
<a href="https://codecov.io/gh/cosmos/cosmos-sdk">
<img alt="Code Coverage" src="https://codecov.io/gh/cosmos/cosmos-sdk/branch/master/graph/badge.svg" />
</a>
</div>
<div align="center">
<a href="https://github.com/cosmos/cosmos-sdk">
<img alt="Lines Of Code" src="https://tokei.rs/b1/github/cosmos/cosmos-sdk" />
</a>
<a href="https://discord.gg/AzefAFd">
<img alt="Discord" src="https://img.shields.io/discord/669268347736686612.svg" />
</a>
<a href="https://sourcegraph.com/github.com/cosmos/cosmos-sdk?badge">
<img alt="Imported by" src="https://sourcegraph.com/github.com/cosmos/cosmos-sdk/-/badge.svg" />
</a>
<img alt="Sims" src="https://github.com/cosmos/cosmos-sdk/workflows/Sims/badge.svg" />
<img alt="Lint Satus" src="https://github.com/cosmos/cosmos-sdk/workflows/Lint/badge.svg" />
</div>

The Cosmos SDK is a framework for building blockchain applications. [Tendermint Core (BFT Consensus)](https://github.com/tendermint/tendermint) and the Cosmos SDK are written in the Golang programming language. Cosmos SDK is used to build [Gaia](https://github.com/cosmos/gaia), the first implementation of the Cosmos Hub.

**WARNING**: The Cosmos SDK has mostly stabilized, but we are still making some
breaking changes.

**Note**: Requires [Go 1.17+](https://golang.org/dl/)

## Quick Start

To learn how the Cosmos SDK works from a high-level perspective, see the Cosmos SDK [High-Level Intro](./docs/intro/overview.md).

If you want to get started quickly and learn how to build on top of Cosmos SDK, visit [Cosmos SDK Tutorials](https://tutorials.cosmos.network). You can also fork the tutorial's repository to get started building your own Cosmos SDK application.

For more information, see the [Cosmos SDK Documentation](./docs/).

## Contributing

See [CONTRIBUTING.md](./CONTRIBUTING.md) for details how to contribute and participate in our [dev calls](./CONTRIBUTE.md#dev-calls).
If you want to follow the updates or learn more about the latest design then join our [Discord](https://discord.com/invite/cosmosnetwork).

## Tools and Frameworks

The Cosmos ecosystem is vast. We will only make a few notable mentions here.

+ [Tools](https://v1.cosmos.network/tools): notable frameworks and modules.
+ [CosmJS](https://github.com/cosmos/cosmjs): the Swiss Army knife to power JavaScript based client solutions.

### Cosmos Hub Mainnet

The Cosmos Hub application, `gaia`, has moved to its own [cosmos/gaia repository](https://github.com/cosmos/gaia). Go there to join the Cosmos Hub mainnet and more.

### Inter-Blockchain Communication (IBC)

The IBC module for the Cosmos SDK has moved to its own [cosmos/ibc-go repository](https://github.com/cosmos/ibc-go). Go there to build and integrate with the IBC module.

### Starport

Starport is the all-in-one platform to build, launch, and maintain any crypto application on a sovereign and secured blockchain. If you are building a new app or a new module, use [Starport](https://github.com/tendermint/starport) to get started and speed up development.

## Disambiguation

This Cosmos SDK project is not related to the [React-Cosmos](https://github.com/react-cosmos/react-cosmos) project (yet). Many thanks to Evan Coury and Ovidiu (@skidding) for this Github organization name. As per our agreement, this disambiguation notice will stay here.
3 changes: 1 addition & 2 deletions baseapp/baseapp.go
Expand Up @@ -4,7 +4,6 @@ import (
"context"
"errors"
"fmt"
"reflect"

abci "github.com/tendermint/tendermint/abci/types"
"github.com/tendermint/tendermint/libs/log"
Expand Down Expand Up @@ -202,7 +201,7 @@ func (app *BaseApp) MountStores(keys ...storetypes.StoreKey) {
app.MountStore(key, storetypes.StoreTypeTransient)

default:
panic("Unrecognized store key type " + reflect.TypeOf(key).Name())
panic(fmt.Sprintf("Unrecognized store key type :%T", key))
}
}
}
Expand Down
5 changes: 2 additions & 3 deletions baseapp/baseapp_test.go
Expand Up @@ -5,7 +5,6 @@ import (
"encoding/binary"
"encoding/json"
"fmt"
"io/ioutil"
"math"
"math/rand"
"os"
Expand Down Expand Up @@ -162,7 +161,7 @@ func setupBaseAppWithSnapshots(t *testing.T, blocks uint, blockTxs int, options

snapshotInterval := uint64(2)
snapshotTimeout := 1 * time.Minute
snapshotDir, err := ioutil.TempDir("", "baseapp")
snapshotDir, err := os.MkdirTemp("", "baseapp")
require.NoError(t, err)
snapshotStore, err := snapshots.NewStore(dbm.NewMemDB(), snapshotDir)
require.NoError(t, err)
Expand Down Expand Up @@ -934,7 +933,7 @@ func incrementingCounter(t *testing.T, store sdk.KVStore, counterKey []byte, cou
return &sdk.Result{}, nil
}

//---------------------------------------------------------------------
// ---------------------------------------------------------------------
// Tx processing - CheckTx, DeliverTx, SimulateTx.
// These tests use the serialized tx as input, while most others will use the
// Check(), Deliver(), Simulate() methods directly.
Expand Down

0 comments on commit ef42cff

Please sign in to comment.