tangle-network / tangle

Modular restaking infrastructure for developers, restakers, and operators.
https://www.tangle.tools/
GNU General Public License v3.0
51 stars 24 forks source link

[BUG] Node in the Validator Set, yet, not validating blocks #607

Closed tbraun96 closed 5 months ago

tbraun96 commented 6 months ago

I'm using this script for installing tangle and adding a tangle node (validator) as a systemd service: install_tangle.sh

This generates a folder: $HOME/tangle/ I then add and execute this script while inside $HOME/tangle: insert_keys.bash

As per the tutorial, referencing this page, I run:

curl -H "Content-Type: application/json" -d '{"id":1, "jsonrpc":"2.0", "method": "author_rotateKeys", "params":[]}' http://localhost:9933

I successfully get a result back with an 0x.... session key.

Then, in the polkadot UI, I go to network -> staking -> accounts. Then, I add a validator under my account ID (shown at the bottom of this issue), which is hooked up to the polkadot browser extension. Importantly, I set the "keys from rotateKeys" equal to my 0x.. session key obtained from the bash command above to add this validator.

After awhile, I notice my node show up in the ACTIVE validator set: Active Validators. As of posting this, my account is in this ACTIVE validator set.

Despite this, my node is not producing blocks. I have opened all required firewall ports, evidenced by the fact that on telemetry (node name: "NoLogik"), I am connected to peers. @1xstj and I have attempted to debug, but to no success.

My account ID: tgF8pYSb7KQPGjPkvBoCU2ACeAYv3mKXMkqhS2wzLdjDUvsQy

tbraun96 commented 5 months ago

The issue appears to be that, while I bonded enough tokens to meet the validator minimum, those tokens were frozen/unvested. The actual number of tokens that were transferrable and bonded was in the amount of millitnt. Since the block selection algorithm for determining who produces the next block is contingent on this actual number of bonded tokens, I was never selected. Maybe, we should calculate the "accessible" tokens before allowing people to bond/stake.