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

v1.18: relax stake split destination check (backport of #162) #368

Merged
merged 1 commit into from
Mar 21, 2024

Conversation

mergify[bot]
Copy link

@mergify mergify bot commented Mar 21, 2024

Issue #147

####Improvements

  1. Removed strict checks for staked_split_account and allowed account owned by system program with no data and some lamports to be allocated as a new stake account to receive stake split

Summary of Changes

1 solana/cli/src/stake.rs
function - process_split_stake
removed some strict checks resulting in allowing system account (without data and some lamports) to be allocated as new stake account to receive split


This is an automatic backport of pull request #162 done by [Mergify](https://mergify.com).

* relax stake split destination check

* change stake_account error handling logic

* fmt

* modify logic

* change error message when account is neither owned by stake program or system program

* add a comment explaining nested ifs in stake_account error handling

* fix typos in comments

* update comment

(cherry picked from commit 6bcb77d)
@CriesofCarrots
Copy link

This is a solana-cli-only change, which is a precursor to this backport: #369
Both these PRs remove obstacles that exist for splitting stake now that solana-labs#33300 is active everywhere.

Copy link

@willhickey willhickey left a comment

Choose a reason for hiding this comment

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

Approved for backport to beta

@CriesofCarrots CriesofCarrots added the automerge automerge Merge this Pull Request automatically once CI passes label Mar 21, 2024
@mergify mergify bot merged commit 680d783 into v1.18 Mar 21, 2024
36 checks passed
@mergify mergify bot deleted the mergify/bp/v1.18/pr-162 branch March 21, 2024 18:27
anwayde pushed a commit to firedancer-io/agave that referenced this pull request Jul 23, 2024
…anza-xyz#368)

relax stake split destination check (anza-xyz#162)

* relax stake split destination check

* change stake_account error handling logic

* fmt

* modify logic

* change error message when account is neither owned by stake program or system program

* add a comment explaining nested ifs in stake_account error handling

* fix typos in comments

* update comment

(cherry picked from commit 6bcb77d)

Co-authored-by: Nagaprasad V R <81755170+Nagaprasadvr@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge automerge Merge this Pull Request automatically once CI passes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants