As pointed out by @bzawisto (https://github.com/Zilliqa/zq2/pull/1393#issuecomment-2329124425), we are cloning the transaction pool when we construct a block. Not only is this probably bad for performance, but its also a bit of a vulnerability. A user is perfectly able to fill up the transaction pool with a bunch of transactions that are not (yet) mineable, which we end up having to make clones of every time we want to propose a block.
As pointed out by @bzawisto (https://github.com/Zilliqa/zq2/pull/1393#issuecomment-2329124425), we are cloning the transaction pool when we construct a block. Not only is this probably bad for performance, but its also a bit of a vulnerability. A user is perfectly able to fill up the transaction pool with a bunch of transactions that are not (yet) mineable, which we end up having to make clones of every time we want to propose a block.