Commit Graph

230 Commits

Author SHA1 Message Date
Alexander Ray d158bb150c
stake_pool: fix wrong available_for_withdrawal_wo_fee calculation (#2900)
* - fix wrong available_for_withdrawal_wo_fee calculation by prepare_withdraw_accounts

* - fix formatting

* - refactor

* - fix sub issue
2022-02-15 21:45:32 +01:00
Jon Cinque 4dbb4a5bb4
stake-pool-py: Add more waits to solidify tests (#2882) 2022-02-07 22:26:23 +01:00
Jon Cinque 37ba32f7c8
stake-pool-cli: Fix mismatched output fields (#2846) 2022-01-31 20:15:28 +01:00
Jon Cinque 32e77fb390
stake-pool-js: Bump version for release (#2832) 2022-01-29 00:39:28 +01:00
Kabir R b63d368b79
Add stake-pool browser build commands and documentation (#2804)
* Add browser build commands and documentation

* Improve rollup configuration

* Remove unused external import from rollup configuration

* Move from Babel to Typescript plugin

Co-authored-by: Jon Cinque <jon.cinque@gmail.com>
2022-01-28 19:15:51 +01:00
Jon Cinque c781067b2b
stake-pool-cli: Use old ATA creation instruction (#2819) 2022-01-27 17:50:22 +01:00
Michael Vines 6d62ea6cc7 Drop _program_id 2022-01-24 17:41:47 -08:00
Tyera Eulberg 83c3ffad25
Bump solana crates to v1.9.5 (#2780)
* Bump solana crates to v1.9.5

* Update sol_set_return_data type signature and un-ignore test
2022-01-21 22:52:10 -07:00
Jon Cinque 8ee35d74c1
stake-pool-cli / token-lending-cli: Sign after balance check (#2773) 2022-01-22 01:11:58 +01:00
Jon Cinque 78e7a9538e
associated-token-account: Bump dependent token version to 3.3 (#2766)
* associated-token-account: Bump dependent token version to 3.3

* Fix uses of deprecated instruction
2022-01-21 11:01:06 +01:00
Jon Cinque 81f50127f1
token: Bump version to 3.3.0 (#2765) 2022-01-21 01:47:02 +01:00
Jon Cinque 2e03106ae0
stake-pool-cli: Sign messages before checking fee (#2759) 2022-01-20 14:36:19 +01:00
Jon Cinque 2d770628ef
stake-pool-cli: Add best practices for fees, prevent zero fees (#2670)
* stake-pool-cli: Add best practices for fees, prevent zero fees

* Address feedback
2022-01-11 01:24:16 +01:00
Tyera Eulberg f4e0cae144
Fix up helper to create rent-exempt accounts (#2720) 2022-01-08 15:51:17 -07:00
Dmitri Makarov 65b49073f4
Decrease the stake pool size due to the new mem op syscall base cost (#2705) 2022-01-05 14:26:13 -08:00
Jon Cinque f5f062e1b0
stake-pool-js: Prepare package for release (#2681)
* stake-pool-js: Prepare package for release

* Upgrade node version for new npm

* Regenerate package-lock.json

* Update README, fix build to remove test files
2021-12-30 12:55:09 -05:00
Jon Cinque 6ee008d256
Update SDK to 1.9.2, fix warnings (#2674)
* Update SDK to 1.9.2, fix warnings

* Upgrade honggfuzz

* Use `get_latest_blockhash` correctly
2021-12-28 23:02:47 -05:00
Alexander Ray cd8d79a2b4
[stake-pool] js: web3 stake pool bindings (#2604)
* - add stake-pool-web3-bindings (preview)

* - update readme

* - add tests

* - remove package-lock from foreign project

* - revert changes from foreign project

* - review improvenments

* - refactor regarding review suggestions

* - fix test
- fix readme

* Update stake-pool/js/src/instructions.ts

Co-authored-by: Jon Cinque <jon.cinque@gmail.com>

* - add withdraw authority as optional parameter

Co-authored-by: Jon Cinque <jon.cinque@gmail.com>
2021-12-23 13:34:02 -05:00
Jon Cinque 1f4b65153f
Update tests to prepare for `BanksClientError` (#2657)
* Update tests to prepare for `BanksClientError`

* Remove import from record tests
2021-12-23 13:08:06 -05:00
Jon Cinque 8c9f8a0088
stake-pool: Reduce maximum pool size (#2654)
* stake-pool: Reduce huge pool size in tests

* stake-pool: Reduce supported maximum size
2021-12-21 13:10:12 +01:00
Jon Cinque 5aa3b98f2c
stake-pool-cli: Add next fees in verbose mode, fix mapping (#2645) 2021-12-16 14:46:01 +01:00
Jon Cinque ba08b6e662
stake-pool: Mint extra reserve lamports as pool tokens on init (#2636)
* stake-pool: Mint extra reserve lamports as pool tokens on init

* Wait more aggressively in py test

* Simplify test
2021-12-14 18:45:15 +01:00
Jon Cinque 9bda73f37c
stake-pool-cli: Add `deposit-all-stake` command (#2614)
* stake-pool-cli: Add `deposit-all-stake` command

* Improve py test
2021-12-14 02:25:37 +01:00
Jon Cinque d5ac6b883b
stake-pool-py: Add simple rebalance bot (#2630)
* stake-pool-py: Add simple rebalance bot

* Fixup test

* Refactor flaky tests

* Create vote earlier in test

* Duplicate create_vote call causes stall

* Wait more aggressively
2021-12-13 13:17:07 +01:00
Michael Vines 1a0155e34b Update to Rust 1.57.0 2021-12-09 23:56:47 -08:00
Jon Cinque a7888861da
stake-pool-py: Create and deserialize stake pools (#2557)
* stake-pool-py: Create and deserialize stake pools with CI

* Add ability to add / remove validators

* Add vote init instruction for cleaner tests

* Fixup CI

* Add deposit / withdraw sol

* Add update instructions

* Add increase / decrease stake

* Add deposit / withdraw stake
2021-12-10 00:43:25 +01:00
Jon Cinque c24bc966f1
stake-pool-cli: Update input parser to work with ledgers (#2613)
* stake-pool-cli: Update input parser to work with ledgers

* fmt
2021-12-03 01:55:18 +01:00
Jon Cinque 688ee423ed
stake-pool-cli: Fix vote account address in details (#2585) 2021-11-16 21:30:10 +01:00
JulI0-concerto cd63580b79
Implement multiple output format for spl-stake-pool list-all (#2558)
* Implement json output formats for spl-stake-pool list-all

* Implement --output json or json-compact or display in list-all cmd

* cleanup: use destructuring instead of tuple

* Fix related to PR comments

* Add json and json-compact output for list command

* implement list command display with Display and VerboseDisplay

* make CliStakePool->details optional

* cleanup use

* Update stake-pool/cli/src/main.rs

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>

* Update stake-pool/cli/src/main.rs

Co-authored-by: Tyera Eulberg <teulberg@gmail.com>

* clippished

* fix use

* fix fmt issue

Co-authored-by: Julien Piccaluga <julien.piccaluga@kudelskisecurity.com>
Co-authored-by: Tyera Eulberg <teulberg@gmail.com>
2021-11-10 13:06:14 -07:00
Jon Cinque 75ddd9bb22
stake-pool-docs: Rearrange docs, add quickstart guide (#2561)
* stake-pool-docs: Rearrange docs, add quickstart guide

* Rearrange doc sidebar
2021-11-06 12:48:11 +00:00
Jon Cinque 8aef395901
stake-pool: Bump CLI and program version to 0.6.3 (#2555) 2021-11-02 22:15:33 +01:00
Jon Cinque 01765b9953
stake-pool: Reduce wait for active stake merges (#2553)
* stake-pool: Reduce wait to one epoch for active merges

* Remove stake_program references

* Remove credits observed point from docs
2021-11-01 15:14:49 +01:00
Alexander Ray 287c3bedaf
stake-pool-cli: Fix prepare_withdraw_accounts issues (#2548)
* - fix prepare_withdraw_accounts issues

* - use reverse fee as workaround for withdraw issue
2021-10-26 23:13:59 +02:00
Jon Cinque cd3f5ae9fe
stake-pool: Add test for withdrawing all, with fee (#2550) 2021-10-26 22:50:16 +02:00
Jon Cinque 8be3ba819c
stake-pool-docs: Add the published audits (#2546) 2021-10-26 22:30:16 +02:00
Jon Cinque 756696ee8e
stake-pool-cli: Add validator list argument to create (#2545)
People want to know more about the validator list, but there isn't too
much info provided.

* Include the validator list as an optional parameter to pool creation
* Print out the address during creation
* Always print out the address during `list`
* Add docs about it
2021-10-25 23:13:58 +02:00
Michael Vines fca9836a2c Avoid MemcmpEncodedBytes::Binary 2021-10-20 22:52:19 -07:00
Michael Vines 9acb082dc3 Upgrade to Solana v1.8.1 2021-10-20 22:52:19 -07:00
Jon Cinque 4ab60e6794
stake-pool: Also set the sol deposit authority on init (#2532) 2021-10-20 01:45:00 +02:00
Jon Cinque 675d65b965
stake-pool-cli: Add more docs around scripts (#2531) 2021-10-20 01:29:00 +02:00
Jon Cinque 203db7bc3f
stake-pool-cli: Improve deposit and withdraw UX (#2530) 2021-10-19 23:30:41 +02:00
Jon Cinque c5e7ae736e
stake-pool: Add comment to validator stake info field (#2527) 2021-10-19 17:19:10 +02:00
Jon Cinque 1a48523a80
stake-pool: Remove copied stake program code (mostly) (#2526)
* stake-pool: Remove (mostly) the copied stake program

* Remove references to stake_program in CLI
2021-10-19 16:48:56 +02:00
Jon Cinque f95e390dd4
stake-pool: Clarify stake deposit fee (#2520) 2021-10-19 12:26:50 +02:00
Jon Cinque 3b48fa09d3
stake-pool: Cleanup documentation in code (#2525) 2021-10-19 01:50:35 +02:00
Jon Cinque 4658815e9f
stake-pool: Force pools to only use the SPL token program (#2521) 2021-10-19 01:39:57 +02:00
Jon Cinque 7f0278caa8
stake-pool: Add checked math to big vec calc (#2524) 2021-10-19 00:46:49 +02:00
Jon Cinque f97c61a9ed
stake-pool: Initialize all pool fields explicitly (#2523) 2021-10-19 00:46:39 +02:00
Jon Cinque 50b5597fcf
stake-pool: Improve error when overdrawing on decrease (#2522) 2021-10-19 00:45:46 +02:00
Alexander Ray 671590dd05
- reimplement prepare_withdraw_accounts according to the documentation (#2513)
* - reimplement prepare_withdraw_accounts according to the docu

* - add preferred withdraw validator

* - fix clippy issues

* - fix styling
2021-10-15 22:35:44 +02:00