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

Can't bond shares after creating validator on gaia-6001 #1196

Closed
kwunyeung opened this issue Jun 10, 2018 · 12 comments · Fixed by #1200
Closed

Can't bond shares after creating validator on gaia-6001 #1196

kwunyeung opened this issue Jun 10, 2018 · 12 comments · Fixed by #1200
Assignees

Comments

@kwunyeung
Copy link
Contributor

@rigelrozanski I have stopped my validator node, upgraded to v0.18.0 and then start the node again. I checked the node status and it had voting_power: 1011 right after the node is connected. After the next block, my node became voting_power: 0. I don't see my node sending vote. Then I query the validator and it gave me this information.

Validator Owner: cosmosaccaddr1k6p5my20u58scap7dgqj4vsy8r86m7u4rlk5sr
Validator: cosmosvalpub1zcjduc3qdgwundnqgrhqdu229znrash2gf2hees2f5u5qjfjl8c3k8c72edqmeym4v
Shares: Status Unbonded, Amount: 367189039844346961/-7638281776791552000
Delegator Shares: 1011/1

I unbonded all the coins and the validator disappeared.

I created the validator again

gaiacli stake create-validator --address-validator cosmosaccaddr1k6p5my20u58scap7dgqj4vsy8r86m7u4rlk5sr --pubkey cosmosvalpub1zcjduc3qdgwundnqgrhqdu229znrash2gf2hees2f5u5qjfjl8c3k8c72edqmeym4v --chain-id=gaia-6001 --amount=1010steak --moniker=forbole --name=forbole

Committed at block 47409. Hash: F75D33A141E4D0D2DF4CBBE235E5B4E2C7FAE9A2

Still have voting_power: 0.

I queried the validatar again.

Validator
Owner: cosmosaccaddr1k6p5my20u58scap7dgqj4vsy8r86m7u4rlk5sr
Validator: cosmosvalpub1zcjduc3qdgwundnqgrhqdu229znrash2gf2hees2f5u5qjfjl8c3k8c72edqmeym4v
Shares: Status Unbonded, Amount: -5074216642907784547/-7062656381400121344
Delegator Shares: 6621055/8916

Shares are still unbonded.

Then I tried to delegate the remaining steaks to the validator.

gaiacli stake delegate --address-delegator cosmosaccaddr1k6p5my20u58scap7dgqj4vsy8r86m7u4rlk5sr --address-validator cosmosaccaddr1k6p5my20u58scap7dgqj4vsy8r86m7u4rlk5sr --amount=324steak --chain-id=gaia-6001 --name=forbole

And it gives me the following errors.

ERROR: CheckTx failed: (262345) === ABCI Log ===
Codespace: 4
Code: 201
ABCICode: 262345
Error: --= Error =--
Message: Validator for this address is currently revoked
Cause: <nil>
T: 0xc9
Msg Traces:
--= /Error =--

=== /ABCI Log ===

And then I setup a new clean validator node. Send 1 steak to an address on that validator node and use that account to create validator.

gaiacli stake create-validator --address-validator cosmosaccaddr13fa89leczch40xtcp47y46n0z858crx4s05rqf --pubkey cosmosvalpub1zcjduc3qd3d5lrenvpplxq92nmy6hc30pms866kjz9ks6304eys2vjq3l5usgmcrn4 --chain-id=gaia-6001 --amount=1steak --moniker=forbole.1 --name=forbole-v1

I can create this validator successfully. So I use the original account to delegate steaks to this validator but it also gives me the following error.

ERROR: CheckTx failed: (262345) === ABCI Log ===
Codespace: 4
Code: 201
ABCICode: 262345
Error: --= Error =--
Message: Validator for this address is currently revoked
Cause: <nil>
T: 0xc9
Msg Traces:
--= /Error =--

=== /ABCI Log ===

I queried this validator and it has the following information.

gaiacli stake validator cosmosaccaddr13fa89leczch40xtcp47y46n0z858crx4s05rqf

Validator
Owner: cosmosaccaddr13fa89leczch40xtcp47y46n0z858crx4s05rqf
Validator: cosmosvalpub1zcjduc3qd3d5lrenvpplxq92nmy6hc30pms866kjz9ks6304eys2vjq3l5usgmcrn4
Shares: Status Unbonded, Amount: -5074216642907784547/2446598830636924928
Delegator Shares: 123518731/183919248

Seems all validators created after block 0 can't bond shares.

@hendrikhofstadt
Copy link
Contributor

hendrikhofstadt commented Jun 10, 2018

Can confirm that for validator cosmosaccaddr1dlgd8tksf635zntchgc3kh60fkgpe9sstkql0l

Also gaiacli stake signing-info cosmosvalpub1zcjduc3q0aa7syja0llpzw8na06pd4u2xg04vwqpe6uvvvpc8ax54p8eft7sq8fexa
indeed returns
Start height: 0, index offset: 2, jailed until: 1528612413, signed blocks counter: 2

Saying that some blocks have been signed but still the node was jailed and the validator unbonded.

@kwunyeung
Copy link
Contributor Author

And I can't unrevoke my validator.

gaiacli stake unrevoke cosmosaccaddr1k6p5my20u58scap7dgqj4vsy8r86m7u4rlk5sr --chain-id=gaia-6001 --name=forbole

ERROR: CheckTx failed: (65542) === ABCI Log ===
Codespace: 1
Code: 6
ABCICode: 65542
Error: --= Error =--
Message: Unrecognized Msg type: slashing
Cause: <nil>
T: 0x6
Msg Traces:
--= /Error =--

=== /ABCI Log ===

@hendrikhofstadt
Copy link
Contributor

This is probably related to #1117

The handler for slashing is not yet being registered in the router: https://github.com/cosmos/cosmos-sdk/blob/v0.18.0-rc1/cmd/gaia/app/app.go#L84

@rigelrozanski
Copy link
Contributor

CC: @cwgoes looks like unrevoke message type not registered with the codec in gaia

@cwgoes
Copy link
Contributor

cwgoes commented Jun 11, 2018

CC: @cwgoes looks like unrevoke message type not registered with the codec in gaia

It's registered with the codec - https://github.com/cosmos/cosmos-sdk/blob/v0.18.0-rc1/cmd/gaia/app/app.go#L106 - but the handler is not registered with the router.

Thanks @SLAMPER! Writing a PR now.

@hendrikhofstadt
Copy link
Contributor

hendrikhofstadt commented Jun 11, 2018

@cwgoes You're welcome. I'm looking forward to doing more contributions to both tendermint and now also the cosmos ecosystem.

The missing handler registration is the cause for unrevoked not working but I guess it is not the cause of the immediate unbonding and revoking of new validators, is it ?

@cwgoes
Copy link
Contributor

cwgoes commented Jun 11, 2018

The missing handler registration is the cause for unrevoked not working but I guess it is not the cause of the immediate unbonding and revoking of new validators, is it ?

No, it is not. Validators who miss 50 precommits out of a 100 blocks are automatically unbonded and slashed (slightly) per the current downtime slashing logic - are you referring to that, or are you experiencing a different behavior?

edit: This is a separate bug, I think I know the cause. Tracking in #1199.

@hendrikhofstadt
Copy link
Contributor

@cwgoes Thanks for clarifying. I was already wondering why StartHeight was 0. It makes sense that this is causing the trouble 👍

@kidinamoto01
Copy link
Contributor

@cwgoes
this slashing logic is too tough. Basically you only have 100s to recover.

@rigelrozanski
Copy link
Contributor

the intense conditions are for testnets - production system will have more leeway

@cwgoes
Copy link
Contributor

cwgoes commented Jun 11, 2018

@cwgoes
this slashing logic is too tough. Basically you only have 100s to recover.

Perhaps! Hopefully the next testnet (or perhaps the one after) will implement governance, so you'll be able to vote to change this parameter yourself.

@cwgoes
Copy link
Contributor

cwgoes commented Jun 12, 2018

Closed by #1200. Thanks all.

@cwgoes cwgoes closed this as completed Jun 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants