Repository navigation
feat: prevent commits for confined accounts #690
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
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
7caed5e
chore: update solana-account version to get confined flag
thlorenz 27fd6e9
feat: set confined flag from delegation record info
thlorenz 8e22eb8
feat: respect confined flag when cloning non-program accounts
thlorenz 7dda02a
Merge branch 'master' into thlorenz/confined
thlorenz 8f348c7
feat: confined flag setting tested
thlorenz db58c2e
Merge branch 'master' into thlorenz/confined
thlorenz 15a1cdb
feat: prevent scheduling commits if confined accounts are involved
thlorenz 9656446
chore: check confined account remains delegated on commit failure
thlorenz 1ac8674
chore: adding more checks to confined account tests
thlorenz 74168ee
chore: fix wording in test error message
thlorenz b0cc641
chore: add one more check to confined tests
thlorenz 103322a
Merge branch 'master' into thlorenz/confined
thlorenz File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧹 Nitpick | 🔵 Trivial
Make unused return value explicit for clarity.
In this subscription update context, the
commit_frequency_msreturn value is intentionally unused (line 273 hardcodes it toNone). However, for clarity and to avoid potential clippy warnings, consider explicitly discarding the return value:📝 Committable suggestion
🤖 Prompt for AI Agents
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should only be done for results, but here we just don't need the commit frequency, so it's fine to just ignore the return value.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@thlorenz, you're absolutely right. The
let _ = ...pattern is conventionally used forResulttypes to make it explicit that you're intentionally ignoring potential errors. Sinceapply_delegation_record_to_accountreturnsOption<u64>(not aResult), it's perfectly idiomatic in Rust to call it without explicitly discarding the return value when you don't need it. The current code is fine as-is.🧠 Learnings used