Skip to content
This repository has been archived by the owner on Mar 16, 2022. It is now read-only.

[Tezos] Invalid information in delegations endpoint #750

Closed
4 tasks
vikmeup opened this issue Jan 26, 2020 · 7 comments · Fixed by #797
Closed
4 tasks

[Tezos] Invalid information in delegations endpoint #750

vikmeup opened this issue Jan 26, 2020 · 7 comments · Fixed by #797
Assignees
Labels
Bug Something doesn't work as expected and it's confirmed Priority: Critical Priority: High

Comments

@vikmeup
Copy link
Contributor

vikmeup commented Jan 26, 2020

Summary of Bug

/v2/tezos/staking/delegations/tz1VFiQwFL36Ru7EtugLjXVh3dqp9B4KRSAV

{
   "delegations":[
      {
         "delegator":{
            "id":"tz1Vyuu4EJ5Nym4JcrfRLnp3hpaq1DSEp1Ke",
            "status":true,
            "info":{
               "name":"POS Bakerz",
               "description":"Secure, Reliable and Efficient Staking-as-a-Service",
               "image":"https://raw.githubusercontent.com/trustwallet/assets/master/blockchains/tezos/validators/assets/tz1Vyuu4EJ5Nym4JcrfRLnp3hpaq1DSEp1Ke/logo.png",
               "website":"https://posbakerz.com/"
            },
            "details":{
               "reward":{
                  "annual":5.724600000000001
               },
               "locktime":0,
               "minimum_amount":"0",
               "type":"delegate"
            }
         },
         "value":"0",
         "status":"active"
      }
   ],
   "balance":"91240997",
   "address":"tz1VFiQwFL36Ru7EtugLjXVh3dqp9B4KRSAV",
   "coin":{
      "coin":1729,
      "symbol":"XTZ",
      "name":"Tezos",
      "decimals":6
   },
   "details":{
      "reward":{
         "annual":6.09
      },
      "locktime":0,
      "minimum_amount":"0",
      "type":"delegate"
   }
}

Delegations should not be returned if there is not staking, expect to see delegations: [] if no delegations.

Steps to Reproduce


For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@vikmeup vikmeup added Bug Something doesn't work as expected and it's confirmed Priority: Critical Priority: High labels Jan 26, 2020
@Pantani Pantani self-assigned this Jan 26, 2020
@EnoRage
Copy link
Contributor

EnoRage commented Jan 27, 2020

https://tezblock.io/account/tz1VFiQwFL36Ru7EtugLjXVh3dqp9B4KRSAV shows that account delegated TZS to the POSBackerz

@EnoRage
Copy link
Contributor

EnoRage commented Jan 27, 2020

https://tzstats.com/tz1VFiQwFL36Ru7EtugLjXVh3dqp9B4KRSAV also showing that there was delegation

@EnoRage
Copy link
Contributor

EnoRage commented Jan 27, 2020

Details:

  1. I made an issue about not documented response for this address, you can see it here: https:/blockwatch-cc/tzstats/issues/49
  2. Currently out http.Get Client Maps data to the Account struct without delegate_account field.
    These field contains the same data as account. What is weird

@Pantani
Copy link
Contributor

Pantani commented Jan 28, 2020

@EnoRage, I think this problem is already solved
@vikmeup the owner did stake again with this address?

Here is appear this address is staking:
https://api.tezos.id/mainnet/chains/main/blocks/head/context/contracts/tz1VFiQwFL36Ru7EtugLjXVh3dqp9B4KRSAV

{
  "balance": "91240997",
  "delegate": "tz1Vyuu4EJ5Nym4JcrfRLnp3hpaq1DSEp1Ke",
  "counter": "2261965"
}

@vikmeup
Copy link
Contributor Author

vikmeup commented Jan 28, 2020

Which commit solved this issue? I'm not able to reproduce it, but not sure if other addresses might have this issue

@EnoRage
Copy link
Contributor

EnoRage commented Jan 28, 2020

I will try to reproduce it with:

  1. We need an TZS account that will have balance > 0
  2. I will try to call this method with it
  3. I will try to stake 0 tzs and call it again
  4. If there will be no any returning delegations - we can close these issue

@vikmeup @Pantani

@vikmeup
Copy link
Contributor Author

vikmeup commented Jan 28, 2020

@EnoRage if there is no fix to this problem, I would assume problem still persist.

I would try to look for different addresses on explorers: https://tezos.id/ to see where it caused the issue to show 0 balance for delegations when it was not staking.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Something doesn't work as expected and it's confirmed Priority: Critical Priority: High
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants