Skip to content

Conversation

howjmay
Copy link
Member

@howjmay howjmay commented Aug 31, 2025

No description provided.

@howjmay howjmay force-pushed the support-addr branch 17 times, most recently from 8506003 to 473a1dc Compare September 8, 2025 08:55
@howjmay howjmay marked this pull request as ready for review September 8, 2025 08:56
@howjmay howjmay force-pushed the support-addr branch 2 times, most recently from e08b0ca to 0f82ba7 Compare September 9, 2025 06:32

func Signer(chainID *big.Int) types.Signer {
return types.NewEIP155Signer(chainID)
return types.NewPragueSigner(chainID)
Copy link
Contributor

Choose a reason for hiding this comment

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

What is the consequence of changing this? Can it affect tracing old transactions?

Copy link
Member Author

Choose a reason for hiding this comment

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

It supports old transactions here is the snippet from https://github.com/ethereum/go-ethereum/blob/ca6e2d141b14e67d2ba826c6213e9e413148b6ec/core/types/transaction_signing.go#L279

// NewPragueSigner returns a signer that accepts
// - EIP-7702 set code transactions
// - EIP-4844 blob transactions
// - EIP-1559 dynamic fee transactions
// - EIP-2930 access list transactions,
// - EIP-155 replay protected transactions, and
// - legacy Homestead transactions.
func NewPragueSigner(chainId *big.Int) Signer {
	return newModernSigner(chainId, forks.Prague)
}

And in func newModernSigner(chainID *big.Int, fork forks.Fork) Signer
it set up the legacy signer as we are doing right now

// configure legacy signer
	switch {
	case fork >= forks.SpuriousDragon:
		s.legacy = NewEIP155Signer(chainID)

So it will use EIP155 signer for legacy tx, and other signers in the corresponding scenarios

I have change the signer of a test to get the prague signer, and it works well

S *hexutil.Big `json:"s"`

// Typed-transaction metadata (EIP-2718)
Type hexutil.Uint64 `json:"type"` // 0x0,0x1,0x2,0x3
Copy link
Contributor

Choose a reason for hiding this comment

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

Again, will this change affect tracing old transactions?

receipt := env.mustSendTransactionAndWait(types.MustSignNewTx(
creator,
types.NewEIP155Signer(big.NewInt(int64(env.ChainID))),
env.Signer(),
Copy link
Member Author

Choose a reason for hiding this comment

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

Here is the change to test how the prague signer works for LegacyTx

@howjmay howjmay force-pushed the support-addr branch 2 times, most recently from f62eed6 to ce6324a Compare October 3, 2025 20:22
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