lbryio / lbry-sdk

The LBRY SDK for building decentralized, censorship resistant, monetized, digital content apps.
https://lbry.com
MIT License
7.19k stars 482 forks source link

Takeover delay not taken into account after support #2424

Open tzarebczan opened 5 years ago

tzarebczan commented 5 years ago

I added 20LBC in support to this claim, and it activated right away as controlling, even though the block delay height has not been hit:

C:\Users\SoloDolo\Desktop>lbrynet resolve @kundaliniyogini
{
  "@kundaliniyogini": {
    "address": "bXrfqnHTBniXSCD9oNyik54M1642AM9G8J",
    "amount": "0.01",
    "canonical_url": "lbry://@KundaliniYogini#0",
    "claim_id": "08f31fe3fa6caa14799d7a7d1de8713553f5e8ee",
    "claim_op": "create",
    "confirmations": 1868,
    "height": 621980,
    "meta": {
      "activation_height": 622065,
      "claims_in_channel": 187,
      "creation_height": 621980,
      "creation_timestamp": 1566622513,
      "effective_amount": "20.01",
      "expiration_height": 2724380,
      "is_controlling": true,
      "support_amount": "20.0",
      "take_over_height": 623843,
      "trending_global": 0.0,
      "trending_group": 0,
      "trending_local": 0.0,
      "trending_mixed": 0.0
    },
BrannonKing commented 4 years ago

This is a bug in lbrycrd, and has been one for a long time. We tried to fork it out in HF1910, but we apparently failed at that. I had to code it up as part of the sqlite rewrite just to keep hash compatibility.

lyoshenka commented 4 years ago

@BrannonKing are you planning to fix this in the next HF?

tzarebczan commented 4 years ago

It's actually fixed already, meant to close this.

tzarebczan commented 4 years ago

This is still an issue on the SDK side. If I add a support, it takes over right away.