Repository: initia-labs/initia
Pull request #354: feat: audit
Author: login: beer-1
Created: 2025-03-01T08:51:47Z | Merged: 2025-03-04T11:35:45Z

# Description

Closes: #XXXX

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->

---

## Author Checklist

_All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues._

I have...

- [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title, you can find examples of the prefixes below:
  <!-- * `feat`: A new feature
  * `fix`: A bug fix
  * `docs`: Documentation only changes
  * `style`: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc)
  * `refactor`: A code change that neither fixes a bug nor adds a feature
  * `perf`: A code change that improves performance
  * `test`: Adding missing tests or correcting existing tests
  * `build`: Changes that affect the build system or external dependencies (example scopes: gulp, broccoli, npm)
  * `ci`: Changes to our CI configuration files and scripts (example scopes: Travis, Circle, BrowserStack, SauceLabs)
  * `chore`: Other changes that don't modify src or test files
  * `revert`: Reverts a previous commit -->
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] targeted the correct branch
- [ ] provided a link to the relevant issue or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] included the necessary unit and integration tests
- [ ] updated the relevant documentation or specification, including comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] confirmed all CI checks have passed

## Reviewers Checklist

_All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items._

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed all author checklist items have been addressed
- [ ] reviewed state machine logic, API design and naming, documentation is accurate, tests and test coverage



Diff:
diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml
index 05c9a566c..83f2bef46 100644
--- a/.github/workflows/docker.yml
+++ b/.github/workflows/docker.yml
@@ -11,13 +11,6 @@ on:
       - "**.go"
       - "go.mod"
       - "go.sum"
-  pull_request:
-    branches:
-      - "main"
-    paths:
-      - "**.go"
-      - "go.mod"
-      - "go.sum"
 
 env:
   REGISTRY: ghcr.io
@@ -61,6 +54,8 @@ jobs:
           push: ${{ startsWith(github.ref, 'refs/tags') }} # push image only for tags
           tags: ${{ steps.meta.outputs.tags }}
           labels: ${{ steps.meta.outputs.labels }}
+        env:
+          VERSION: ${{ github.ref_name }}
 
   node:
     if: ${{ startsWith(github.ref, 'refs/tags/') }}
diff --git a/x/distribution/keeper/allocation.go b/x/distribution/keeper/allocation.go
index dc9ad13e4..bff2c63fc 100644
--- a/x/distribution/keeper/allocation.go
+++ b/x/distribution/keeper/allocation.go
@@ -80,7 +80,7 @@ func (k Keeper) AllocateTokens(ctx context.Context, totalPreviousPower int64, bo
 
 	// allocate rewards proportionally to reward power
 	for _, rewardWeight := range rewardWeights {
-		poolFraction := rewardWeight.Weight.Quo(weightsSum)
+		poolFraction := rewardWeight.Weight.QuoTruncate(weightsSum)
 		poolReward := feesCollected.MulDecTruncate(voteMultiplier).MulDecTruncate(poolFraction)
 
 		poolDenom := rewardWeight.Denom
diff --git a/x/distribution/keeper/genesis.go b/x/distribution/keeper/genesis.go
index 61d9e8947..cfbb561a6 100644
--- a/x/distribution/keeper/genesis.go
+++ b/x/distribution/keeper/genesis.go
@@ -122,7 +122,14 @@ func (k Keeper) InitGenesis(ctx sdk.Context, data customtypes.GenesisState) {
 	if balances.IsZero() {
 		k.authKeeper.SetModuleAccount(ctx, moduleAcc)
 	}
-	if !balances.Equal(moduleHoldingsInt) {
+
+	// It is hard to block fungible asset transfer from move side,
+	// so we can't guarantee the ModuleAccount is always equal to the sum
+	// of the distribution rewards and community pool. Instead, we decide to check
+	// if the ModuleAccount balance is greater than or equal to the sum of
+	// the distribution rewards and community pool.
+	broken := !balances.IsAllGTE(moduleHoldingsInt)
+	if broken {
 		panic(fmt.Sprintf("distribution module balance does not match the module holdings: %s <-> %s", balances, moduleHoldingsInt))
 	}
 }
diff --git a/x/evidence/keeper/msg_server.go b/x/evidence/keeper/msg_server.go
index fa3a14fca..46419e20c 100644
--- a/x/evidence/keeper/msg_server.go
+++ b/x/evidence/keeper/msg_server.go
@@ -3,8 +3,11 @@ package keeper
 import (
 	"context"
 
+	"cosmossdk.io/errors"
 	"cosmossdk.io/x/evidence/types"
+
 	sdk "github.com/cosmos/cosmos-sdk/types"
+	sdkerrors "github.com/cosmos/cosmos-sdk/types/errors"
 )
 
 type msgServer struct {
@@ -21,9 +24,20 @@ var _ types.MsgServer = msgServer{}
 
 // SubmitEvidence implements the MsgServer.SubmitEvidence method.
 func (ms msgServer) SubmitEvidence(goCtx context.Context, msg *types.MsgSubmitEvidence) (*types.MsgSubmitEvidenceResponse, error) {
-	ctx := sdk.UnwrapSDKContext(goCtx)
+	if _, err := ms.addressCodec.StringToBytes(msg.Submitter); err != nil {
+		return nil, sdkerrors.ErrInvalidAddress.Wrapf("invalid submitter address: %s", err)
+	}
 
 	evidence := msg.GetEvidence()
+	if evidence == nil {
+		return nil, errors.Wrap(types.ErrInvalidEvidence, "missing evidence")
+	}
+
+	if err := evidence.ValidateBasic(); err != nil {
+		return nil, errors.Wrapf(types.ErrInvalidEvidence, "failed basic validation: %s", err)
+	}
+
+	ctx := sdk.UnwrapSDKContext(goCtx)
 	if err := ms.Keeper.SubmitEvidence(ctx, evidence); err != nil {
 		return nil, err
 	}
diff --git a/x/ibc-hooks/move-hooks/receive.go b/x/ibc-hooks/move-hooks/receive.go
index 25a578ff3..4f024824f 100644
--- a/x/ibc-hooks/move-hooks/receive.go
+++ b/x/ibc-hooks/move-hooks/receive.go
@@ -22,7 +22,7 @@ func (h MoveHooks) onRecvIcs20Packet(
 	data transfertypes.FungibleTokenPacketData,
 ) ibcexported.Acknowledgement {
 	isMoveRouted, hookData, err := validateAndParseMemo(data.GetMemo())
-	if !isMoveRouted || hookData.Message == nil {
+	if !isMoveRouted || (err == nil && hookData.Message == nil) {
 		return im.App.OnRecvPacket(ctx, packet, relayer)
 	} else if err != nil {
 		return newEmitErrorAcknowledgement(err)
@@ -74,7 +74,7 @@ func (h MoveHooks) onRecvIcs721Packet(
 	data nfttransfertypes.NonFungibleTokenPacketData,
 ) ibcexported.Acknowledgement {
 	isMoveRouted, hookData, err := validateAndParseMemo(data.GetMemo())
-	if !isMoveRouted || hookData.Message == nil {
+	if !isMoveRouted || (err == nil && hookData.Message == nil) {
 		return im.App.OnRecvPacket(ctx, packet, relayer)
 	} else if err != nil {
 		return newEmitErrorAcknowledgement(err)
diff --git a/x/intertx/keeper/msg_server.go b/x/intertx/keeper/msg_server.go
index 9d945535d..e02026a76 100644
--- a/x/intertx/keeper/msg_server.go
+++ b/x/intertx/keeper/msg_server.go
@@ -37,7 +37,15 @@ func (k msgServer) RegisterAccount(goCtx context.Context, msg *types.MsgRegister
 	icaMsg := icacontrollertypes.NewMsgRegisterInterchainAccount(msg.ConnectionId, msg.Owner, msg.Version)
 	icaMsg.Ordering = msg.Ordering
 
-	if _, err := k.icaControllerMsgServer.RegisterInterchainAccount(ctx, icaMsg); err != nil {
+	// validate the icaMsg
+	err := icaMsg.ValidateBasic()
+	if err != nil {
+		return nil, err
+	}
+
+	// send the icaMsg to the ica controller
+	_, err = k.icaControllerMsgServer.RegisterInterchainAccount(ctx, icaMsg)
+	if err != nil {
 		return nil, err
 	}
 
@@ -64,6 +72,14 @@ func (k msgServer) SubmitTx(goCtx context.Context, msg *types.MsgSubmitTx) (*typ
 
 	relativeTimeoutTimestamp := uint64((time.Minute * 5).Nanoseconds())
 	icaMsg := icacontrollertypes.NewMsgSendTx(msg.Owner, msg.ConnectionId, uint64(relativeTimeoutTimestamp), packetData)
+
+	// validate the icaMsg
+	err = icaMsg.ValidateBasic()
+	if err != nil {
+		return nil, err
+	}
+
+	// send the icaMsg to the ica controller
 	_, err = k.icaControllerMsgServer.SendTx(ctx, icaMsg)
 	if err != nil {
 		return nil, err
diff --git a/x/move/keeper/genesis.go b/x/move/keeper/genesis.go
index ee98d7776..2bffb97f3 100644
--- a/x/move/keeper/genesis.go
+++ b/x/move/keeper/genesis.go
@@ -68,7 +68,7 @@ func (k Keeper) Initialize(
 		}
 	}
 
-	return k.handleExecuteResponse(sdkCtx, sdkCtx.GasMeter(), execRes)
+	return nil
 }
 
 // InitGenesis sets supply information for genesis.
diff --git a/x/move/keeper/handler.go b/x/move/keeper/handler.go
index 24737793d..f2d2bf18a 100644
--- a/x/move/keeper/handler.go
+++ b/x/move/keeper/handler.go
@@ -391,7 +391,13 @@ func (k Keeper) dispatchMessage(parentCtx sdk.Context, message vmtypes.CosmosMes
 	ctx, commit := parentCtx.CacheContext()
 	defer func() {
 		if r := recover(); r != nil {
-			err = fmt.Errorf("panic: %v", r)
+			switch r.(type) {
+			case storetypes.ErrorOutOfGas:
+				// propagate out of gas error
+				panic(r)
+			default:
+				err = fmt.Errorf("panic: %v", r)
+			}
 		}
 
 		success := err == nil
@@ -580,28 +586,25 @@ func (k Keeper) executeViewFunction(
 		return vmtypes.ViewOutput{}, 0, err
 	}
 
-	executionCounter, err := k.ExecutionCounter.Next(ctx)
+	ac := types.NextAccountNumber(ctx, k.authKeeper)
+	ec, err := k.ExecutionCounter.Next(ctx)
 	if err != nil {
 		return vmtypes.ViewOutput{}, 0, err
 	}
 
-	api := NewApi(k, ctx)
-	env := types.NewEnv(
-		ctx,
-		types.NextAccountNumber(ctx, k.authKeeper),
-		executionCounter,
-	)
-
 	sdkCtx := sdk.UnwrapSDKContext(ctx)
 	gasMeter := sdkCtx.GasMeter()
 	gasForRuntime := k.computeGasForRuntime(ctx, gasMeter)
 
+	// delegate gas metering to move vm
+	sdkCtx = sdkCtx.WithGasMeter(storetypes.NewInfiniteGasMeter())
+
 	gasBalance := gasForRuntime
 	viewRes, err := k.initiaMoveVM.ExecuteViewFunction(
 		&gasBalance,
-		types.NewVMStore(ctx, k.VMStore),
-		api,
-		env,
+		types.NewVMStore(sdkCtx, k.VMStore),
+		NewApi(k, sdkCtx),
+		types.NewEnv(sdkCtx, ac, ec),
 		payload,
 	)
 
diff --git a/x/move/types/connector.go b/x/move/types/connector.go
index 90b5fa529..28bf7f5e4 100644
--- a/x/move/types/connector.go
+++ b/x/move/types/connector.go
@@ -412,7 +412,7 @@ func GetPoolWeights(
 	timestampBefore, timestampAfter, timestamp math.Int,
 ) (math.LegacyDec, math.LegacyDec, error) {
 	if timestampBefore.GT(timestamp) {
-		return math.LegacyZeroDec(), math.LegacyZeroDec(), ErrInvalidDexConfig
+		return weightCoinABefore, weightCoinBBefore, nil
 	}
 
 	if timestamp.GTE(timestampAfter) {


Reviews:
user: login: coderabbitai[bot]
body: **Actionable comments posted: 2**

<details>
<summary>🧹 Nitpick comments (1)</summary><blockquote>

<details>
<summary>x/distribution/keeper/genesis.go (1)</summary><blockquote>

`126-132`: **Relaxed module account balance validation.**

The validation check has been changed to only verify that the module account balance is greater than or equal to the expected holdings, rather than requiring an exact match. This accommodates potential external transfers into the module account.


This is a reasonable approach given the challenges with blocking fungible asset transfers. However, ensure there are regular audits to detect any unexpected discrepancies in balances that might indicate issues beyond normal operations.

</blockquote></details>

</blockquote></details>

<details>
<summary>📜 Review details</summary>

**Configuration used: CodeRabbit UI**
**Review profile: CHILL**
**Plan: Pro**

<details>
<summary>📥 Commits</summary>

Reviewing files that changed from the base of the PR and between 30059bc8f4195676adc3663625fc9092de9039d3 and 96e498d069d0fdb9757ba49b033970e8a2631fbb.

</details>

<details>
<summary>📒 Files selected for processing (5)</summary>

* `x/distribution/keeper/allocation.go` (1 hunks)
* `x/distribution/keeper/genesis.go` (1 hunks)
* `x/move/keeper/genesis.go` (1 hunks)
* `x/move/keeper/handler.go` (2 hunks)
* `x/move/types/connector.go` (1 hunks)

</details>

<details>
<summary>⏰ Context from checks skipped due to timeout of 90000ms (4)</summary>

* GitHub Check: golangci-lint
* GitHub Check: Run test and upload codecov
* GitHub Check: Initiad
* GitHub Check: Analyze (go)

</details>

<details>
<summary>🔇 Additional comments (5)</summary><blockquote>

<details>
<summary>x/move/types/connector.go (1)</summary>

`414-415`: <details>
<summary>✅ Verification successful</summary>

**Improved error handling for timestamp inconsistencies.**

The code now returns valid weight values instead of an error when `timestampBefore` is greater than `timestamp`. This change makes the function more robust by handling potential timestamp inconsistencies gracefully.
 

Run this script to verify how these weights are used in practice:

---

🏁 Script executed:

```shell
#!/bin/bash
# Check where GetPoolWeights is called and how errors are handled
rg -A 3 -B 3 "GetPoolWeights" --type go
```

Length of output: 1283

---



</details>

**Notice: Timestamp Handling Update Verified**  
The changes at `x/move/types/connector.go` (lines 414–415) now return the pre-calculated weights (`weightCoinABefore` and `weightCoinBBefore`) with a nil error when `timestampBefore` is greater than `timestamp`. Verification shows that downstream calls (e.g., in `Test_GetDexWeight` in `connector_test.go`) expect a valid weight value and handle the nil error appropriately. This update improves robustness by gracefully managing timestamp inconsistencies without propagating an error.

</details>
<details>
<summary>x/move/keeper/handler.go (4)</summary>

`394-400`: **Enhanced panic handling for gas-related errors.**

This change improves error handling by differentiating between out-of-gas errors and other panic types, allowing appropriate propagation of gas errors while safely handling other panic scenarios.

---

`589-591`: **Account tracking added to view function execution.**

Adding account number tracking alongside execution counter provides better context for audit purposes. The variable naming change from `executionCounter` to `ec` also improves code consistency.

---

`599-601`: **Verify the implications of using an infinite gas meter for view functions.**

While delegating gas metering to the Move VM makes sense, using an infinite gas meter for view functions could potentially allow resource-intensive operations without proper constraints.

Can you confirm that the Move VM properly handles gas accounting internally for view functions? Otherwise, this approach could expose the system to potential DoS vulnerabilities if complex view functions consume excessive resources.

---

`605-608`: **Context enrichment for better auditing.**

Passing account number and execution counter to the execution environment enhances the audit trail for view function calls, which aligns with the PR's audit feature objectives.

</details>

</blockquote></details>

</details>

<!-- This is an auto-generated comment by CodeRabbit for review status -->
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-03-01T08:55:17Z
user: login: coderabbitai[bot]
body: **Actionable comments posted: 0**

<details>
<summary>🧹 Nitpick comments (4)</summary><blockquote>

<details>
<summary>x/ibc-hooks/move-hooks/receive.go (4)</summary><blockquote>

`24-29`: **Enhanced error handling for memo validation in ICS-20 packet processing**

This change improves the conditional logic to properly handle error cases during memo validation. Now, the function only passes the packet to the standard processing path when either it's not Move-routed OR (the validation produced no error AND there's no Move message). This ensures that invalid memo data with errors won't be incorrectly processed.



While the current implementation is correct, consider extracting this flow control logic into a helper function since it's duplicated in both packet handlers:

```diff
+ func shouldUseDefaultHandler(isMoveRouted bool, err error, hookData *HookData) bool {
+    return !isMoveRouted || (err == nil && hookData != nil && hookData.Message == nil)
+ }

  func (h MoveHooks) onRecvIcs20Packet(
      // ...existing params...
  ) ibcexported.Acknowledgement {
      isMoveRouted, hookData, err := validateAndParseMemo(data.GetMemo())
-     if !isMoveRouted || (err == nil && hookData.Message == nil) {
+     if shouldUseDefaultHandler(isMoveRouted, err, hookData) {
          return im.App.OnRecvPacket(ctx, packet, relayer)
      } else if err != nil {
          return newEmitErrorAcknowledgement(err)
      }
```

---

`31-66`: **Consider adding audit logging for successful Move hook executions**

Given that this PR is focused on adding an audit feature (as mentioned in the PR objectives), and considering this is a critical path for interchain communications, it would be beneficial to add audit logging for successful executions of Move hooks when processing ICS-20 packets.


Consider adding audit logging after successful execution:

```diff
  _, err = h.execMsg(ctx, msg)
  if err != nil {
      return newEmitErrorAcknowledgement(err)
  }
+ 
+ // Add audit logging for successful hook execution
+ ctx.Logger().Info("ICS-20 packet processed with Move hook", 
+     "sender", intermediateSender,
+     "module_address", msg.ModuleAddress,
+     "channel", packet.GetDestChannel())

  return ack
```

---

`112-117`: **Consider adding audit logging for successful Move hook executions in ICS-721 handler**

Similar to the ICS-20 handler, this function should also include audit logging for successful executions to maintain consistency and improve traceability of NFT-related operations.


Consider adding audit logging after successful execution:

```diff
  _, err = h.execMsg(ctx, msg)
  if err != nil {
      return newEmitErrorAcknowledgement(err)
  }
+
+ // Add audit logging for successful hook execution
+ ctx.Logger().Info("ICS-721 packet processed with Move hook", 
+     "sender", intermediateSender,
+     "module_address", msg.ModuleAddress,
+     "channel", packet.GetDestChannel(),
+     "class_id", data.ClassId)

  return ack
```

---

`121-133`: **Consider adding execution metrics for monitoring and auditing**

To further enhance the audit capabilities of this system, consider instrumenting the `execMsg` function with metrics that track execution counts, success rates, and execution times. This would be valuable for operational monitoring and auditing.


```diff
func (h MoveHooks) execMsg(ctx sdk.Context, msg *movetypes.MsgExecute) (*movetypes.MsgExecuteResponse, error) {
+   start := time.Now()
+   defer func() {
+       h.metrics.ObserveExecutionTime(time.Since(start))
+   }()

    if err := msg.Validate(h.ac); err != nil {
+       h.metrics.IncrementFailedExecutions(msg.ModuleAddress)
        return nil, err
    }

    moveMsgServer := movekeeper.NewMsgServerImpl(h.moveKeeper)
    res, err := moveMsgServer.Execute(ctx, msg)
    if err != nil {
+       h.metrics.IncrementFailedExecutions(msg.ModuleAddress)
        return nil, err
    }

+   h.metrics.IncrementSuccessfulExecutions(msg.ModuleAddress)
    return res, nil
}
```

</blockquote></details>

</blockquote></details>

<details>
<summary>📜 Review details</summary>

**Configuration used: CodeRabbit UI**
**Review profile: CHILL**
**Plan: Pro**

<details>
<summary>📥 Commits</summary>

Reviewing files that changed from the base of the PR and between fae99629760b44a6694f110d838f3ab123c86c94 and 114b26b0913ef13672d2f202abe56dc67a1d0272.

</details>

<details>
<summary>📒 Files selected for processing (1)</summary>

* `x/ibc-hooks/move-hooks/receive.go` (2 hunks)

</details>

<details>
<summary>⏰ Context from checks skipped due to timeout of 90000ms (4)</summary>

* GitHub Check: Run test and upload codecov
* GitHub Check: golangci-lint
* GitHub Check: Initiad
* GitHub Check: Analyze (go)

</details>

<details>
<summary>🔇 Additional comments (1)</summary><blockquote>

<details>
<summary>x/ibc-hooks/move-hooks/receive.go (1)</summary>

`76-81`: **Enhanced error handling for memo validation in ICS-721 packet processing**

This change applies the same improved error handling logic to the non-fungible token packet processing path. The function now correctly ensures that errors from memo validation are properly handled before proceeding with any processing.

</details>

</blockquote></details>

</details>

<!-- This is an auto-generated comment by CodeRabbit for review status -->
state: COMMENTED
author_association: CONTRIBUTOR
submitted_at: 2025-03-03T12:30:43Z

Review comments:
diff_hunk: @@ -68,7 +68,7 @@ func (k Keeper) Initialize(
 		}
 	}
 
-	return k.handleExecuteResponse(sdkCtx, sdkCtx.GasMeter(), execRes)
+	return nil
path: x/move/keeper/genesis.go
user: login: coderabbitai[bot]
body: _⚠️ Potential issue_

**Removed execution response handling in Initialize method.**

The function now returns `nil` instead of handling the execution response from the VM initialization. This removes error propagation that might be important during chain initialization.
 

Please ensure that any critical errors from execution are still being captured and properly handled elsewhere. Consider the following improvement:

```diff
-	return nil
+	// Return any errors from VM initialization
+	if execRes.Status != vmtypes.ExecutionStatus_Success {
+		return fmt.Errorf("VM initialization failed: %s", execRes.Error)
+	}
+	return nil
```


<!-- suggestion_start -->

<details>
<summary>📝 Committable suggestion</summary>

> ‼️ **IMPORTANT**
> Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

`````suggestion
	// Return any errors from VM initialization
	if execRes.Status != vmtypes.ExecutionStatus_Success {
		return fmt.Errorf("VM initialization failed: %s", execRes.Error)
	}
	return nil
`````

</details>

<!-- suggestion_end -->

<!-- This is an auto-generated comment by CodeRabbit -->
created_at: 2025-03-01T08:55:14Z
author_association: CONTRIBUTOR
diff_hunk: @@ -80,7 +80,7 @@ func (k Keeper) AllocateTokens(ctx context.Context, totalPreviousPower int64, bo
 
 	// allocate rewards proportionally to reward power
 	for _, rewardWeight := range rewardWeights {
-		poolFraction := rewardWeight.Weight.Quo(weightsSum)
+		poolFraction := rewardWeight.Weight.QuoTruncate(weightsSum)
path: x/distribution/keeper/allocation.go
user: login: coderabbitai[bot]
body: _🛠️ Refactor suggestion_

<details>
<summary>❓ Verification inconclusive</summary>

**Changed division method for reward allocation.**

The function now uses `QuoTruncate` instead of `Quo` when calculating the pool fraction, which means values will be truncated instead of rounded. This will result in more deterministic but potentially less precise reward allocations.
 

This change affects how rewards are distributed to validators. Using truncated division could lead to small amounts of tokens being left in the community pool over time rather than being fully distributed to validators. Run the following to understand the impact:

---

🏁 Script executed:

```shell
#!/bin/bash
# Check other places where similar calculations occur for consistency
rg "Quo\(" --type go --glob "x/distribution/**/*.go" -A 1 -B 1
```

Length of output: 811

---



</details>

**Attention: Verify Consistency in Reward Allocation Calculations**

The change from using `Quo` to `QuoTruncate` in calculating `poolFraction` now enforces deterministic truncation. This may cause small amounts of tokens to remain in the community pool over time instead of being fully allocated to validators. A code search in the distribution module shows that while this update is applied in production (in `x/distribution/keeper/allocation.go`), test files (e.g., `x/distribution/keeper/keeper_test.go`) still employ the legacy `Quo` method for division.

- **Action Items:**
  - **Review Test Consistency:** Confirm whether test expectations need to be updated to align with the new truncation behavior.
  - **Evaluate Precision Impact:** Ensure that the potential accumulation of unallocated tokens is acceptable based on overall reward distribution goals.

<!-- This is an auto-generated comment by CodeRabbit -->
created_at: 2025-03-01T08:55:14Z
author_association: CONTRIBUTOR

PR comments:
user: login: coderabbitai[bot]
created_at: 2025-03-01T08:51:55Z
body: <!-- This is an auto-generated comment: summarize by coderabbit.ai -->
<!-- This is an auto-generated comment: skip review by coderabbit.ai -->

> [!IMPORTANT]
> ## Review skipped
> 
> Review was skipped due to path filters
> 
> <details>
> <summary>:no_entry: Files ignored due to path filters (1)</summary>
> 
> * `.github/workflows/docker.yml` is excluded by `!**/*.yml`
> 
> </details>
> 
> CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including `**/dist/**` will override the default block on the `dist` directory, by removing the pattern from both the lists.
> 
> You can disable this status message by setting the `reviews.review_status` to `false` in the CodeRabbit configuration file.

<!-- end of auto-generated comment: skip review by coderabbit.ai -->
<!-- walkthrough_start -->

<details>
<summary>📝 Walkthrough</summary>

## Walkthrough
This PR adjusts several reward allocation and error handling routines across the distribution and move modules. In the distribution module, the token allocation now uses truncated division, and the genesis balance check has been relaxed. In the move module, the initialization no longer processes execution responses while dispatch and view functions receive improved error handling using type checks and an infinite gas context. The connector’s pool weight function is also modified to return valid weights without triggering an error for timestamp discrepancies.

## Changes

| File(s)                                               | Change Summary |
|-------------------------------------------------------|----------------|
| `x/distribution/keeper/allocation.go`                 | Changed the `poolFraction` calculation in `AllocateTokens` to use `QuoTruncate` (truncated division) instead of standard division. |
| `x/distribution/keeper/genesis.go`                    | Updated `InitGenesis` to compare module account balances using `IsAllGTE` and added a variable (`broken`) for condition tracking before panicking. |
| `x/move/keeper/genesis.go`                            | Modified the `Initialize` method to remove execution response handling by returning `nil` directly. |
| `x/move/keeper/handler.go`                            | Enhanced error handling in `dispatchMessage` (using a type switch for panic recovery) and adjusted execution context in `executeViewFunction` and `executeEntryFunction` (new variables `ac`/`ec` and infinite gas for Move VM). |
| `x/move/types/connector.go`                           | Revised `GetPoolWeights` to return prior weight values with a `nil` error instead of returning an error when the timestamp condition fails. |
| `x/evidence/keeper/msg_server.go`                     | Added validation checks for `msg.Submitter` and `msg.GetEvidence()` in `SubmitEvidence`, enhancing error handling. |
| `x/intertx/keeper/msg_server.go`                      | Introduced validation for `icaMsg` in `RegisterAccount` and `SubmitTx` methods before processing messages. |

## Possibly related PRs
- **initia-labs/initia#229:** The changes in the main PR regarding the `AllocateTokens` method in `allocation.go` are directly related to the modifications made in the same file in the retrieved PR, which also involves updates to the allocation logic.
- **initia-labs/initia#251:** The changes in the main PR and the retrieved PR are related as both involve modifications to division operations, specifically replacing standard division methods with truncation variants in the `AllocateTokens` method and the `ShareToAmount` function, respectively.
- **initia-labs/initia#253:** The changes in the main PR modify the `AllocateTokens` method in `allocation.go`, while the retrieved PR also alters the logic within the `AllocateTokens` function in the same file, indicating a direct relationship between the two.

## Suggested reviewers
- **Vritra4**

## Poem
> I’m a bunny code-rabbit, hopping through the field of change,  
> Carrots of logic trimmed with care, arranged within each range.  
> Allocation flows now truncate errors, gentle but precise,  
> Genesis checks and view functions sing, bugs vanish like ice.  
> With cadence and with cheer, I nibble through this byte,  
> Celebrating every little fix that makes our code feel right!  
> 🥕🐇

</details>

<!-- walkthrough_end -->
<!-- intern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ilAJYZsNQBbDljWx3+TMLWFowgbtBEAEDEaMYSgZ9gwgb/D/gAE4AAbCQHGDYCAAHLQEm64DsBpAuILQAEDYC1uowNbtGkIECBJuwwYYLQMm4kAiBaASJrgOGANA4gqgK2IYA/6HMSA2AvAZE1oG4DJuAgcYOMDQC4DyB4wOIA0AaCTdaARA4YEQLiDDAVADQSJsMAYBEDcBDAbAeMCEGwCIAkAVQeMAEA8DmB2AhoMMHRBODcBG3WgJEziBTdImKgEgKMFwG0AGAbgtAA0FIGRMNuFgywVAF5jqBEBWYFAUA0vB0AIGLMIQUAA=== -->

<!-- internal state end -->
<!-- tips_start -->

---



<details>
<summary>🪧 Tips</summary>

### Chat

There are 3 ways to chat with [CodeRabbit](https://coderabbit.ai):

- Review comments: Directly reply to a review comment made by CodeRabbit. Example:
  - `I pushed a fix in commit <commit_id>, please review it.`
  - `Generate unit testing code for this file.`
  - `Open a follow-up GitHub issue for this discussion.`
- Files and specific lines of code (under the "Files changed" tab): Tag `@coderabbitai` in a new review comment at the desired location with your query. Examples:
  - `@coderabbitai generate unit testing code for this file.`
  -	`@coderabbitai modularize this function.`
- PR comments: Tag `@coderabbitai` in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
  - `@coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.`
  - `@coderabbitai read src/utils.ts and generate unit testing code.`
  - `@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.`
  - `@coderabbitai help me debug CodeRabbit configuration file.`

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

### CodeRabbit Commands (Invoked using PR comments)

- `@coderabbitai pause` to pause the reviews on a PR.
- `@coderabbitai resume` to resume the paused reviews.
- `@coderabbitai review` to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
- `@coderabbitai full review` to do a full review from scratch and review all the files again.
- `@coderabbitai summary` to regenerate the summary of the PR.
- `@coderabbitai generate docstrings` to [generate docstrings](https://docs.coderabbit.ai/finishing-touches/docstrings) for this PR.
- `@coderabbitai resolve` resolve all the CodeRabbit review comments.
- `@coderabbitai configuration` to show the current CodeRabbit configuration for the repository.
- `@coderabbitai help` to get help.

### Other keywords and placeholders

- Add `@coderabbitai ignore` anywhere in the PR description to prevent this PR from being reviewed.
- Add `@coderabbitai summary` to generate the high-level summary at a specific location in the PR description.
- Add `@coderabbitai` anywhere in the PR title to generate the title automatically.

### CodeRabbit Configuration File (`.coderabbit.yaml`)

- You can programmatically configure CodeRabbit by adding a `.coderabbit.yaml` file to the root of your repository.
- Please see the [configuration documentation](https://docs.coderabbit.ai/guides/configure-coderabbit) for more information.
- If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: `# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json`

### Documentation and Community

- Visit our [Documentation](https://docs.coderabbit.ai) for detailed information on how to use CodeRabbit.
- Join our [Discord Community](http://discord.gg/coderabbit) to get help, request features, and share feedback.
- Follow us on [X/Twitter](https://twitter.com/coderabbitai) for updates and announcements.

</details>

<!-- tips_end -->
author_association: CONTRIBUTOR
user: login: github-actions[bot]
created_at: 2025-03-01T08:52:02Z
body: <h1>Dependency Review</h1>
✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.<h2>OpenSSF Scorecard</h2>
<table><tr><th>Package</th><th>Version</th><th>Score</th><th>Details</th></tr>
</table><h2>Scanned Files</h2>
<ul>


<!-- dependency-review-pr-comment-marker -->
author_association: CONTRIBUTOR
user: login: codecov[bot]
created_at: 2025-03-01T09:04:17Z
body: ## [Codecov](https://app.codecov.io/gh/initia-labs/initia/pull/354?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) Report
Attention: Patch coverage is `43.18182%` with `25 lines` in your changes missing coverage. Please review.
> Project coverage is 41.18%. Comparing base [(`30059bc`)](https://app.codecov.io/gh/initia-labs/initia/commit/30059bc8f4195676adc3663625fc9092de9039d3?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) to head [(`f1e401a`)](https://app.codecov.io/gh/initia-labs/initia/commit/f1e401a0d4ea4fcf6037862c4bf682dd8d3d24bd?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs).
> Report is 1 commits behind head on main.

| [Files with missing lines](https://app.codecov.io/gh/initia-labs/initia/pull/354?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) | Patch % | Lines |
|---|---|---|
| [x/evidence/keeper/msg\_server.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fevidence%2Fkeeper%2Fmsg_server.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9ldmlkZW5jZS9rZWVwZXIvbXNnX3NlcnZlci5nbw==) | 0.00% | [10 Missing :warning: ](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) |
| [x/intertx/keeper/msg\_server.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fintertx%2Fkeeper%2Fmsg_server.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9pbnRlcnR4L2tlZXBlci9tc2dfc2VydmVyLmdv) | 53.84% | [4 Missing and 2 partials :warning: ](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) |
| [x/move/keeper/handler.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fmove%2Fkeeper%2Fhandler.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9tb3ZlL2tlZXBlci9oYW5kbGVyLmdv) | 57.14% | [6 Missing :warning: ](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) |
| [x/distribution/keeper/genesis.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fdistribution%2Fkeeper%2Fgenesis.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9kaXN0cmlidXRpb24va2VlcGVyL2dlbmVzaXMuZ28=) | 0.00% | [2 Missing :warning: ](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) |
| [x/move/types/connector.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fmove%2Ftypes%2Fconnector.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9tb3ZlL3R5cGVzL2Nvbm5lY3Rvci5nbw==) | 0.00% | [1 Missing :warning: ](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) |

<details><summary>Additional details and impacted files</summary>


[![Impacted file tree graph](https://app.codecov.io/gh/initia-labs/initia/pull/354/graphs/tree.svg?width=650&height=150&src=pr&token=CQ8FELH3BU&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs)](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs)

```diff
@@            Coverage Diff             @@
##             main     #354      +/-   ##
==========================================
- Coverage   41.21%   41.18%   -0.03%     
==========================================
  Files         269      269              
  Lines       25761    25783      +22     
==========================================
+ Hits        10617    10620       +3     
- Misses      13498    13515      +17     
- Partials     1646     1648       +2     
```

| [Files with missing lines](https://app.codecov.io/gh/initia-labs/initia/pull/354?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs) | Coverage Δ | |
|---|---|---|
| [x/distribution/keeper/allocation.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fdistribution%2Fkeeper%2Fallocation.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9kaXN0cmlidXRpb24va2VlcGVyL2FsbG9jYXRpb24uZ28=) | `67.61% <100.00%> (ø)` | |
| [x/ibc-hooks/move-hooks/receive.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fibc-hooks%2Fmove-hooks%2Freceive.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9pYmMtaG9va3MvbW92ZS1ob29rcy9yZWNlaXZlLmdv) | `57.14% <100.00%> (ø)` | |
| [x/move/keeper/genesis.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fmove%2Fkeeper%2Fgenesis.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9tb3ZlL2tlZXBlci9nZW5lc2lzLmdv) | `13.29% <100.00%> (ø)` | |
| [x/move/types/connector.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fmove%2Ftypes%2Fconnector.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9tb3ZlL3R5cGVzL2Nvbm5lY3Rvci5nbw==) | `19.35% <0.00%> (ø)` | |
| [x/distribution/keeper/genesis.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fdistribution%2Fkeeper%2Fgenesis.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9kaXN0cmlidXRpb24va2VlcGVyL2dlbmVzaXMuZ28=) | `0.00% <0.00%> (ø)` | |
| [x/intertx/keeper/msg\_server.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fintertx%2Fkeeper%2Fmsg_server.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9pbnRlcnR4L2tlZXBlci9tc2dfc2VydmVyLmdv) | `81.63% <53.84%> (-10.26%)` | :arrow_down: |
| [x/move/keeper/handler.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fmove%2Fkeeper%2Fhandler.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9tb3ZlL2tlZXBlci9oYW5kbGVyLmdv) | `80.14% <57.14%> (-0.92%)` | :arrow_down: |
| [x/evidence/keeper/msg\_server.go](https://app.codecov.io/gh/initia-labs/initia/pull/354?src=pr&el=tree&filepath=x%2Fevidence%2Fkeeper%2Fmsg_server.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=initia-labs#diff-eC9ldmlkZW5jZS9rZWVwZXIvbXNnX3NlcnZlci5nbw==) | `10.00% <0.00%> (-6.67%)` | :arrow_down: |

</details>
author_association: NONE