Skip to content

Commit

Permalink
chore(staking): add delegator to events (#18006)
Browse files Browse the repository at this point in the history
(cherry picked from commit b170ccc)

# Conflicts:
#	x/staking/keeper/msg_server.go
  • Loading branch information
tac0turtle authored and mergify[bot] committed Oct 9, 2023
1 parent d7c4bfd commit 1be4ec3
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions x/staking/keeper/msg_server.go
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,7 @@ func (k msgServer) Delegate(goCtx context.Context, msg *types.MsgDelegate) (*typ
sdk.NewEvent(
types.EventTypeDelegate,
sdk.NewAttribute(types.AttributeKeyValidator, msg.ValidatorAddress),
sdk.NewAttribute(types.AttributeKeyDelegator, msg.DelegatorAddress),
sdk.NewAttribute(sdk.AttributeKeyAmount, msg.Amount.String()),
sdk.NewAttribute(types.AttributeKeyNewShares, newShares.String()),
),
Expand Down Expand Up @@ -358,7 +359,12 @@ func (k msgServer) Undelegate(goCtx context.Context, msg *types.MsgUndelegate) (
sdk.NewEvent(
types.EventTypeUnbond,
sdk.NewAttribute(types.AttributeKeyValidator, msg.ValidatorAddress),
<<<<<<< HEAD

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / dependency-review

expected operand, found '<<'

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

syntax error: unexpected <<, expecting expression

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

expected operand, found '<<' (typecheck)

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (02)

syntax error: unexpected <<, expecting expression

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected <<, expecting expression

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected <<, expecting expression

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected <<, expecting expression

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected <<, expecting expression

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected <<, expecting expression

Check failure on line 362 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected <<, expecting expression
sdk.NewAttribute(sdk.AttributeKeyAmount, msg.Amount.String()),

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

syntax error: unexpected ) in composite literal; possibly missing comma or }

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (02)

syntax error: unexpected ) in composite literal; possibly missing comma or }

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected ) in composite literal; possibly missing comma or }

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected ) in composite literal; possibly missing comma or }

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected ) in composite literal; possibly missing comma or }

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected ) in composite literal; possibly missing comma or }

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected ) in composite literal; possibly missing comma or }

Check failure on line 363 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected ) in composite literal; possibly missing comma or }
=======

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

syntax error: unexpected ==, expecting expression

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (02)

syntax error: unexpected ==, expecting expression

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected ==, expecting expression

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected ==, expecting expression

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected ==, expecting expression

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected ==, expecting expression

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected ==, expecting expression

Check failure on line 364 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected ==, expecting expression
sdk.NewAttribute(types.AttributeKeyDelegator, msg.DelegatorAddress),

Check failure on line 365 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

syntax error: unexpected ), expecting := or = or comma

Check failure on line 365 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (02)

syntax error: unexpected ), expecting := or = or comma

Check failure on line 365 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected ), expecting := or = or comma

Check failure on line 365 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected ), expecting := or = or comma

Check failure on line 365 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected ), expecting := or = or comma
sdk.NewAttribute(sdk.AttributeKeyAmount, undelegatedCoin.String()),
>>>>>>> b170ccc45 (chore(staking): add delegator to events (#18006))

Check failure on line 367 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / dependency-review

illegal character U+0023 '#'

Check failure on line 367 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

invalid character U+0023 '#'

Check failure on line 367 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

illegal character U+0023 '#' (typecheck)

Check failure on line 367 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (02)

invalid character U+0023 '#'

Check failure on line 367 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

invalid character U+0023 '#'

Check failure on line 367 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

invalid character U+0023 '#'

Check failure on line 367 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

invalid character U+0023 '#'
sdk.NewAttribute(types.AttributeKeyCompletionTime, completionTime.Format(time.RFC3339)),
),

Check failure on line 369 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

syntax error: unexpected ), expecting expression

Check failure on line 369 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (02)

syntax error: unexpected ), expecting expression

Check failure on line 369 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected ), expecting expression

Check failure on line 369 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected ), expecting expression

Check failure on line 369 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected ), expecting expression
})

Check failure on line 370 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / golangci-lint

syntax error: unexpected ) after top level declaration (typecheck)

Check failure on line 370 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (02)

syntax error: unexpected ) after top level declaration

Check failure on line 370 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (03)

syntax error: unexpected ) after top level declaration

Check failure on line 370 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (01)

syntax error: unexpected ) after top level declaration

Check failure on line 370 in x/staking/keeper/msg_server.go

View workflow job for this annotation

GitHub Actions / tests (00)

syntax error: unexpected ) after top level declaration
Expand Down

0 comments on commit 1be4ec3

Please sign in to comment.