Skip to content

Fix data race in chains/cosmos/log.go getFeePayer() #1169

@KyleMoser

Description

@KyleMoser

In the getFeePayer function, there is a comment on each of the switch statements similar to:

	case *clienttypes.MsgCreateClient:
		// Without this particular special case, there is a panic in ibc-go
		// due to the sdk config singleton expecting one bech32 prefix but seeing another.
		return firstMsg.Signer

Since getFeePayer is only called by Providers, the bech32 prefix should be passed in, and the address computed from the known prefix instead of calling .GetSigners()[0].String(), avoiding this data race altogether.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions