Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add check for payment data #607

Merged
merged 1 commit into from
Apr 26, 2024

Conversation

forcodedancing
Copy link
Contributor

@forcodedancing forcodedancing commented Apr 10, 2024

Description

Check payment data in endblock:

  • lock balance
  • netflow rate for users
  • netflow rate for gvg family/gvg (i.e., income receivers)

This feature should be only enabled for a fullnode which does not provide rpc service - the check is time consuming.

Rationale

To detect issues in payment module further.

Example

###############################################################################
###                           PaymentCheck Config                           ###
###############################################################################
[payment-check]
# enabled - the flag to enable/disable payment check
enabled = true
# interval - the block interval run check payment
interval = 50

Changes

Notable changes:

  • new logic in end block with panic

Potential Impacts

  • panic if there are issues for the full node

@unclezoro
Copy link
Collaborator

interval = 50 maybe too large, I think check it per day is ok?

@forcodedancing
Copy link
Contributor Author

interval = 50 maybe too large, I think check it per day is ok?

sure, it is ok

package keeper

import (
sdkmath "cosmossdk.io/math"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fix imports

@unclezoro unclezoro added this pull request to the merge queue Apr 26, 2024
Merged via the queue into bnb-chain:develop with commit a165e09 Apr 26, 2024
5 checks passed
forcodedancing added a commit to forcodedancing/greenfield that referenced this pull request May 24, 2024
Copy link

@dabossdana dabossdana left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A lot coins u have check daily

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants