Skip to content

Conversation

@0xKarl98
Copy link

This aims at resolve issue #1764

cc @mattsse

@vercel
Copy link

vercel bot commented Dec 26, 2025

@0xKarl98 is attempting to deploy a commit to the Tempo Team on Vercel.

A member of the Team first needs to authorize it.

.map(|tx| tx.into_inner())
})
.collect::<Vec<_>>();
let mut txs = Vec::with_capacity(tx_hashes.len());
Copy link
Collaborator

Choose a reason for hiding this comment

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

this could over allocate

Comment on lines 358 to 362
for tx in self.aa_2d_pool.read().get_all_iter(&tx_hashes) {
// Safe unwrap: TryFromConsensusError is Infallible for TempoPooledTransaction.
let pooled = tx.transaction.clone_into_pooled().unwrap();
txs.push(pooled.into_inner());
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

instead of this we could simple flip it and first obtain a vec from

self.protocol_pool
                .get_pooled_transaction_elements

and then extend that

if you want you can also submit a pr that adds fn append_pooled_transaction_elements variant for this:

https://github.com/paradigmxyz/reth/blob/8ae7a1c8d14025243919d9c05d3505ef414f6937/crates/transaction-pool/src/pool/mod.rs#L402-L411

similar to

https://github.com/paradigmxyz/reth/blob/8ae7a1c8d14025243919d9c05d3505ef414f6937/crates/transaction-pool/src/pool/mod.rs#L321-L325

@0xKarl98 0xKarl98 requested a review from mattsse December 27, 2025 12:12
@0xKarl98
Copy link
Author

0xKarl98 commented Dec 27, 2025

pending @mattsse

@0xKarl98 0xKarl98 marked this pull request as draft December 28, 2025 07:14
@0xKarl98 0xKarl98 marked this pull request as ready for review December 28, 2025 08:08
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