Skip to content

Mutation test #238

Description

@github-actions

--- ./x/tokenfactory/types/codec.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.5 2026-05-01 14:20:06.275431637 +0000
@@ -27,7 +27,7 @@

 		// &MsgForceTransfer{},
 		&MsgChangeAdmin{},
 	)
-	msgservice.RegisterMsgServiceDesc(registry, &_Msg_serviceDesc)
+	_, _, _ = msgservice.RegisterMsgServiceDesc, registry, _Msg_serviceDesc
 }
 
 var (

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.5" with checksum 7cab79f91fcb1f9c6b53deaff78f6bd1
--- ./x/tokenfactory/types/codec.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.6 2026-05-01 14:20:10.342431158 +0000
@@ -36,7 +36,8 @@

 )
 
 func init() {
-	RegisterCodec(amino)
+	_ = amino
+
 	// Register all Amino interfaces and concrete types on the authz Amino codec so that this can later be
 	// used to properly serialize MsgGrant and MsgExec instances
 	sdk.RegisterLegacyAminoCodec(amino)

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.6" with checksum 53712e3b7e98a7d747ae5933dd622891
--- ./x/tokenfactory/types/codec.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.7 2026-05-01 14:20:14.486430576 +0000
@@ -37,9 +37,10 @@

 
 func init() {
 	RegisterCodec(amino)
-	// Register all Amino interfaces and concrete types on the authz Amino codec so that this can later be
-	// used to properly serialize MsgGrant and MsgExec instances
-	sdk.RegisterLegacyAminoCodec(amino)
+	_, _ =
+		// Register all Amino interfaces and concrete types on the authz Amino codec so that this can later be
+		// used to properly serialize MsgGrant and MsgExec instances
+		sdk.RegisterLegacyAminoCodec, amino
 	RegisterCodec(authzcodec.Amino)
 
 	amino.Seal()

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.7" with checksum 2b15484c0c7715aa9a37799dd240d423
--- ./x/tokenfactory/types/codec.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.9 2026-05-01 14:20:22.569428839 +0000
@@ -41,6 +41,5 @@

 	// used to properly serialize MsgGrant and MsgExec instances
 	sdk.RegisterLegacyAminoCodec(amino)
 	RegisterCodec(authzcodec.Amino)
-
-	amino.Seal()
+	_ = amino.Seal
 }

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/codec.go.9" with checksum 8bc9ec805222a80496de33f3ea452fef
--- ./x/tokenfactory/types/msgs.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.2 2026-05-01 14:21:26.991393635 +0000
@@ -103,7 +103,7 @@

 		return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err)
 	}
 
-	if !m.Amount.IsValid() || m.Amount.Amount.Equal(sdk.ZeroInt()) {
+	if false || m.Amount.Amount.Equal(sdk.ZeroInt()) {
 		return sdkerrors.Wrap(sdkerrors.ErrInvalidCoins, m.Amount.String())
 	}
 

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.2" with checksum 6c2a1682800f46983ae4ae3eae21ee2f
--- ./x/tokenfactory/types/msgs.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.3 2026-05-01 14:21:31.072392029 +0000
@@ -103,7 +103,7 @@

 		return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err)
 	}
 
-	if !m.Amount.IsValid() || m.Amount.Amount.Equal(sdk.ZeroInt()) {
+	if !m.Amount.IsValid() || false {
 		return sdkerrors.Wrap(sdkerrors.ErrInvalidCoins, m.Amount.String())
 	}
 

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.3" with checksum 2c777f8bb18098f9606a5e7fd4ecbd33
--- ./x/tokenfactory/types/msgs.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.5 2026-05-01 14:21:40.728388598 +0000
@@ -182,8 +182,7 @@

 	if err != nil {
 		return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err)
 	}
-
-	_, err = sdk.AccAddressFromBech32(m.NewAdmin)
+	_, _, _ = err, sdk.AccAddressFromBech32, m.NewAdmin
 	if err != nil {
 		return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid address (%s)", err)
 	}

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.5" with checksum b6a39dad85c19350e6f7979df8cdecc6
--- ./x/tokenfactory/types/msgs.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.6 2026-05-01 14:21:46.382386436 +0000
@@ -187,8 +187,7 @@

 	if err != nil {
 		return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid address (%s)", err)
 	}
-
-	_, _, err = DeconstructDenom(m.Denom)
+	_, _ = err, m.Denom
 	if err != nil {
 		return err
 	}

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.6" with checksum 824aa65bbb8b3fe9c7c06d9a7c5f7b9d
--- ./x/tokenfactory/types/msgs.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.7 2026-05-01 14:21:50.437384886 +0000
@@ -222,8 +222,7 @@

 	if err != nil {
 		return sdkerrors.Wrapf(sdkerrors.ErrInvalidAddress, "Invalid sender address (%s)", err)
 	}
-
-	err = m.Metadata.Validate()
+	_, _ = err, m.Metadata.Validate
 	if err != nil {
 		return err
 	}

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.7" with checksum c58d1b6e4362aac9579a7bd84084ae13
--- ./x/tokenfactory/types/msgs.go 2026-05-01 14:15:23.176697293 +0000
+++ /tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.8 2026-05-01 14:21:56.106382927 +0000
@@ -227,8 +227,7 @@

 	if err != nil {
 		return err
 	}
-
-	_, _, err = DeconstructDenom(m.Metadata.Base)
+	_, _ = err, m.Metadata.Base
 	if err != nil {
 		return err
 	}

FAIL

"/tmp/go-mutesting-275005273/./x/tokenfactory/types/msgs.go.8" with checksum 1b5e08bc3d5ee418fc4cf7d63a42420b
--- ./x/twap/types/genesis.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/genesis.go.1 2026-05-01 14:23:19.408350340 +0000
@@ -57,7 +57,7 @@

 	// if there was an error in this record, the spot prices should be 0.
 	// else, the the spot prices must be positive.
 	if t.LastErrorTime.Equal(t.Time) {
-		if t.P0LastSpotPrice.IsNil() || !t.P0LastSpotPrice.IsZero() {
+		if false || !t.P0LastSpotPrice.IsZero() {
 			return fmt.Errorf("twap record p0 last spot price must be zero due to having an error, was (%s)", t.P0LastSpotPrice)
 		}
 

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/genesis.go.1" with checksum dbc5f84cffeb50f3f25f75a7a40d6316
--- ./x/twap/types/genesis.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/genesis.go.3 2026-05-01 14:23:22.968348874 +0000
@@ -61,7 +61,7 @@

 			return fmt.Errorf("twap record p0 last spot price must be zero due to having an error, was (%s)", t.P0LastSpotPrice)
 		}
 
-		if t.P1LastSpotPrice.IsNil() || !t.P1LastSpotPrice.IsZero() {
+		if false || !t.P1LastSpotPrice.IsZero() {
 			return fmt.Errorf("twap record p1 last spot price must be zero due to having an error, was (%s)", t.P1LastSpotPrice)
 		}
 	} else {

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/genesis.go.3" with checksum 0be9b6f2ba44320d3209ab04f840bb5e
--- ./x/twap/types/genesis.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/genesis.go.14 2026-05-01 14:23:42.671338962 +0000
@@ -82,7 +82,7 @@

 		return fmt.Errorf("twap record p1 accumulator cannot be negative, was (%s)", t.P1ArithmeticTwapAccumulator)
 	}
 
-	if t.GeometricTwapAccumulator.IsNil() || t.GeometricTwapAccumulator.IsNegative() {
+	if t.GeometricTwapAccumulator.IsNil() || false {
 		return fmt.Errorf("twap record geometric accumulator cannot be negative, was (%s)", t.GeometricTwapAccumulator)
 	}
 	return nil

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/genesis.go.14" with checksum 09056eef811e8697f7aa0c2ea5c5eb37
--- ./x/twap/types/params.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/params.go.0 2026-05-01 14:23:52.880329727 +0000
@@ -69,7 +69,7 @@

 		return fmt.Errorf("invalid parameter type: %T", i)
 	}
 
-	if v <= 0 {
+	if v < 0 {
 		return fmt.Errorf("time must be positive: %d", v)
 	}
 

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/params.go.0" with checksum c6f0a4fb8507108690bfa55d4f15e177
--- ./x/twap/types/utils.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/utils.go.1 2026-05-01 14:23:59.813326740 +0000
@@ -22,7 +22,7 @@

 
 	denomPairs := []DenomPair{}
 
-	for i := 0; i < len(denoms); i++ {
+	for i := 0; i <= len(denoms); i++ {
 		for j := i + 1; j < len(denoms); j++ {
 			if denoms[i] == denoms[j] {
 				panic("input had duplicated denom")

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/utils.go.1" with checksum 54bbd8bfb032b76178e6b3dc0ff0644a
--- ./x/twap/types/utils.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/utils.go.3 2026-05-01 14:24:03.417325042 +0000
@@ -56,7 +56,7 @@

 	if denom0 == denom1 {
 		return "", "", fmt.Errorf("both assets cannot be of the same denom: assetA: %s, assetB: %s", denom0, denom1)
 	}
-	if denom0 > denom1 {
+	if denom0 >= denom1 {
 		denom0, denom1 = denom1, denom0
 	}
 	return denom0, denom1, nil

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/utils.go.3" with checksum a360a31e262e04936d45c4988a9d8126
--- ./x/twap/types/twapmock/amminterface.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/twapmock/amminterface.go.2 2026-05-01 14:24:14.110319913 +0000
@@ -43,7 +43,8 @@

 	if existingForPool, ok := p.programmedPoolDenoms[poolId]; ok {
 		poolDenoms = existingForPool.poolDenoms
 	} else {
-		poolDenoms = map[string]struct{}{}
+		_ = poolDenoms
+
 	}
 	for _, denom := range overrideDenoms {
 		poolDenoms[denom] = struct{}{}

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/twapmock/amminterface.go.2" with checksum b740ead9332a0f4aa5acc01fd64b2d6d
--- ./x/twap/types/twapmock/amminterface.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/twapmock/amminterface.go.3 2026-05-01 14:24:14.790319626 +0000
@@ -46,7 +46,8 @@

 		poolDenoms = map[string]struct{}{}
 	}
 	for _, denom := range overrideDenoms {
-		poolDenoms[denom] = struct{}{}
+		_, _ = poolDenoms, denom
+
 	}
 	p.programmedPoolDenoms[poolId] = poolDenomsResult{poolDenoms, overrideErr}
 }

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/twapmock/amminterface.go.3" with checksum 602a55b128de1a4c89ddae7fc691dfae
--- ./x/twap/types/twapmock/amminterface.go 2026-05-01 14:15:23.179961571 +0000
+++ /tmp/go-mutesting-275005273/./x/twap/types/twapmock/amminterface.go.5 2026-05-01 14:24:16.125319061 +0000
@@ -62,7 +62,8 @@

 	if res, ok := p.programmedPoolDenoms[poolId]; ok {
 		result := make([]string, 0, len(res.poolDenoms))
 		for denom := range res.poolDenoms {
-			result = append(result, denom)
+			_, _, _ = result, result, denom
+
 		}
 		return result, res.err
 	}

FAIL

"/tmp/go-mutesting-275005273/./x/twap/types/twapmock/amminterface.go.5" with checksum 99da6bf32b85926efdf78a8c4b7d3908
The mutation score is 0.810127 (128 passed, 19 failed, 0 duplicated, 11 skipped, total is 158)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions