Skip to content

Commit

Permalink
Rebrand to Rollkit (cosmos#703)
Browse files Browse the repository at this point in the history
Resolves cosmos#704.
  • Loading branch information
tzdybal authored Jan 23, 2023
1 parent 9bf4b1d commit 567b9f5
Show file tree
Hide file tree
Showing 79 changed files with 619 additions and 612 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/docker-build-ethermint-debug.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
cp -R rollmint ethermint
cd ethermint
rm -rf .git
go mod edit -replace=github.com/celestiaorg/rollmint=./rollmint
go mod edit -replace=github.com/rollkit/rollkit=./rollmint
go mod tidy -compat=1.17 -e
- name: Docker meta
id: meta
Expand Down
2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ linters-settings:
- name: package-comments
disabled: true
goimports:
local-prefixes: github.com/celestiaorg
local-prefixes: github.com/rollkit
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Finding an issue

GitHub issues are used to track the work associated with rollmint. That's where you can find things to work on.
GitHub issues are used to track the work associated with Rollkit. That's where you can find things to work on.

Issue labels have been used to help designate the priority, status and beginner-friendliness of various issues. Here are some of the ones that are most relevant to finding a good issue to work on:

Expand All @@ -11,7 +11,7 @@ Issue labels have been used to help designate the priority, status and beginner-

No explicit permission is needed to work on these issues but it would be good idea to tag the user who opened the issue and ask that the issue is assinged to yourself.

All issue labels can be [found here](https://github.com/celestiaorg/rollmint/labels) for you to explore and see what peaks your interest.
All issue labels can be [found here](https://github.com/rollkit/rollkit/labels) for you to explore and see what peaks your interest.

## Contribution process

Expand Down
4 changes: 2 additions & 2 deletions NOTICE
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
rollmint
Copyright 2021-2022 Celestia Labs
Rollkit
Copyright 2021-2023 Celestia Labs
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# rollmint
# Rollkit

ABCI-client implementation for Optimistic Rollups.

[![build-and-test](https://github.com/celestiaorg/rollmint/actions/workflows/test.yml/badge.svg)](https://github.com/celestiaorg/rollmint/actions/workflows/test.yml)
[![golangci-lint](https://github.com/celestiaorg/rollmint/actions/workflows/lint.yml/badge.svg)](https://github.com/celestiaorg/rollmint/actions/workflows/lint.yml)
[![Go Report Card](https://goreportcard.com/badge/github.com/celestiaorg/rollmint)](https://goreportcard.com/report/github.com/celestiaorg/rollmint)
[![codecov](https://codecov.io/gh/celestiaorg/rollmint/branch/main/graph/badge.svg?token=CWGA4RLDS9)](https://codecov.io/gh/celestiaorg/rollmint)
[![GoDoc](https://godoc.org/github.com/celestiaorg/rollmint?status.svg)](https://godoc.org/github.com/celestiaorg/rollmint)
[![build-and-test](https://github.com/rollkit/rollkit/actions/workflows/test.yml/badge.svg)](https://github.com/rollkit/rollkit/actions/workflows/test.yml)
[![golangci-lint](https://github.com/rollkit/rollkit/actions/workflows/lint.yml/badge.svg)](https://github.com/rollkit/rollkit/actions/workflows/lint.yml)
[![Go Report Card](https://goreportcard.com/badge/github.com/rollkit/rollkit)](https://goreportcard.com/report/github.com/rollkit/rollkit)
[![codecov](https://codecov.io/gh/rollkit/rollkit/branch/main/graph/badge.svg?token=CWGA4RLDS9)](https://codecov.io/gh/rollkit/rollkit)
[![GoDoc](https://godoc.org/github.com/rollkit/rollkit?status.svg)](https://godoc.org/github.com/rollkit/rollkit)
[![Twitter Follow](https://img.shields.io/twitter/follow/CelestiaOrg?style=social)](https://twitter.com/CelestiaOrg)

## Building From Source
Expand All @@ -16,8 +16,8 @@ Requires Go version >= 1.19.
To build:

```sh
git clone https://github.com/celestiaorg/rollmint.git
cd rollmint
git clone https://github.com/rollkit/rollkit.git
cd rollkit
go build -v ./...
```

Expand All @@ -38,15 +38,15 @@ To regenerate protobuf types:
We welcome your contributions! Everyone is welcome to contribute, whether it's in the form of code,
documentation, bug reports, feature requests, or anything else.

If you're looking for issues to work on, try looking at the [good first issue list](https://github.com/celestiaorg/rollmint/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22). Issues with this tag are suitable for a new external contributor and is a great way to find something you can help with!
If you're looking for issues to work on, try looking at the [good first issue list](https://github.com/rollkit/rollkit/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22). Issues with this tag are suitable for a new external contributor and is a great way to find something you can help with!

See [the contributing guide](./CONTRIBUTING.md) for more details.

Please join our [Community Discord](https://discord.com/invite/YsnTPcSfWQ) to ask questions, discuss your ideas, and connect with other contributors.

## Dependency Graph

To see our progress and a possible future of rollmint visit our [Dependency Graph](./docs/specification/rollmint-dependency-graph.md).
To see our progress and a possible future of Rollkit visit our [Dependency Graph](./docs/specification/rollkit-dependency-graph.md).

## Code of Conduct

Expand Down
18 changes: 9 additions & 9 deletions block/manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,19 @@ import (
tmtypes "github.com/tendermint/tendermint/types"
"go.uber.org/multierr"

"github.com/celestiaorg/rollmint/config"
"github.com/celestiaorg/rollmint/da"
"github.com/celestiaorg/rollmint/log"
"github.com/celestiaorg/rollmint/mempool"
"github.com/celestiaorg/rollmint/state"
"github.com/celestiaorg/rollmint/store"
"github.com/celestiaorg/rollmint/types"
"github.com/rollkit/rollkit/config"
"github.com/rollkit/rollkit/da"
"github.com/rollkit/rollkit/log"
"github.com/rollkit/rollkit/mempool"
"github.com/rollkit/rollkit/state"
"github.com/rollkit/rollkit/store"
"github.com/rollkit/rollkit/types"
)

// defaultDABlockTime is used only if DABlockTime is not configured for manager
const defaultDABlockTime = 30 * time.Second

// maxSubmitAttempts defines how many times rollmint will re-try to publish block to DA layer.
// maxSubmitAttempts defines how many times Rollkit will re-try to publish block to DA layer.
// This is temporary solution. It will be removed in future versions.
const maxSubmitAttempts = 30

Expand Down Expand Up @@ -536,7 +536,7 @@ func (m *Manager) submitBlockToDA(ctx context.Context, block *types.Block) error
for attempt := 1; ctx.Err() == nil && !submitted && attempt <= maxSubmitAttempts; attempt++ {
res := m.dalc.SubmitBlock(ctx, block)
if res.Code == da.StatusSuccess {
m.logger.Info("successfully submitted rollmint block to DA layer", "rollmintHeight", block.Header.Height, "daHeight", res.DAHeight)
m.logger.Info("successfully submitted Rollkit block to DA layer", "rollkitHeight", block.Header.Height, "daHeight", res.DAHeight)
submitted = true
} else {
m.logger.Error("DA layer submission failed", "error", res.Message, "attempt", attempt)
Expand Down
10 changes: 5 additions & 5 deletions block/manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ import (
"github.com/tendermint/tendermint/libs/log"
tmtypes "github.com/tendermint/tendermint/types"

"github.com/celestiaorg/rollmint/config"
"github.com/celestiaorg/rollmint/da"
mockda "github.com/celestiaorg/rollmint/da/mock"
"github.com/celestiaorg/rollmint/store"
"github.com/celestiaorg/rollmint/types"
"github.com/rollkit/rollkit/config"
"github.com/rollkit/rollkit/da"
mockda "github.com/rollkit/rollkit/da/mock"
"github.com/rollkit/rollkit/store"
"github.com/rollkit/rollkit/types"
)

func TestInitialState(t *testing.T) {
Expand Down
26 changes: 13 additions & 13 deletions config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,29 +7,29 @@ import (
"github.com/spf13/cobra"
"github.com/spf13/viper"

"github.com/celestiaorg/rollmint/types"
"github.com/rollkit/rollkit/types"
)

const (
flagAggregator = "rollmint.aggregator"
flagDALayer = "rollmint.da_layer"
flagDAConfig = "rollmint.da_config"
flagBlockTime = "rollmint.block_time"
flagDABlockTime = "rollmint.da_block_time"
flagDAStartHeight = "rollmint.da_start_height"
flagNamespaceID = "rollmint.namespace_id"
flagFraudProofs = "rollmint.experimental_insecure_fraud_proofs"
flagLight = "rollmint.light"
flagAggregator = "rollkit.aggregator"
flagDALayer = "rollkit.da_layer"
flagDAConfig = "rollkit.da_config"
flagBlockTime = "rollkit.block_time"
flagDABlockTime = "rollkit.da_block_time"
flagDAStartHeight = "rollkit.da_start_height"
flagNamespaceID = "rollkit.namespace_id"
flagFraudProofs = "rollkit.experimental_insecure_fraud_proofs"
flagLight = "rollkit.light"
)

// NodeConfig stores rollmint node configuration.
// NodeConfig stores Rollkit node configuration.
type NodeConfig struct {
// parameters below are translated from existing config
RootDir string
DBPath string
P2P P2PConfig
RPC RPCConfig
// parameters below are rollmint specific and read from config
// parameters below are Rollkit specific and read from config
Aggregator bool `mapstructure:"aggregator"`
BlockManagerConfig `mapstructure:",squash"`
DALayer string `mapstructure:"da_layer"`
Expand Down Expand Up @@ -70,7 +70,7 @@ func (nc *NodeConfig) GetViperConfig(v *viper.Viper) error {
return nil
}

// AddFlags adds rollmint specific configuration options to cobra Command.
// AddFlags adds Rollkit specific configuration options to cobra Command.
//
// This function is called in cosmos-sdk.
func AddFlags(cmd *cobra.Command) {
Expand Down
2 changes: 1 addition & 1 deletion config/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import (
"github.com/spf13/viper"
"github.com/stretchr/testify/assert"

"github.com/celestiaorg/rollmint/types"
"github.com/rollkit/rollkit/types"
)

func TestViperAndCobra(t *testing.T) {
Expand Down
2 changes: 1 addition & 1 deletion config/defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package config
import (
"time"

"github.com/celestiaorg/rollmint/types"
"github.com/rollkit/rollkit/types"
)

const (
Expand Down
18 changes: 9 additions & 9 deletions conv/abci/block.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ import (
tmversion "github.com/tendermint/tendermint/proto/tendermint/version"
tmtypes "github.com/tendermint/tendermint/types"

"github.com/celestiaorg/rollmint/types"
"github.com/rollkit/rollkit/types"
)

// ToABCIHeaderPB converts rollmint header to Header format defined in ABCI.
// Caller should fill all the fields that are not available in rollmint header (like ChainID).
// ToABCIHeaderPB converts Rollkit header to Header format defined in ABCI.
// Caller should fill all the fields that are not available in Rollkit header (like ChainID).
func ToABCIHeaderPB(header *types.Header) (tmproto.Header, error) {
return tmproto.Header{
Version: tmversion.Consensus{
Expand Down Expand Up @@ -39,8 +39,8 @@ func ToABCIHeaderPB(header *types.Header) (tmproto.Header, error) {
}, nil
}

// ToABCIHeader converts rollmint header to Header format defined in ABCI.
// Caller should fill all the fields that are not available in rollmint header (like ChainID).
// ToABCIHeader converts Rollkit header to Header format defined in ABCI.
// Caller should fill all the fields that are not available in Rollkit header (like ChainID).
func ToABCIHeader(header *types.Header) (tmtypes.Header, error) {
return tmtypes.Header{
Version: tmversion.Consensus{
Expand Down Expand Up @@ -69,7 +69,7 @@ func ToABCIHeader(header *types.Header) (tmtypes.Header, error) {
}, nil
}

// ToABCIBlock converts rollmint block into block format defined by ABCI.
// ToABCIBlock converts Rolkit block into block format defined by ABCI.
// Returned block should pass `ValidateBasic`.
func ToABCIBlock(block *types.Block) (*tmtypes.Block, error) {
abciHeader, err := ToABCIHeader(&block.Header)
Expand Down Expand Up @@ -97,7 +97,7 @@ func ToABCIBlock(block *types.Block) (*tmtypes.Block, error) {
return &abciBlock, nil
}

// ToABCIBlockMeta converts rollmint block into BlockMeta format defined by ABCI
// ToABCIBlockMeta converts Rollkit block into BlockMeta format defined by ABCI
func ToABCIBlockMeta(block *types.Block) (*tmtypes.BlockMeta, error) {
tmblock, err := ToABCIBlock(block)
if err != nil {
Expand All @@ -113,8 +113,8 @@ func ToABCIBlockMeta(block *types.Block) (*tmtypes.BlockMeta, error) {
}, nil
}

// ToABCICommit converts rollmint commit into commit format defined by ABCI.
// This function only converts fields that are available in rollmint commit.
// ToABCICommit converts Rollkit commit into commit format defined by ABCI.
// This function only converts fields that are available in Rollkit commit.
// Other fields (especially ValidatorAddress and Timestamp of Signature) has to be filled by caller.
func ToABCICommit(commit *types.Commit) *tmtypes.Commit {
tmCommit := tmtypes.Commit{
Expand Down
2 changes: 1 addition & 1 deletion conv/addr.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (

"github.com/multiformats/go-multiaddr"

"github.com/celestiaorg/rollmint/config"
"github.com/rollkit/rollkit/config"
)

// TranslateAddresses updates conf by changing Cosmos-style addresses to Multiaddr format.
Expand Down
8 changes: 4 additions & 4 deletions conv/addr_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@ import (
"github.com/multiformats/go-multiaddr"
"github.com/stretchr/testify/assert"

"github.com/celestiaorg/rollmint/config"
"github.com/rollkit/rollkit/config"
)

func TestTranslateAddresses(t *testing.T) {
t.Parallel()

invalidCosmos := "foobar"
validCosmos := "127.0.0.1:1234"
validRollmint := "/ip4/127.0.0.1/tcp/1234"
validRollkit := "/ip4/127.0.0.1/tcp/1234"

cases := []struct {
name string
Expand All @@ -27,13 +27,13 @@ func TestTranslateAddresses(t *testing.T) {
{
"valid listen address",
config.NodeConfig{P2P: config.P2PConfig{ListenAddress: validCosmos}},
config.NodeConfig{P2P: config.P2PConfig{ListenAddress: validRollmint}},
config.NodeConfig{P2P: config.P2PConfig{ListenAddress: validRollkit}},
"",
},
{
"valid seed address",
config.NodeConfig{P2P: config.P2PConfig{Seeds: validCosmos + "," + validCosmos}},
config.NodeConfig{P2P: config.P2PConfig{Seeds: validRollmint + "," + validRollmint}},
config.NodeConfig{P2P: config.P2PConfig{Seeds: validRollkit + "," + validRollkit}},
"",
},
{
Expand Down
4 changes: 2 additions & 2 deletions conv/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ package conv
import (
tmcfg "github.com/tendermint/tendermint/config"

"github.com/celestiaorg/rollmint/config"
"github.com/rollkit/rollkit/config"
)

// GetNodeConfig translates Tendermint's configuration into rollmint configuration.
// GetNodeConfig translates Tendermint's configuration into Rollkit configuration.
//
// This method only translates configuration, and doesn't verify it. If some option is missing in Tendermint's
// config, it's skipped during translation.
Expand Down
2 changes: 1 addition & 1 deletion conv/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (

tmcfg "github.com/tendermint/tendermint/config"

"github.com/celestiaorg/rollmint/config"
"github.com/rollkit/rollkit/config"
)

func TestGetNodeConfig(t *testing.T) {
Expand Down
9 changes: 5 additions & 4 deletions da/celestia/celestia.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ import (
ds "github.com/ipfs/go-datastore"

"github.com/celestiaorg/go-cnc"
"github.com/celestiaorg/rollmint/da"
"github.com/celestiaorg/rollmint/log"
"github.com/celestiaorg/rollmint/types"
pb "github.com/celestiaorg/rollmint/types/pb/rollmint"

"github.com/rollkit/rollkit/da"
"github.com/rollkit/rollkit/log"
"github.com/rollkit/rollkit/types"
pb "github.com/rollkit/rollkit/types/pb/rollkit"
)

// DataAvailabilityLayerClient use celestia-node public API.
Expand Down
11 changes: 6 additions & 5 deletions da/celestia/mock/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@ import (
mux2 "github.com/gorilla/mux"

"github.com/celestiaorg/go-cnc"
"github.com/celestiaorg/rollmint/da"
mockda "github.com/celestiaorg/rollmint/da/mock"
"github.com/celestiaorg/rollmint/log"
"github.com/celestiaorg/rollmint/store"
"github.com/celestiaorg/rollmint/types"

"github.com/rollkit/rollkit/da"
mockda "github.com/rollkit/rollkit/da/mock"
"github.com/rollkit/rollkit/log"
"github.com/rollkit/rollkit/store"
"github.com/rollkit/rollkit/types"
)

// Server mocks celestia-node HTTP API.
Expand Down
8 changes: 4 additions & 4 deletions da/da.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ import (

ds "github.com/ipfs/go-datastore"

"github.com/celestiaorg/rollmint/log"
"github.com/celestiaorg/rollmint/types"
"github.com/rollkit/rollkit/log"
"github.com/rollkit/rollkit/types"
)

// StatusCode is a type for DA layer return status.
// TODO: define an enum of different non-happy-path cases
// that might need to be handled by rollmint independent of
// that might need to be handled by Rollkit independent of
// the underlying DA chain.
type StatusCode uint64

Expand All @@ -37,7 +37,7 @@ type BaseResult struct {
type ResultSubmitBlock struct {
BaseResult
// Not sure if this needs to be bubbled up to other
// parts of rollmint.
// parts of Rollkit.
// Hash hash.Hash
}

Expand Down
Loading

0 comments on commit 567b9f5

Please sign in to comment.