STEEM SCOT Voting Power Viewer Update: Est Value / Market Prices / Delegation Info / Faster VP loading + Precision fix

in utopian-io •  5 years ago  (edited)

Repository

https://github.com/economicstudio/vp

Let me first show basic usage and information and then introduce updates.

Usage
SCOT additional Information
  • Staked: Staked amount (like SP)
  • Unstaked: Unstaked amount (like STEEM) But excluded if used for market order
  • PendingUnstaked: Pending unstake amount (like powerdown)
  • PendingClaim: Unclaimed amount
  • Total: Total (market order amount is excluded)
Keychain support
  • Claim, Stake, and Donate :)
Steemconnect support
  • Claim (posting key)
  • I feel uncomfortable to require users to enter active key via SC2. Once SC3 is fully tested, I'll add SC support for claim.

New Features: Estimated Value

Commit: https://github.com/economicstudio/vp/commit/ac4088c0ddc530933e214d8f631663d0bc929449

  • As in the above picture, now it shows estimated value in two ways
    • in STEEM
    • in USD (not SBD)

New Features: Market Prices

Commit: https://github.com/economicstudio/vp/commit/ac4088c0ddc530933e214d8f631663d0bc929449

  • It also shows market prices of SCOT and STEEM
    • last SCOT price in STEEM
    • last STEEM price in USD

Code excerpt for STEEM Price

STEEM Price is queried from postpromoter.net API which is also used by Steem Engine, so I believe this API is quite stable.

Code excerpt for SCOT Price

SCOT price can be queried by using SE API with findOne("market", "metrics", { symbol: SCOT }.

New Features: Delegation amount info

Commit: https://github.com/economicstudio/vp/commit/19b50888a8ff199b820be9618108c306a8f9e7cf

Now when there are delegations, it shows as follows (+: In, -: Out):
Staked: 100000.000 (+50000.000-0.000)

New Features: Faster VP loading

Commit: https://github.com/economicstudio/vp/commit/83302496d143a720f10a2069f885b8de6673a23f

  • Now I separated VP loading from balance calculations, so VP loading speed is enhanced.

Now VP loading is done in its promise prmSCOT. Likewise, when all necessary information is ready, the balance info is updated.

Bug Fixes: Pending Claim precision

Commit: https://github.com/economicstudio/vp/commit/83302496d143a720f10a2069f885b8de6673a23f

  • Each SCOT may have different precisions.
  • Now it shows the precisions of Pending Claim correctly.

precision information can be got from findOne("tokens", "tokens", { symbol: SCOT }

Update: Staking JSON format update

Commit: https://github.com/economicstudio/vp/commit/098e7435dfa1c6911bce4766a215015fd8ed5467

  • Steem Engine Staking JSON format has changed
  • Now to field is required.

GitHub Account

https://github.com/economicstudio

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  

Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.

To view those questions and the relevant answers related to your post, click here.


Need help? Chat with us on Discord.

[utopian-moderator]

Hi @helo, thank you for your review. next time, i'll use the compare link, as you suggested.

But console.log is still needed, I think. Scotbot is still very new and changing frequently, so easy report from some advanced users and for me, it's good to keep. But I'll remove quite stable ones next time. (Or make a dev version file separately.) Thanks again.

Thank you for your review, @helo! Keep up the good work!

u should add delegated stake

Oh I forgot that now delegations are enabled. Done!

Staked: 100000.000 (+50000.000-0.000)

Thanks for pointing out that.

NICE u are fast! calculate it into estimated value now :D

No problem and thanks again :)

but delegationIN amount shouldn't be included in the estimated value. delegation is delegation :) Not yours. OUT is still included.

Steemit Wallet and other wallet for SP is also calculated that way.

dunno, my delegation out is not included in estimated, maybe I need to clear caches

Oh I see, you're right. Steem Engine's stake seems "kind of" effective stake already, which is a bad naming to me. their stake = real staked - Out. (but not + In), so in some sense, stake that can be delegated.

Based on https://www.palnet.io/@gerber/transfers that's correct.

Done!

travelgirl님이 blockchainstudio님을 멘션하셨습니당. 아래 링크를 누르시면 연결되용~ ^^
travelgirl님의 Keep An Eye on Your Splintertalk VP Bar ~

... my votes worth so much less than usual. I then went to blockchainstudios clever github tool and it answered all my questions. ...

very cool man, really going to help im starting to go loopy trying to keep track of all thas going on in my poor account

Thanks for your comment :)

  ·  5 years ago (edited)

I didnt see panding claim. Good work!

Thanks. You can also stake it with keychain.

zorba님이 blockchainstudio님을 멘션하셨습니당. 아래 링크를 누르시면 연결되용~ ^^
zorba님의 [2019/6/23] 가장 빠른 해외 소식! 해외 스티미언 소모임 회원들의 글을 소개해드립니다.

...an님, 태국에서 jisoooh0202님, 미국 캘리포니아에서 livelyshawnee님, 영국에서 blockchainstudio gomdory님, 일본에서 sizuko님, 프랑스에서 eric66님, laylador님, 네덜란드에...

Hi @blockchainstudio!

Your post was upvoted by @steem-ua, new Steem dApp, using UserAuthority for algorithmic post curation!
Your post is eligible for our upvote, thanks to our collaboration with @utopian-io!
Feel free to join our @steem-ua Discord server

Hey, @blockchainstudio!

Thanks for contributing on Utopian.
We’re already looking forward to your next contribution!

Get higher incentives and support Utopian.io!
Simply set @utopian.pay as a 5% (or higher) payout beneficiary on your contribution post (via SteemPlus or Steeditor).

Want to chat? Join us on Discord https://discord.gg/h52nFrV.

Vote for Utopian Witness!

  ·  5 years ago Reveal Comment