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

exit consume_buffered_packets early if empty #5149

Merged

Conversation

apfitzge
Copy link

@apfitzge apfitzge commented Mar 5, 2025

Problem

  • If there are no packets to process we can return immediately
  • There are some errors of missing sysvars for slot 0 that pop up in many test logs due to calls to this function...even if there are no votes to process!
Example Test Output
running 1 test
[2025-03-05T17:29:09.481913000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:09.582663000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:09.687719000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:09.789760000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:09.891041000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:09.996087000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.099869000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.204927000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.307708000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.407768000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.512830000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.617898000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.722953000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.828012000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:10.929943000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.031430000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.136513000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.241574000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.346634000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.448110000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.551050000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.656116000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.757775000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.862827000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:11.967878000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:12.072931000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:12.177988000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:12.278222000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:12.383270000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
[2025-03-05T17:29:12.488331000Z ERROR solana_core::banking_stage::latest_unprocessed_votes] Slot hashes sysvar doesn't exist on bank 0. Including all votes without filtering
test banking_stage::tests::test_banking_stage_entryfication::transactionstructure_view_expects ... ok

Summary of Changes

  • Immediately exit work loop if there is no work to do 🤯

Fixes #

@apfitzge apfitzge marked this pull request as ready for review March 5, 2025 17:30
@apfitzge apfitzge requested a review from steviez March 5, 2025 17:30
Copy link

@steviez steviez left a comment

Choose a reason for hiding this comment

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

LGTM

@apfitzge apfitzge merged commit 111c97c into anza-xyz:master Mar 5, 2025
47 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants