We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
node-bindings
latest
macOS (Apple Silicon)
I found a regression when updating alloy from 0.9.2 to 0.11.0.
0.9.2
0.11.0
wrote a small test that reproduces the issue:
#[tokio::test] async fn test_mine_many_blocks() { // 328 passes, 329 fails let blocks_to_mine = 329; let args = vec!["--base-fee", "0", "--gas-limit", "30000000", "--timestamp", "999", "--no-mining"]; let anvil = alloy_node_bindings::Anvil::new().args(args).spawn(); let provider = ProviderBuilder::new().on_http(anvil.endpoint_url()); let head = provider.get_block(alloy_eips::BlockId::latest(), false.into()).await.unwrap().unwrap(); assert_eq!(head.header.number, 0); let ts = head.header.timestamp; // Mine N blocks using anvil_mine_detailed for i in 0..blocks_to_mine { let mine_options = MineOptions::Options { timestamp: Some(ts + i + 1), blocks: Some(1) }; provider.anvil_mine_detailed(Some(mine_options)).await.unwrap(); } // Verify block number is at least 1000 let final_block = provider.get_block_number().await.unwrap(); assert!( final_block >= blocks_to_mine, "Expected at least {} blocks, got {}", blocks_to_mine, final_block ); }
For some reason, on the latest version, that test will hang forever if I try to mine 329+ blocks. With less blocks, it passes.
I bissected this behavior and found the following:
70df381dd5ae09133137bd8c51b5c7f3530445c9 is the first bad commit commit 70df381dd5ae09133137bd8c51b5c7f3530445c9 (HEAD) Author: Yash Atreya <[email protected]> Date: Thu Jan 16 00:00:21 2025 +0530 fix(`node-bindings`): reset `child.stdout` in `AnvilInstance` (#1920) * feat(`node-bindings`): expose `stdout` reader * remove reader and reset child.stdout * Update crates/node-bindings/src/nodes/anvil.rs --------- Co-authored-by: DaniPopes <[email protected]> crates/node-bindings/src/nodes/anvil.rs | 4 +++- crates/provider/src/provider/trait.rs | 28 +++++++++++++++++++++++++++- 2 files changed, 30 insertions(+), 2 deletions(-)
removing this line seems to fix the issue.
Please assist 🙏
The text was updated successfully, but these errors were encountered:
yeah this pr doesn't look right
#1920
this will now fill the stdout buffer and blocks, checking
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
Component
node-bindings
What version of Alloy are you on?
latest
Operating System
macOS (Apple Silicon)
Describe the bug
I found a regression when updating alloy from
0.9.2
to0.11.0
.wrote a small test that reproduces the issue:
For some reason, on the latest version, that test will hang forever if I try to mine 329+ blocks. With less blocks, it passes.
I bissected this behavior and found the following:
removing this line seems to fix the issue.
Please assist 🙏
The text was updated successfully, but these errors were encountered: