* stake-pool-cli: Fix update command, add verbosity
The update command in the stake pool CLI was passing the validator vote
account instead of the associated stake account from the pool, causing
it to fail. Additionally, add more verbose logging, and a dry-run mode
to get simulate transaction information, useful for debugging CLI
failures.
* Run cargo fmt
* stake-pool: Validator stake account initialized with 1 SOL
A validator stake account only has 1 lamport, which means that it will
gain very few rewards per epoch. Its credits_observed is not
be reset each epoch, which makes it practically impossible to merge
into. Get around this by instantiating them with more stake.
* Cargo fmt + fix tests
* Various postponed fixes and changes to the stake pool program
* Fixed PR comments
* Fixed no-signature validator stake account add test
Co-authored-by: Yuriy Savchenko <yuriy.savchenko@gmail.com>
* Added validator stake account list storage, deprecated old tests
* Added join and leave stake pool instructions, error messages refactoring
* Stake pool tests refactoring, tests for join and leave pool added
* Added validator stake account creation instruction, join/leave pool instructions renamed, version field added
* Formatting fixes
* Added update list/pool instructions (no tests yet), updated deposit instruction logic, claim instruction removed, refactoring
* Updated deposit logic and tests, updated withdraw logic and added tests, refactoring
* Stake pool CLI updated to work with new deposit/withdraw instructions, claim usage removed
* Added validator stake account management and balance update commands to the stake pool CLI, updated dependency versions, updated devnet program address
* Merge conflicts fixed
* Removed deprecated tests
* Fixes for review comments
* Additional program id checks across the code
* Formatting errors fixed
* Changed minimum stake balance in CLI, removed deprecated tests, removed check for stake history id
* Added TODO for stake account warmup status check
* Cargo.lock conflict fix
* Formatting fixed
* Update Cargo lock file for CI
* Pin themis version of subtle
Co-authored-by: Yuriy Savchenko <yuriy.savchenko@gmail.com>
* WIP: stake-pool: Add end-to-end testing using ProgramTest
* Run cargo fmt
* Add deposit test and extra requirements
* Update Cargo.lock after rebuild
* Bring token program sdk version back to 1.4.7
* Added set-staking-auth and set-owner commands to stake pool CLI
* Error handling refactored, fixed new fee owner setting, fixed set owner arg group settings
* Added check for fee account mint to stake pool initialization and set owner methods
* Implemented stake-pool CLI with create-pool, deposit, list and withdraw commands, fixed several bugs in underlying smart contract
* Several typos fixed, some error text clarifications.
* Fee parameter in stake pool creation changed into two: numarator and demoninator
* Refactoring to resolve pool request comments
* Added merge to stake_receiver account when claiming whole stake account
* Removed unused import
* Withdraw bump seed calculation fixed
* Added positive tests for withdraw, claim, set owner, set authority, several bugs fixed
* Fixed PR comments
* Fixed constant with leading zero
* Deposit tests refactoring
* Interface accounts added as read-only, fixed mint authority on deposit, fixed stake pool stake deserializing
* Unit test refactoring, added success tests for deposit, updated stake account program id
* Warnings fixed
* Removed random key generation, used Pubkey::new_unique instead
* Imports optimization
* Unit test architecture updated to remove separate invoke_signed declarations
* Added missing accounts (sysvar clock and stake account program id) to calls to stake account program
* Fixed formatting
* Fixed stake pool deposit unit test
* Temporarily removed stake-pool cli from main workspace
* Fixed warning in token program
* Fixed warning in token program v3
* Fixed warnings in token swap program
* Fixed warning in token cli
* Sysvar and program id params reordered
* Interface accounts added as read-only, fixed mint authority on deposit, fixed stake pool stake deserializing
* Unit test refactoring, added success tests for deposit, updated stake account program id
* Warnings fixed
* Removed random key generation, used Pubkey::new_unique instead
* Imports optimization
* Unit test architecture updated to remove separate invoke_signed declarations
* Added address type in programm address generation for the stake pool, renamed nonce to bump seed
* Formatting fixed
* Bump seed calculation moved to the smart contract, test for fee > 1 added, state length public constant added
* Added claim method to stake pool, fixed program address generation in token mint and burn calls
* Refactored signers management when calling other contracts
* Signers formation put back into calling functions, deposit/withdraw/claim method reworked, state serialization bug fixed
* Added instruction interface methods
* Fixed signer flags for accounts in stake pool instruction creation
* Added address type in programm address generation for the stake pool, renamed nonce to bump seed
* Formatting fixed
* Bump seed calculation moved to the smart contract, test for fee > 1 added, state length public constant added
* Added claim method to stake pool, fixed program address generation in token mint and burn calls
* Refactored signers management when calling other contracts
* Signers formation put back into calling functions, deposit/withdraw/claim method reworked, state serialization bug fixed