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

Executor: test Tx_count limit with incorrect tx source #2242

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

acerone85
Copy link
Contributor

Linked Issues/PRs

Closes #2225

Description

As per discussion, we should check that the current Executor logic is resilient against transactions source that ignore the limit on MAX_TX_COUNT.

Checklist

  • New behavior is reflected in tests

Before requesting review

  • I have reviewed the code myself

@acerone85 acerone85 added the no changelog Skip the CI check of the changelog modification label Sep 24, 2024
/// that should be returned by [`TransactionsSource::next()`].
/// It is used only for testing purposes
pub struct BadTransactionsSource {
transactions: Mutex<RefCell<Vec<MaybeCheckedTransaction>>>,
Copy link
Collaborator

Choose a reason for hiding this comment

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

You either need to use RefCell or Mutex=D Both is too much=D

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah yes, I can access the data as mutable from the Lock, my bad. Fixed in 8d5e04c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no changelog Skip the CI check of the changelog modification
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Test that executor is resilient against bad transaction sources
2 participants