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

Why Average Block Time and Active Validators are 0? #626

Open
llwinner opened this issue Aug 7, 2023 · 8 comments
Open

Why Average Block Time and Active Validators are 0? #626

llwinner opened this issue Aug 7, 2023 · 8 comments

Comments

@llwinner
Copy link

llwinner commented Aug 7, 2023

I run bdjuno start with no error.
image
Big dipper shows the right block height, but Average Block Time and Active Validators are 0
image
I checked table block, all datas were in it. And I checked table validator, all validators were in it.
image
But when I checked table validator_info it was empty!
image
I don't know why, I follow the doc and run bdjuno successfully.
Please help me. Thanks

@zura35
Copy link

zura35 commented Sep 18, 2023

Hi @llwinner would you let me know which branch you are running on? Thanks!

@zura35
Copy link

zura35 commented Sep 18, 2023

On the other hand, as I looked up the repository, it might be an expected condition? There are two possible places that would INSERT INTO validator:

  1. in staking.HandleGenesis(...), it will save validators details to both validator and validator_info tables which will only be triggered upon genesis file parsed
  2. in staking.HandleBlock(...), it will save validators details to validator and validator_status which will be done upon worker receiving new blocks

Did you run bdjuno parse genesis-file before starting or can you purge the database, run the genesis parse command and check if validators have been persister after the parsing? Thanks!

@llwinner
Copy link
Author

@zura35 Thanks for your reply, my bdjuno branch is chains/cosmos/mainnet
My cosmos version is 0.46.7
image
I used ignite to create an empty chain, there were no transactions
Before I started the database, I run bdjuno parse genesis-file. There were no outputs after I run bdjuno parse genesis-file.

@zura35
Copy link

zura35 commented Sep 18, 2023

Hi @llwinner I think this is expected to not be able to fetch any validators upon genesis file parsed

I have tried to initiate a new chain with ignite scaffold chain example, and this is the genesis file created from the serve command:
Screenshot 2023-09-18 at 1 23 48 PM

Please see if this answer your question 🙏

@llwinner
Copy link
Author

@zura35 My genesis.json is the same
image
My empty chain has run for several days, block height was 18381, but still not get the validator data...

@zura35
Copy link

zura35 commented Sep 20, 2023

Hi @llwinner yes, the genesis file contains the details of you genesis block, as yours is the same as mine, this explains why you have empty validator_info from point 1 stated here

Going back to your original question where you see 0 active validators but a few rows in the validator table, you can actually look up the validator_status table to see if they are jailed 🙏

@nsonanh
Copy link

nsonanh commented Feb 23, 2024

Hi, I have the same problem, none of the validators are jailed but they are not displayed. Average block time is also 0.

@nsonanh
Copy link

nsonanh commented Mar 4, 2024

@llwinner FYI I have fixed it by updating the config.yml file with more modules:

...
    modules:
        - messages
        - auth
        - bank
        - consensus
        - feegrant
        - gov
        - mint
        - modules
        - pricefeed
        - staking
        - slashing
        - distribution
        - daily refetch
        - wasm
...

Now it's showing validators and average block time:
image

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

No branches or pull requests

3 participants