Skip to content

Commit

Permalink
chore: revert consensus breaking changes
Browse files Browse the repository at this point in the history
  • Loading branch information
rach-id committed Oct 11, 2023
1 parent 1e922d7 commit a27b5a0
Show file tree
Hide file tree
Showing 12 changed files with 185 additions and 189 deletions.
4 changes: 2 additions & 2 deletions app/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
v1 "github.com/celestiaorg/celestia-app/pkg/appconsts/v1"
v2 "github.com/celestiaorg/celestia-app/pkg/appconsts/v2"
"github.com/celestiaorg/celestia-app/x/blob"
"github.com/celestiaorg/celestia-app/x/blobstream"
"github.com/celestiaorg/celestia-app/x/mint"
"github.com/celestiaorg/celestia-app/x/qgb"
"github.com/cosmos/cosmos-sdk/types/module"
"github.com/cosmos/cosmos-sdk/x/auth"
"github.com/cosmos/cosmos-sdk/x/auth/vesting"
Expand Down Expand Up @@ -48,7 +48,7 @@ var (
"genutil": genutil.AppModule{}.ConsensusVersion(),
"capability": capability.AppModule{}.ConsensusVersion(),
"blob": blob.AppModule{}.ConsensusVersion(),
"qgb": qgb.AppModule{}.ConsensusVersion(),
"qgb": blobstream.AppModule{}.ConsensusVersion(),
"ibc": ibc.AppModule{}.ConsensusVersion(),
"transfer": transfer.AppModule{}.ConsensusVersion(),
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
syntax = "proto3";
package celestia.blobstream.v1;
package celestia.qgb.v1;

import "gogoproto/gogo.proto";
import "celestia/blobstream/v1/types.proto";
import "celestia/qgb/v1/types.proto";

option go_package = "github.com/celestiaorg/celestia-app/x/blobstream/types";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
syntax = "proto3";
package celestia.blobstream.v1;
package celestia.qgb.v1;

import "celestia/blobstream/v1/genesis.proto";
import "celestia/blobstream/v1/types.proto";
import "celestia/qgb/v1/genesis.proto";
import "celestia/qgb/v1/types.proto";
import "google/api/annotations.proto";
import "gogoproto/gogo.proto";
import "cosmos_proto/cosmos.proto";
Expand All @@ -14,7 +14,7 @@ option go_package = "github.com/celestiaorg/celestia-app/x/blobstream/types";
service Query {
// Params queries the current parameters for the blobstream module
rpc Params(QueryParamsRequest) returns (QueryParamsResponse) {
option (google.api.http).get = "/blobstream/v1/params";
option (google.api.http).get = "/qgb/v1/params";
}

// queries for attestations requests waiting to be signed by an orchestrator
Expand All @@ -23,12 +23,12 @@ service Query {
// Returns nil if not found.
rpc AttestationRequestByNonce(QueryAttestationRequestByNonceRequest)
returns (QueryAttestationRequestByNonceResponse) {
option (google.api.http).get = "/blobstream/v1/attestations/requests/{nonce}";
option (google.api.http).get = "/qgb/v1/attestations/requests/{nonce}";
}
// LatestAttestationNonce queries latest attestation nonce.
rpc LatestAttestationNonce(QueryLatestAttestationNonceRequest)
returns (QueryLatestAttestationNonceResponse) {
option (google.api.http).get = "/blobstream/v1/attestations/nonce/latest";
option (google.api.http).get = "/qgb/v1/attestations/nonce/latest";
}
// LatestValsetRequestBeforeNonce Queries latest Valset request before nonce.
// And, even if the current nonce is a valset, it will return the previous
Expand All @@ -37,34 +37,34 @@ service Query {
// no valset before nonce 1.
rpc LatestValsetRequestBeforeNonce(QueryLatestValsetRequestBeforeNonceRequest)
returns (QueryLatestValsetRequestBeforeNonceResponse) {
option (google.api.http).get = "/blobstream/v1/valset/request/before/{nonce}";
option (google.api.http).get = "/qgb/v1/valset/request/before/{nonce}";
}

// misc

// LatestUnbondingHeight returns the latest unbonding height
rpc LatestUnbondingHeight(QueryLatestUnbondingHeightRequest)
returns (QueryLatestUnbondingHeightResponse) {
option (google.api.http).get = "/blobstream/v1/unbonding";
option (google.api.http).get = "/qgb/v1/unbonding";
}

// DataCommitmentRangeForHeight returns the data commitment window
// that includes the provided height
rpc DataCommitmentRangeForHeight(QueryDataCommitmentRangeForHeightRequest)
returns (QueryDataCommitmentRangeForHeightResponse) {
option (google.api.http).get = "/blobstream/v1/data_commitment/range/height";
option (google.api.http).get = "/qgb/v1/data_commitment/range/height";
}

// LatestDataCommitment returns the latest data commitment in store
rpc LatestDataCommitment(QueryLatestDataCommitmentRequest)
returns (QueryLatestDataCommitmentResponse) {
option (google.api.http).get = "/blobstream/v1/data_commitment/latest";
option (google.api.http).get = "/qgb/v1/data_commitment/latest";
}

// EVMAddress returns the evm address associated with a supplied
// validator address
rpc EVMAddress(QueryEVMAddressRequest) returns (QueryEVMAddressResponse) {
option (google.api.http).get = "/blobstream/v1/evm_address";
option (google.api.http).get = "/qgb/v1/evm_address";
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
syntax = "proto3";
package celestia.blobstream.v1;
package celestia.qgb.v1;

import "gogoproto/gogo.proto";
import "cosmos_proto/cosmos.proto";
Expand All @@ -16,7 +16,7 @@ service Msg {
// state machine.
rpc RegisterEVMAddress(MsgRegisterEVMAddress)
returns (MsgRegisterEVMAddressResponse) {
option (google.api.http).get = "/blobstream/v1/register_evm_address";
option (google.api.http).get = "/qgb/v1/register_evm_address";
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
syntax = "proto3";
package celestia.blobstream.v1;
package celestia.qgb.v1;

import "gogoproto/gogo.proto";
import "cosmos_proto/cosmos.proto";
Expand Down
6 changes: 3 additions & 3 deletions test/util/genesis/modifier.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (

"github.com/celestiaorg/celestia-app/app"
blobtypes "github.com/celestiaorg/celestia-app/x/blob/types"
qgbtypes "github.com/celestiaorg/celestia-app/x/qgb/types"
bstypes "github.com/celestiaorg/celestia-app/x/blobstream/types"
"github.com/cosmos/cosmos-sdk/codec"
sdk "github.com/cosmos/cosmos-sdk/types"
authtypes "github.com/cosmos/cosmos-sdk/x/auth/types"
Expand Down Expand Up @@ -49,9 +49,9 @@ func ImmediateProposals(codec codec.Codec) Modifier {
// qgb module's genesis state.
func SetDataCommitmentWindow(codec codec.Codec, window uint64) Modifier {
return func(state map[string]json.RawMessage) map[string]json.RawMessage {
qgbGenState := qgbtypes.DefaultGenesis()
qgbGenState := bstypes.DefaultGenesis()
qgbGenState.Params.DataCommitmentWindow = window
state[qgbtypes.ModuleName] = codec.MustMarshalJSON(qgbGenState)
state[bstypes.ModuleName] = codec.MustMarshalJSON(qgbGenState)
return state
}
}
Expand Down
50 changes: 24 additions & 26 deletions x/blobstream/types/genesis.pb.go

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

Loading

0 comments on commit a27b5a0

Please sign in to comment.