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

Staking wallet api refine #2950

Merged
merged 10 commits into from
May 6, 2024
Merged

Staking wallet api refine #2950

merged 10 commits into from
May 6, 2024

Conversation

hui-an-yang
Copy link
Collaborator

@hui-an-yang hui-an-yang commented May 3, 2024

@taquito/taquito updated walletAPI typedoc
integration-tests updated assertion to be robusst

Thank you for your contribution to Taquito.

Before submitting this PR, please make sure:

  • Your code builds cleanly without any errors or warnings
  • You have run the linter against the changes
  • You have added unit tests (if relevant/appropriate)
  • You have added integration tests (if relevant/appropriate)
  • All public methods or types have TypeDoc coverage with a complete description, and ideally an @example
  • You have added or updated corresponding documentation
  • If relevant, you have written a first draft summary describing the change for inclusion in Release Notes.

In this PR, please also make sure:

  • You have linked this PR to the issue by putting closes #TICKETNUMBER in the description box (when applicable)
  • You have added a concise description on your changes

Release Note Draft Snippet

If relevant, please write a summary of your change that will be suitable for
inclusion in the Release Notes for the next Taquito release.

Copy link

github-actions bot commented May 3, 2024

New packages have been deployed to the preview repository at https://npm.preview.tezostaquito.io/.

Published packages:

npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/
npm i @taquito/[email protected] --registry https://npm.preview.tezostaquito.io/

Copy link

cloudflare-workers-and-pages bot commented May 3, 2024

Deploying taquito with  Cloudflare Pages  Cloudflare Pages

Latest commit: 359e531
Status: ✅  Deploy successful!
Preview URL: https://18b097cf.taquito.pages.dev
Branch Preview URL: https://staking-walletapi-refine.taquito.pages.dev

View logs

@hui-an-yang hui-an-yang requested a review from dsawali May 3, 2024 17:55
@hui-an-yang hui-an-yang marked this pull request as ready for review May 3, 2024 17:55
* @description Transfer all the finalizable unstaked funds of the source to their liquid balance
* @returns An operation handle with the result from the rpc node
*
* @returns A wallet command from which we can send the operation to the wallet
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would keep the previous description. This is technically correct, but doesn't tell our users much because a wallet command is just a helper method.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for contractAPI it will return and make sense to haveAn operation handle with the result from the rpc node but walletAPI does return a send command only, it's after the send command is called that will return a WalletOperaion, i think something like @returns A wallet command "send" to send the operation to the wallet that will return the WalletOperation might be more appropriate. Do you still think it's best to keep An operation handle with the result from the rpc node and update all operations supported in walletApi accordinly

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@returns a wallet command... is not correct. The returns will bubble up. A stake method returns a Promise<TransactionWalletOperation> object. The description should not have to mention the 'wallet command' part of the execution. That should just stay internal.

The previous description is correct, but not explicit. If you want to make it a bit more clear. It should say something like @returns TransactionWalletOperation promise object, which contains the operation hash and the block response observable.

@hui-an-yang hui-an-yang merged commit cce27ff into paris May 6, 2024
6 of 8 checks passed
@hui-an-yang hui-an-yang deleted the staking-walletAPI-refine branch May 6, 2024 18:55
dsawali added a commit that referenced this pull request Jun 5, 2024
* feat: configured paris branch (#2911)

* feat: configured paris branch

* test: updated estimation assertion

* 2884 remove get endorsing rights (#2916)

* feat: removed rpc.getEndorsingRights

* docs: update getBlock desc with default version 1

* test: updated estimation assertion

* test: updated estimation assertion

* test: updated estimation assertion

* updated protocol constants test (#2918)

* updated protocol constants test

* updated constants response for proto20

* updated missing properties and estimation values

* removed duplicate property

* 2678 rpc ai launch cycle (#2919)

* feat: support new rpc getAdaptiveIssuanceLaunchCycle and unit tests

re #2678

* test: add integration test and updated response type and description

* test: update test descript for clarity

* test: update estimation consumedMilligas assertion

* docs: updated docs/rpc_nodes_integration_test.md with getAdaptiveIssuanceLaunchCycle

* 2887 update ai rpc (#2923)

* feat: update getDelegates rpc type with adaptive issuance changes

* test: updated estimation assertion

* 2676 new ai rpc (#2926)

* added staking support in contract API, with unit and integration tests (#2930)

* added staking support in contract API, with unit and integration tests

* updated ux to not require destination (for stake/unstake) and not require a param for finalize unstake

* updated error message

* addressed PR comments

* remove wrong check

* removed undefined check for a more general falsy check

* feat: walletAPI supports stake, unstake, finalizeUnstake with integration-tests (#2935)

* docs: adapting getPendingOperations version change in description (#2936)

* feat: update rpc for dal (#2937)

* chore(releng) bump version to 20.0.0-beta.0

* test: added pseudo-entrypoints-forgin.spec.ts (#2938)

* updated baker account for staking tests (#2951)

* updated baker account for staking tests

* updated paris tests to not run on oxfordnet

* Staking wallet api refine (#2950)

* test: updated wallet/staking tests to be robust and walletAPI desc to be accurate

* docs: address comments for typedoc

* docs: added rounding explanation

* Documentation for Staking (#2928)

* docs: draft of documentation for staking

* docs: modifications in response to An's comments

* docs: fix spelling errors

* docs: added code samples

* docs: fixed mermaid error

* docs: add a note to doc that staking will be disabled for about two weeks after protocol activation

* docs: add wallet api code

* 2880 forger attestation with dal (#2949)

* feat: added rpc type of attestation_with_dal & endorsement_with_dal

* feat: added local-forger support of attestation_with_dal

* test: added unit tests

* test: removed logging

* New Paris protocol ticket literal (#2940)

* ticket literal

* legacy ticket typeckeck fix

* feat: adding local-forger opMapping with Ticket

---------

Co-authored-by: huianyang <[email protected]>

* 2881 dal publish commitment (#2948)

* feat: added rpc type of dal_publish_commitment

* feat: added forger support of dal_publish_commitment

* test: added dal_publish_commitment unit test

* test: remove debug logging

* docs: add comments for commitment_proof bytes length

* Update Paris branch with newest Beacon version (v4.2.2-beta.4) (#2956)

* update beacon version to v4.2.2-beta.4

* removed space

* updated algoliasearch and fortawesome deps (#2954)

* 2912 paris cleanup (#2957)

* test: replaced all oxford ref with paris

* test: updated test mentioning protocol

* test: removed unneeded test case

* test: refine failing_noop test

* updated beacon wallet with new event sub (#2961)

* added comment and trigger ci

* chore(releng) bump version to 20.0.0-beta.1

* 2953 dapp staking (#2959)

* feat: implement test-dapp set-delegate

* feat: implement test-dapp stake/unstake/finalize-unstake

* ci: removed pr test-dapp preview restirction

* feat: support parisnet on test-dapp

* feat: modified testnet specific test names

* Dependencies 20240521 (#2965)

* build: snyk suggested website dependencies upgrade

* build: dependabot suggested dependencies upgrade

* docs: udpate website rpc_nodes page (#2966)

* chore(releng) bump version to 20.0.0-RC.0

* feat: adding new protocol hash (#2974)

* feat: adding new protocol hash PtParisBxoLz5gzMmn3d9WBQNoPSZakgnkMC2VNuQ3KXfUtUQeZ

* addressed review comment

* feat: supporting getAllDelegates in rpc (#2975)

* feat: supporting getAllDelegates in rpc

* test: remove unneeded logging

* chore(releng) bump version to 20.0.0-RC.1

* chore: satisfy lerna

* chore(releng) bump version to 20.0.0

* test: adjusted tests for paris2 protocol (#2980)

* updated estimate test values and mainnet constants for paris (#2982)

* updated estimate test values and mainnet constants for paris

* updated assertion to check for a 403 instead of 401 (old node response)

---------

Co-authored-by: huianyang <[email protected]>
Co-authored-by: hui-an-yang <[email protected]>
Co-authored-by: ac10n <[email protected]>
Co-authored-by: Eugene Zagidullin <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants