Skip to content

Conversation

@rakita
Copy link
Collaborator

@rakita rakita commented Feb 13, 2024

In two places we didn't set optimism flag

In the Node builder trait in crates/node-api/src/engine/traits.rs. @mattsse check if this is a bug or not, maybe it is overwritten.

And in crates/rpc/rpc/src/eth/api/call.rs flag would be lost.

Will add proper constructors to revm but to fix it asap this should be fine

should close #6593

@rakita rakita changed the title fix: set optimism flag correctly fix(op): set optimism flag correctly Feb 13, 2024
}

#[cfg(not(feature = "optimism"))]
let cfg_with_handler_cfg = CfgEnvWithHandlerCfg::new(cfg, spec_id);
Copy link
Collaborator Author

@rakita rakita Feb 13, 2024

Choose a reason for hiding this comment

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

If we use ::new here is_optimism flag would be set to false


let cfg_with_spec_id = CfgEnvWithHandlerCfg::new(env.cfg.clone(), env.handler_cfg.spec_id);
let cfg_with_spec_id =
CfgEnvWithHandlerCfg { cfg_env: env.cfg.clone(), handler_cfg: env.handler_cfg.clone() };
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Here is_optimism flag would be lost

Copy link
Member

@Rjected Rjected left a comment

Choose a reason for hiding this comment

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

I see, yeah setting if is_optimism makes sense here. would also add docs saying that is_optimism is set to false when new is used

@rakita
Copy link
Collaborator Author

rakita commented Feb 13, 2024

I see, yeah setting if is_optimism makes sense here. would also add docs saying that is_optimism is set to false when new is used

Have added the proper constructor here: bluealloy/revm#1087

Where did you mean to add the doc in revm?

@Rjected
Copy link
Member

Rjected commented Feb 13, 2024

I see, yeah setting if is_optimism makes sense here. would also add docs saying that is_optimism is set to false when new is used

Have added the proper constructor here: bluealloy/revm#1087

Where did you mean to add the doc in revm?

Just above new, as a doc comment here https://github.com/bluealloy/revm/blob/0651044b7ad7e8eaacf6650d64abb7a927e867f3/crates/primitives/src/env/handler_cfg.rs#L58

@rakita rakita added this pull request to the merge queue Feb 13, 2024
Merged via the queue into main with commit 4b21cf6 Feb 13, 2024
@rakita rakita deleted the rakita_fix_is_op_correctly branch February 13, 2024 23:52
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

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

I'm losing my mind with the semicolon back and forth

@zilayo
Copy link
Contributor

zilayo commented Feb 14, 2024

unfortunately still seeing the same

2024-02-14T00:16:43.247799Z TRACE payload_builder: Error in sequencer transaction, skipping. err=GasPriceLessThanBasefee sequencer_tx=TransactionSignedEcRecovered { signer: 0xdeaddeaddeaddeaddeaddeaddeaddeaddead0001, signed_transaction: TransactionSigned { hash: 0x0e857b761b597ab9822686094f163b2854fbe8bab1605db314085598f907c633, signature: Signature { r: 0x0_U256, s: 0x0_U256, odd_y_parity: false }, transaction: Deposit(TxDeposit { source_hash: 0xa47b9fcfd83f311f99381963ddc4ed2c3dfb0237772d51aca1446efff4fd2ad1, from: 0xdeaddeaddeaddeaddeaddeaddeaddeaddead0001, to: Call(0x4200000000000000000000000000000000000015), mint: None, value: TxValue(0x0_U256), gas_limit: 1000000, is_system_transaction: false, input: 0x015d8eb90000000000000000000000000000000000000000000000000000000001252b530000000000000000000000000000000000000000000000000000000065ca47630000000000000000000000000000000000000000000000000000000905c8d3ca0e3da5fbee17c50ce24e742ebefa28907988cc116221ca539de59464a6d6b4d8000000000000000000000000000000000000000000000000000000000000000000000000000000000000000099199a22125034c808ff20f377d91187e8050f2e00000000000000000000000000000000000000000000000000000000000000bc00000000000000000000000000000000000000000000000000000000000a6fe0 }) } }
2024-02-14T00:16:43.247843Z TRACE payload_builder: Error in sequencer transaction, skipping. err=GasPriceLessThanBasefee sequencer_tx=TransactionSignedEcRecovered { signer: 0xa6ceca6c8edeb69c98bd5bd17660bacef1299b80, signed_transaction: TransactionSigned { hash: 0xa23e0e1ee8870ddc4e5c1b9c45cfd0d8f852a15ff5538df5f9299a9ebc9da2bd, signature: Signature { r: 0x0_U256, s: 0x0_U256, odd_y_parity: false }, transaction: Deposit(TxDeposit { source_hash: 0xd556217e25d9513b4eea5ae2bd9aea5eef4853caeec38d16230c42fac3eb5719, from: 0xa6ceca6c8edeb69c98bd5bd17660bacef1299b80, to: Call(0x4200000000000000000000000000000000000007), mint: Some(12000000000000000), value: TxValue(0x000000000000000000000000000000000000000000000000002aa1efb94e0000_U256), gas_limit: 288136, is_system_transaction: false, input: 0xd764ad0b000100000000000000000000000000000000000000000000000000000001b8cd000000000000000000000000735adbbe72226bd52e818e7181953f42e3b0ff210000000000000000000000004200000000000000000000000000000000000010000000000000000000000000000000000000000000000000002aa1efb94e0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000c41635f5fd0000000000000000000000002971b9b03e665b81a4a322eac998ce4e0693f7dc0000000000000000000000002971b9b03e665b81a4a322eac998ce4e0693f7dc000000000000000000000000000000000000000000000000002aa1efb94e00000000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000001e55625344576b4c56485a6f307330567a3738495446373044686d56624158000000000000000000000000000000000000000000000000000000000000 }) } }

i thought fixing cfg_and_block_env should have solved it, but seems not

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.

5 participants