reth
reth copied to clipboard
Replace ethsigner trait with alloy-signer
Describe the feature
we now have alloy-signer as dependency, and the EthSigner
trait:
https://github.com/paradigmxyz/reth/blob/b89af430e2f45f8a6e53776a6e5150c1b21458c6/crates/rpc/rpc/src/eth/signer.rs#L19-L19
can now be replaced with alloy signer traits (NetworkSigner)
we can also replace all the typedtransaction types: https://github.com/paradigmxyz/reth/blob/b89af430e2f45f8a6e53776a6e5150c1b21458c6/crates/rpc/rpc-types/src/eth/transaction/typed.rs#L18-L18
in favor of https://github.com/alloy-rs/alloy/blob/098907b76208f786f3070e23c76428d692e94dc3/crates/network/src/transaction/builder.rs#L48-L48 which is implemented for TransactionRequest
https://github.com/alloy-rs/alloy/blob/098907b76208f786f3070e23c76428d692e94dc3/crates/network/src/transaction/builder.rs#L212-L216
cc @allnil
Additional context
No response
will take a look
thanks @justcode740, you're already assigned to a few other issues. I'll leave this open in case anyone else wants to take this or until you've wrapped up the others :)
will look at it
Hey @allnil, what's the status of this?
@onbjerg hey! going to finish it this week
in progress
@allnil update on this?
Describe the feature
we now have alloy-signer as dependency, and the
EthSigner
trait:https://github.com/paradigmxyz/reth/blob/b89af430e2f45f8a6e53776a6e5150c1b21458c6/crates/rpc/rpc/src/eth/signer.rs#L19-L19
can now be replaced with alloy signer traits (NetworkSigner)
we can also replace all the typedtransaction types:
https://github.com/paradigmxyz/reth/blob/b89af430e2f45f8a6e53776a6e5150c1b21458c6/crates/rpc/rpc-types/src/eth/transaction/typed.rs#L18-L18
in favor of https://github.com/alloy-rs/alloy/blob/098907b76208f786f3070e23c76428d692e94dc3/crates/network/src/transaction/builder.rs#L48-L48 which is implemented for
TransactionRequest
https://github.com/alloy-rs/alloy/blob/098907b76208f786f3070e23c76428d692e94dc3/crates/network/src/transaction/builder.rs#L212-L216
cc @allnil
Additional context
No response
Hey @mattsse! Is this issue open to work?
hey @kamuik16 are you still interested in this?
yeh, guys, sorry, I don't have capacity to finish it, pretty big issue and I was quite overloaded
all good, the draft should be useful for anyone that'll pick this up, ty @allnil
@mattsse that’s interesting. I’m finishing my last issue and go for this
@mattsse, will all components that implement the trait EthSigner
possibly be changed?
I think we can keep the trait but hide the signing internally like:
https://github.com/alloy-rs/alloy/blob/c3ccf7e2c5f9720fa6c193a9ea918aabf88aa6a2/crates/network/src/transaction/signer.rs#L51-L60
similar to:
https://github.com/paradigmxyz/reth/pull/8614/files#diff-fc791d9a535c846c23e379d9e1656f7c2f5974e06c91da0ce8d89e0322b1696bR1063-R1072
I'm fine with the rlp roundtrip
I think we can keep the trait but hide the signing internally like:
https://github.com/alloy-rs/alloy/blob/c3ccf7e2c5f9720fa6c193a9ea918aabf88aa6a2/crates/network/src/transaction/signer.rs#L51-L60
similar to:
https://github.com/paradigmxyz/reth/pull/8614/files#diff-fc791d9a535c846c23e379d9e1656f7c2f5974e06c91da0ce8d89e0322b1696bR1063-R1072
I'm fine with the rlp roundtrip
well, what I was wondering:
continue with trait EthSigner
and only assigns it with Signer
from alloy-signer
cc @mattsse
I think we can keep the trait but hide the signing internally like:
https://github.com/alloy-rs/alloy/blob/c3ccf7e2c5f9720fa6c193a9ea918aabf88aa6a2/crates/network/src/transaction/signer.rs#L51-L60
similar to:
https://github.com/paradigmxyz/reth/pull/8614/files#diff-fc791d9a535c846c23e379d9e1656f7c2f5974e06c91da0ce8d89e0322b1696bR1063-R1072
I'm fine with the rlp roundtrip
btw, this makes sense if we keep the trait, maybe could be benefincial for we...
marking this as completed per #11089