Skip to content

Commit

Permalink
Cosmos v0.38.5 update
Browse files Browse the repository at this point in the history
See PR #220
  • Loading branch information
RiccardoM authored Jul 6, 2020
1 parent 19d4cbd commit 3822f0d
Show file tree
Hide file tree
Showing 11 changed files with 237 additions and 185 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
- Moved `posts` module constants to chain parameters (#172)
- Added the creation date inside the profile saving event (#210)
- Changed the way times are serialized inside event attributes (#211)
- Updated Cosmos to `v0.38.5`

## Bug fixes
- Fixed a bug inside the `Equals` method of the `Pictures` object
Expand Down Expand Up @@ -45,6 +46,10 @@
- Fixed the account query CLI command (#155)
- Fixed the profile deletion CLI command (#166)

# Version 0.5.3
## Changes
- Updated Cosmos to [v0.38.5](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.38.5)

# Version 0.5.2
## Bug fixes
- Fixed a bug that caused the state export to fail due to [cosmos/cosmos-sdk#6280](https://github.com/cosmos/cosmos-sdk/issues/6280)
Expand Down
2 changes: 1 addition & 1 deletion cmd/desmosd/replay.go
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ func replayTxs(rootDir string) error {

t2 := time.Now()

state, err = blockExec.ApplyBlock(state, blockmeta.BlockID, block)
state, _, err = blockExec.ApplyBlock(state, blockmeta.BlockID, block)
if err != nil {
return err
}
Expand Down
12 changes: 6 additions & 6 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ module github.com/desmos-labs/desmos
go 1.13

require (
github.com/btcsuite/btcd v0.0.0-20190115013929-ed77733ec07d
github.com/cosmos/cosmos-sdk v0.38.4
github.com/btcsuite/btcd v0.20.1-beta
github.com/cosmos/cosmos-sdk v0.38.5
github.com/desmos-labs/Go-Emoji-Utils v1.1.1-0.20200515063516-9c493b11de3e
github.com/gorilla/mux v1.7.3
github.com/otiai10/copy v1.0.2
github.com/spf13/cobra v0.0.6
github.com/spf13/viper v1.6.2
github.com/spf13/cobra v1.0.0
github.com/spf13/viper v1.6.3
github.com/stretchr/testify v1.5.1
github.com/tendermint/go-amino v0.15.1
github.com/tendermint/tendermint v0.33.3
github.com/tendermint/tm-db v0.5.0
github.com/tendermint/tendermint v0.33.6
github.com/tendermint/tm-db v0.5.1
)
54 changes: 50 additions & 4 deletions go.sum

Large diffs are not rendered by default.

36 changes: 18 additions & 18 deletions x/magpie/alias.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,53 +11,53 @@ import (
)

const (
ModuleName = types.ModuleName
RouterKey = types.RouterKey
StoreKey = types.StoreKey
ActionCreationSession = types.ActionCreationSession
QuerySessions = keeper.QuerySessions
OpWeightMsgCreatePost = simulation.OpWeightMsgCreatePost
EventTypeCreateSession = types.EventTypeCreateSession
AttributeKeySessionID = types.AttributeKeySessionID
AttributeKeyNamespace = types.AttributeKeyNamespace
AttributeKeyExternalOwner = types.AttributeKeyExternalOwner
AttributeKeyExpiry = types.AttributeKeyExpiry
AttributeValueCategory = types.AttributeValueCategory
QuerySessions = keeper.QuerySessions
OpWeightMsgCreatePost = simulation.OpWeightMsgCreatePost
ModuleName = types.ModuleName
RouterKey = types.RouterKey
StoreKey = types.StoreKey
ActionCreationSession = types.ActionCreationSession
)

var (
// functions aliases
RandomSessionData = simulation.RandomSessionData
WeightedOperations = simulation.WeightedOperations
SimulateMsgCreateSession = simulation.SimulateMsgCreateSession
RandomizedGenState = simulation.RandomizedGenState
DecodeStore = simulation.DecodeStore
NewMsgCreateSession = types.NewMsgCreateSession
SessionStoreKey = types.SessionStoreKey
ParseSessionID = types.ParseSessionID
NewSession = types.NewSession
RegisterCodec = types.RegisterCodec
NewGenesisState = types.NewGenesisState
DefaultGenesisState = types.DefaultGenesisState
ValidateGenesis = types.ValidateGenesis
RegisterCodec = types.RegisterCodec
SessionStoreKey = types.SessionStoreKey
NewMsgCreateSession = types.NewMsgCreateSession
ParseSessionID = types.ParseSessionID
NewSession = types.NewSession
NewHandler = keeper.NewHandler
NewKeeper = keeper.NewKeeper
NewQuerier = keeper.NewQuerier
DecodeStore = simulation.DecodeStore
RandomizedGenState = simulation.RandomizedGenState
WeightedOperations = simulation.WeightedOperations
SimulateMsgCreateSession = simulation.SimulateMsgCreateSession
RandomSessionData = simulation.RandomSessionData

// variable aliases
RandomNamespaces = simulation.RandomNamespaces
ModuleCdc = types.ModuleCdc
SessionLengthKey = types.SessionLengthKey
LastSessionIDStoreKey = types.LastSessionIDStoreKey
SessionStorePrefix = types.SessionStorePrefix
ModuleCdc = types.ModuleCdc
)

type (
Keeper = keeper.Keeper
SessionData = simulation.SessionData
GenesisState = types.GenesisState
MsgCreateSession = types.MsgCreateSession
SessionID = types.SessionID
Session = types.Session
Sessions = types.Sessions
GenesisState = types.GenesisState
)
96 changes: 48 additions & 48 deletions x/posts/alias.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ const (
OpWeightMsgAnswerPoll = simulation.OpWeightMsgAnswerPoll
OpWeightMsgRegisterReaction = simulation.OpWeightMsgRegisterReaction
DefaultGasValue = simulation.DefaultGasValue
DefaultParamspace = types.DefaultParamspace
EventTypePostCreated = types.EventTypePostCreated
EventTypePostEdited = types.EventTypePostEdited
EventTypePostReactionAdded = types.EventTypePostReactionAdded
Expand All @@ -42,6 +41,7 @@ const (
AttributeKeyReactionShortCode = types.AttributeKeyReactionShortCode
AttributeKeyReactionCreator = types.AttributeKeyReactionCreator
AttributeKeyReactionSubSpace = types.AttributeKeyReactionSubSpace
DefaultParamspace = types.DefaultParamspace
ModuleName = common.ModuleName
RouterKey = common.RouterKey
StoreKey = common.StoreKey
Expand All @@ -65,21 +65,14 @@ const (

var (
// functions aliases
NewKeeper = keeper.NewKeeper
ValidatePost = keeper.ValidatePost
NewQuerier = keeper.NewQuerier
RegisterInvariants = keeper.RegisterInvariants
AllInvariants = keeper.AllInvariants
ValidPostsInvariant = keeper.ValidPostsInvariant
ValidCommentsDateInvariant = keeper.ValidCommentsDateInvariant
ValidPostForReactionsInvariant = keeper.ValidPostForReactionsInvariant
ValidPollForPollAnswersInvariant = keeper.ValidPollForPollAnswersInvariant
NewHandler = keeper.NewHandler
WeightedOperations = simulation.WeightedOperations
SimulateMsgAnswerToPoll = simulation.SimulateMsgAnswerToPoll
SimulateMsgCreatePost = simulation.SimulateMsgCreatePost
SimulateMsgEditPost = simulation.SimulateMsgEditPost
SimulateMsgAddPostReaction = simulation.SimulateMsgAddPostReaction
SimulateMsgRemovePostReaction = simulation.SimulateMsgRemovePostReaction
SimulateMsgRegisterReaction = simulation.SimulateMsgRegisterReaction
SimulateMsgCreatePost = simulation.SimulateMsgCreatePost
SimulateMsgEditPost = simulation.SimulateMsgEditPost
ParamChanges = simulation.ParamChanges
RandomPost = simulation.RandomPost
RandomPostData = simulation.RandomPostData
RandomPostReactionData = simulation.RandomPostReactionData
Expand All @@ -97,55 +90,62 @@ var (
RegisteredReactionsData = simulation.RegisteredReactionsData
RandomEmojiPostReaction = simulation.RandomEmojiPostReaction
RandomParams = simulation.RandomParams
WeightedOperations = simulation.WeightedOperations
RandomizedGenState = simulation.RandomizedGenState
ParamChanges = simulation.ParamChanges
DecodeStore = simulation.DecodeStore
SimulateMsgAnswerToPoll = simulation.SimulateMsgAnswerToPoll
RandomizedGenState = simulation.RandomizedGenState
RegisterCodec = types.RegisterCodec
NewGenesisState = types.NewGenesisState
DefaultGenesisState = types.DefaultGenesisState
ValidateGenesis = types.ValidateGenesis
ParamKeyTable = types.ParamKeyTable
NewParams = types.NewParams
DefaultParams = types.DefaultParams
ValidateMaxPostMessageLengthParam = types.ValidateMaxPostMessageLengthParam
ValidateMaxOptionalDataFieldNumberParam = types.ValidateMaxOptionalDataFieldNumberParam
ValidateMaxOptionalDataFieldValueLengthParam = types.ValidateMaxOptionalDataFieldValueLengthParam
DefaultQueryPostsParams = types.DefaultQueryPostsParams
NewGenesisState = types.NewGenesisState
DefaultGenesisState = types.DefaultGenesisState
ValidateGenesis = types.ValidateGenesis
NewPostResponse = models.NewPostResponse
RegisterModelsCodec = models.RegisterModelsCodec
PostStoreKey = models.PostStoreKey
PostCommentsStoreKey = models.PostCommentsStoreKey
PostReactionsStoreKey = models.PostReactionsStoreKey
ReactionsStoreKey = models.ReactionsStoreKey
PollAnswersStoreKey = models.PollAnswersStoreKey
RegisterModelsCodec = models.RegisterModelsCodec
ComputeID = models.ComputeID
ParsePostID = models.ParsePostID
NewPost = models.NewPost
NewPostResponse = models.NewPostResponse
GetEmojiByShortCodeOrValue = common.GetEmojiByShortCodeOrValue
NewPostMedia = common.NewPostMedia
ValidateURI = common.ValidateURI
NewPostMedias = common.NewPostMedias
ParseAnswerID = polls.ParseAnswerID
NewPollAnswer = polls.NewPollAnswer
NewPollAnswers = polls.NewPollAnswers
GetEmojiByShortCodeOrValue = common.GetEmojiByShortCodeOrValue
NewPollData = polls.NewPollData
ArePollDataEquals = polls.ArePollDataEquals
NewUserAnswer = polls.NewUserAnswer
NewUserAnswers = polls.NewUserAnswers
ParseAnswerID = polls.ParseAnswerID
NewPollAnswer = polls.NewPollAnswer
NewPollAnswers = polls.NewPollAnswers
NewPostReaction = reactions.NewPostReaction
NewPostReactions = reactions.NewPostReactions
NewReaction = reactions.NewReaction
IsEmoji = reactions.IsEmoji
NewReactions = reactions.NewReactions
RegisterMessagesCodec = msgs.RegisterMessagesCodec
NewMsgCreatePost = msgs.NewMsgCreatePost
NewMsgEditPost = msgs.NewMsgEditPost
NewMsgRegisterReaction = msgs.NewMsgRegisterReaction
RegisterMessagesCodec = msgs.RegisterMessagesCodec
NewMsgAnswerPoll = msgs.NewMsgAnswerPoll
NewMsgAddPostReaction = msgs.NewMsgAddPostReaction
NewMsgRemovePostReaction = msgs.NewMsgRemovePostReaction
NewMsgAnswerPoll = msgs.NewMsgAnswerPoll
NewMsgRegisterReaction = msgs.NewMsgRegisterReaction
NewQuerier = keeper.NewQuerier
ValidatePost = keeper.ValidatePost
NewHandler = keeper.NewHandler
RegisterInvariants = keeper.RegisterInvariants
AllInvariants = keeper.AllInvariants
ValidPostsInvariant = keeper.ValidPostsInvariant
ValidCommentsDateInvariant = keeper.ValidCommentsDateInvariant
ValidPostForReactionsInvariant = keeper.ValidPostForReactionsInvariant
ValidPollForPollAnswersInvariant = keeper.ValidPollForPollAnswersInvariant
NewKeeper = keeper.NewKeeper

// variable aliases
RandomMimeTypes = simulation.RandomMimeTypes
Expand All @@ -172,37 +172,37 @@ var (
)

type (
PostMedia = common.PostMedia
PostMedias = common.PostMedias
OptionalData = common.OptionalData
KeyValue = common.KeyValue
PollData = polls.PollData
UserAnswer = polls.UserAnswer
UserAnswers = polls.UserAnswers
AnswerID = polls.AnswerID
PollAnswer = polls.PollAnswer
PollAnswers = polls.PollAnswers
PostReaction = reactions.PostReaction
PostReactions = reactions.PostReactions
Reaction = reactions.Reaction
Reactions = reactions.Reactions
MsgCreatePost = msgs.MsgCreatePost
MsgEditPost = msgs.MsgEditPost
MsgRegisterReaction = msgs.MsgRegisterReaction
MsgAnswerPoll = msgs.MsgAnswerPoll
MsgAddPostReaction = msgs.MsgAddPostReaction
MsgRemovePostReaction = msgs.MsgRemovePostReaction
MsgAnswerPoll = msgs.MsgAnswerPoll
MsgRegisterReaction = msgs.MsgRegisterReaction
Keeper = keeper.Keeper
PostData = simulation.PostData
PostReactionData = simulation.PostReactionData
ReactionData = simulation.ReactionData
GenesisState = types.GenesisState
Params = types.Params
QueryPostsParams = types.QueryPostsParams
GenesisState = types.GenesisState
PostQueryResponse = models.PostQueryResponse
PollAnswersQueryResponse = models.PollAnswersQueryResponse
PostID = models.PostID
PostIDs = models.PostIDs
Post = models.Post
Posts = models.Posts
PostQueryResponse = models.PostQueryResponse
PollAnswersQueryResponse = models.PollAnswersQueryResponse
OptionalData = common.OptionalData
KeyValue = common.KeyValue
PostMedia = common.PostMedia
PostMedias = common.PostMedias
AnswerID = polls.AnswerID
PollAnswer = polls.PollAnswer
PollAnswers = polls.PollAnswers
PollData = polls.PollData
UserAnswer = polls.UserAnswer
UserAnswers = polls.UserAnswers
PostReaction = reactions.PostReaction
PostReactions = reactions.PostReactions
Reaction = reactions.Reaction
Reactions = reactions.Reactions
)
60 changes: 30 additions & 30 deletions x/posts/internal/types/alias.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,6 @@ const (

var (
// functions aliases
ComputeID = models.ComputeID
ParsePostID = models.ParsePostID
NewPost = models.NewPost
NewPostResponse = models.NewPostResponse
PostStoreKey = models.PostStoreKey
PostCommentsStoreKey = models.PostCommentsStoreKey
PostReactionsStoreKey = models.PostReactionsStoreKey
ReactionsStoreKey = models.ReactionsStoreKey
PollAnswersStoreKey = models.PollAnswersStoreKey
RegisterModelsCodec = models.RegisterModelsCodec
NewPostMedia = common.NewPostMedia
ValidateURI = common.ValidateURI
NewPostMedias = common.NewPostMedias
Expand All @@ -62,15 +52,27 @@ var (
NewReaction = reactions.NewReaction
IsEmoji = reactions.IsEmoji
NewReactions = reactions.NewReactions
NewMsgAddPostReaction = msgs.NewMsgAddPostReaction
NewMsgRemovePostReaction = msgs.NewMsgRemovePostReaction
NewMsgAnswerPoll = msgs.NewMsgAnswerPoll
RegisterMessagesCodec = msgs.RegisterMessagesCodec
NewMsgCreatePost = msgs.NewMsgCreatePost
NewMsgEditPost = msgs.NewMsgEditPost
NewMsgAnswerPoll = msgs.NewMsgAnswerPoll
NewMsgAddPostReaction = msgs.NewMsgAddPostReaction
NewMsgRemovePostReaction = msgs.NewMsgRemovePostReaction
NewMsgRegisterReaction = msgs.NewMsgRegisterReaction
RegisterMessagesCodec = msgs.RegisterMessagesCodec
RegisterModelsCodec = models.RegisterModelsCodec
PostStoreKey = models.PostStoreKey
PostCommentsStoreKey = models.PostCommentsStoreKey
PostReactionsStoreKey = models.PostReactionsStoreKey
ReactionsStoreKey = models.ReactionsStoreKey
PollAnswersStoreKey = models.PollAnswersStoreKey
ComputeID = models.ComputeID
ParsePostID = models.ParsePostID
NewPost = models.NewPost
NewPostResponse = models.NewPostResponse

// variable aliases
MsgsCodec = msgs.MsgsCodec
ModelsCdc = models.ModelsCdc
Sha256RegEx = common.Sha256RegEx
HashtagRegEx = common.HashtagRegEx
ShortCodeRegEx = common.ShortCodeRegEx
Expand All @@ -81,35 +83,33 @@ var (
PostReactionsStorePrefix = common.PostReactionsStorePrefix
ReactionsStorePrefix = common.ReactionsStorePrefix
PollAnswersStorePrefix = common.PollAnswersStorePrefix
MsgsCodec = msgs.MsgsCodec
ModelsCdc = models.ModelsCdc
)

type (
PostMedia = common.PostMedia
PostMedias = common.PostMedias
OptionalData = common.OptionalData
KeyValue = common.KeyValue
AnswerID = polls.AnswerID
PollAnswer = polls.PollAnswer
PollAnswers = polls.PollAnswers
PollData = polls.PollData
UserAnswer = polls.UserAnswer
UserAnswers = polls.UserAnswers
PostReaction = reactions.PostReaction
PostReactions = reactions.PostReactions
Reaction = reactions.Reaction
Reactions = reactions.Reactions
MsgAddPostReaction = msgs.MsgAddPostReaction
MsgRemovePostReaction = msgs.MsgRemovePostReaction
MsgAnswerPoll = msgs.MsgAnswerPoll
MsgCreatePost = msgs.MsgCreatePost
MsgEditPost = msgs.MsgEditPost
MsgAnswerPoll = msgs.MsgAnswerPoll
MsgAddPostReaction = msgs.MsgAddPostReaction
MsgRemovePostReaction = msgs.MsgRemovePostReaction
MsgRegisterReaction = msgs.MsgRegisterReaction
PollAnswersQueryResponse = models.PollAnswersQueryResponse
PostID = models.PostID
PostIDs = models.PostIDs
Post = models.Post
Posts = models.Posts
PostQueryResponse = models.PostQueryResponse
PollAnswersQueryResponse = models.PollAnswersQueryResponse
PostMedia = common.PostMedia
PostMedias = common.PostMedias
OptionalData = common.OptionalData
KeyValue = common.KeyValue
AnswerID = polls.AnswerID
PollAnswer = polls.PollAnswer
PollAnswers = polls.PollAnswers
PollData = polls.PollData
UserAnswer = polls.UserAnswer
UserAnswers = polls.UserAnswers
)
Loading

0 comments on commit 3822f0d

Please sign in to comment.