astar.js icon indicating copy to clipboard operation
astar.js copied to clipboard

Add final rewards+final used fee

Open johnnyji-dev opened this issue 1 year ago • 12 comments

johnnyji-dev avatar Mar 07 '24 14:03 johnnyji-dev

Hi @johnnyji-dev thank you for your contribution. Can you please add the PR dscription?

gtg7784 avatar May 27 '24 13:05 gtg7784

Hi @johnnyji-dev thank you for your contribution. Can you please add the PR dscription?

Is there any template for PR description? Is there no format? Can I just write down description for my PR? BTW, I checked out my PR and it need to update on "claimedReward" method.

I completed to update and test that method. I am going to retry to PR.

johnnyji-dev avatar May 29 '24 01:05 johnnyji-dev

Hi @johnnyji-dev thank you for your contribution. Can you please add the PR dscription?

Is there any template for PR description? Is there no format? Can I just write down description for my PR? BTW, I checked out my PR and it need to update on "claimedReward" method.

I completed to update and test that method. I am going to retry to PR.

Hi, you can write summary of updates in this PR without template.

Please update the description and check that claimedReward method (and why it's needed)

thank you for your contribution.

gtg7784 avatar May 29 '24 01:05 gtg7784

and also, please run lint before commit your updates. thank you

gtg7784 avatar May 29 '24 01:05 gtg7784

@gtg7784 [Adding Two Methods]

  • Background : After broadcasting an extrinsic, we need to retrieve "usedFee" or "claimedReward" amount.
  • "usedFee" and "claimedReward" methods are added on "packages/sdk-core/src/modules/dapp-staking/pending-rewards/index.ts".
  • We can get the value by 'extrinsic-hash' and 'block-number'.
  • After stakingV3, There are two types of rewards (bonus and claim).
  • "claimedReward" serves the total(bonus + claim) reward.

It need to merge the commit (77dc1cec6fb9c32a32c7820c0aacc1cecdb08e24).

johnnyji-dev avatar May 29 '24 15:05 johnnyji-dev

Hi @johnnyji-dev on more thing. Can you please uplift version in package.json (there are multiple files) from 0.2.9 to 0.3.0

bobo-k2 avatar Jun 19 '24 07:06 bobo-k2

Hi @johnnyji-dev on more thing. Can you please uplift version in package.json (there are multiple files) from 0.2.9 to 0.3.0

@bobo-k2 Monosnap package json — astar js  개발 컨테이너: Alpine @ desktop-linux  2024-06-23 16-56-06

I uplifted version in package.json (there are multiple files) to 0.3.0

johnnyji-dev avatar Jun 23 '24 08:06 johnnyji-dev

Could you run yarn lint? CI failed in lint and build .

impelcrypto avatar Jul 08 '24 08:07 impelcrypto

After work, I will check them out. Thx~

2024년 7월 8일 (월) 오후 5:22, Roy @.***>님이 작성:

Could you run yarn lint? CI failed in lint and build .

— Reply to this email directly, view it on GitHub https://github.com/AstarNetwork/astar.js/pull/75#issuecomment-2213342472, or unsubscribe https://github.com/notifications/unsubscribe-auth/A53U4LRLMGZCEN2RX4A3RUTZLJD27AVCNFSM6AAAAABELFDJAWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMJTGM2DENBXGI . You are receiving this because you were mentioned.Message ID: @.***>

johnnyji-dev avatar Jul 08 '24 08:07 johnnyji-dev

Hi @johnnyji-dev, please address the following

  • fix build errors
  • provide PR description and explain what you did and why those changes are needed
  • Update SDK-Core Library Functions section in README.md
  • Have in mind that there are actually three different reward events in case you want to also handle the third one https://github.com/AstarNetwork/Astar/blob/150b11c4ffabaf82f6c1ec165bfa5d99340c8358/pallets/dapp-staking-v3/src/lib.rs#L301
  • Updated method name (claimedReward to getClaimedReward & UsedFee to getUsedFee)
  • Updated README.md file ( add getClaimedReward() & getUsedFee() description. )
  • Add "Dapp Reward" case on getClaimedReward()

johnnyji-dev avatar Jul 21 '24 08:07 johnnyji-dev

Hi @johnnyji-dev, please address the following

  • fix build errors
  • provide PR description and explain what you did and why those changes are needed
  • Update SDK-Core Library Functions section in README.md
  • Have in mind that there are actually three different reward events in case you want to also handle the third one https://github.com/AstarNetwork/Astar/blob/150b11c4ffabaf82f6c1ec165bfa5d99340c8358/pallets/dapp-staking-v3/src/lib.rs#L301
  • Updated method name (claimedReward to getClaimedReward & UsedFee to getUsedFee)
  • Updated README.md file ( add getClaimedReward() & getUsedFee() description. )
  • Add "Dapp Reward" case on getClaimedReward()

Hi @johnnyji-dev you forgot the most important point. The code is not building image

bobo-k2 avatar Jul 22 '24 09:07 bobo-k2

Hi @johnnyji-dev, please address the following

  • fix build errors
  • provide PR description and explain what you did and why those changes are needed
  • Update SDK-Core Library Functions section in README.md
  • Have in mind that there are actually three different reward events in case you want to also handle the third one https://github.com/AstarNetwork/Astar/blob/150b11c4ffabaf82f6c1ec165bfa5d99340c8358/pallets/dapp-staking-v3/src/lib.rs#L301
  • Updated method name (claimedReward to getClaimedReward & UsedFee to getUsedFee)
  • Updated README.md file ( add getClaimedReward() & getUsedFee() description. )
  • Add "Dapp Reward" case on getClaimedReward()

Hi @johnnyji-dev you forgot the most important point. The code is not building image

Oh, I missed that part!! And complete to update it.

johnnyji-dev avatar Jul 22 '24 15:07 johnnyji-dev