Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion core/rawdb/accessors_chain.go
Original file line number Diff line number Diff line change
Expand Up @@ -619,7 +619,7 @@ type storedReceiptRLP struct {
CumulativeGasUsed uint64
Logs []*types.LogForStorage
L1Fee *big.Int
FeeTokenID *uint16
FeeTokenID *uint64
FeeRate *big.Int
TokenScale *big.Int
FeeLimit *big.Int
Expand Down
2 changes: 1 addition & 1 deletion core/state_processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ func ApplyTransactionWithEVM(msg Message, config *params.ChainConfig, gp *GasPoo
receipt.TransactionIndex = uint(statedb.TxIndex())
receipt.L1Fee = result.L1DataFee
if tx.IsAltFeeTx() {
tokenID := tx.FeeTokenID()
tokenID := uint64(tx.FeeTokenID())
receipt.FeeTokenID = &tokenID
receipt.FeeLimit = tx.FeeLimit()
receipt.FeeRate = result.FeeRate
Expand Down
49 changes: 24 additions & 25 deletions core/types/gen_receipt_json.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions core/types/l2trace.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@ type StorageTrace struct {
// execution status, the amount of gas used and the return value
type ExecutionResult struct {
L1DataFee *hexutil.Big `json:"l1DataFee,omitempty"`
FeeTokenID *uint16 `json:"fee_token_id,omitempty"`
FeeTokenID *uint64 `json:"feeTokenID,omitempty"`
FeeRate *hexutil.Big `json:"feeRate,omitempty"`
TokenScale *hexutil.Big `json:"token_scale,omitempty"`
TokenScale *hexutil.Big `json:"tokenScale,omitempty"`
Comment thread
curryxbo marked this conversation as resolved.
FeeLimit *hexutil.Big `json:"feeLimit,omitempty"`
Gas uint64 `json:"gas"`
Failed bool `json:"failed"`
Expand Down Expand Up @@ -138,7 +138,7 @@ type TransactionData struct {
GasPrice *hexutil.Big `json:"gasPrice"`
GasTipCap *hexutil.Big `json:"gasTipCap"`
GasFeeCap *hexutil.Big `json:"gasFeeCap"`
FeeTokenID *uint16 `json:"feeTokenID,omitempty"`
FeeTokenID *uint64 `json:"feeTokenID,omitempty"`
FeeLimit *hexutil.Big `json:"feeLimit,omitempty"`
From common.Address `json:"from"`
To *common.Address `json:"to"`
Expand Down Expand Up @@ -197,7 +197,7 @@ func NewTransactionData(tx *Transaction, blockNumber uint64, blockTime uint64, c

// Set FeeTokenID and FeeLimit for AltFeeTx
if tx.Type() == AltFeeTxType {
feeTokenID := tx.FeeTokenID()
feeTokenID := uint64(tx.FeeTokenID())
if feeTokenID != 0 {
result.FeeTokenID = &feeTokenID
}
Expand Down
14 changes: 9 additions & 5 deletions core/types/receipt.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,9 @@ type Receipt struct {
// Morph rollup
L1Fee *big.Int `json:"l1Fee,omitempty"`
// Alt Fee
FeeTokenID *uint16 `json:"fee_token_id,omitempty"`
FeeRate *big.Int `json:"fee_rate,omitempty"`
TokenScale *big.Int `json:"token_scale,omitempty"`
FeeTokenID *uint64 `json:"feeTokenID,omitempty"`
FeeRate *big.Int `json:"feeRate,omitempty"`
TokenScale *big.Int `json:"tokenScale,omitempty"`
FeeLimit *big.Int `json:"feeLimit,omitempty"`
Comment thread
curryxbo marked this conversation as resolved.
}

Expand All @@ -97,6 +97,10 @@ type receiptMarshaling struct {
BlockNumber *hexutil.Big
TransactionIndex hexutil.Uint
L1Fee *hexutil.Big
FeeTokenID *hexutil.Uint64
FeeRate *hexutil.Big
TokenScale *hexutil.Big
FeeLimit *hexutil.Big
}

// receiptRLP is the consensus encoding of a receipt.
Expand All @@ -113,7 +117,7 @@ type storedReceiptRLP struct {
CumulativeGasUsed uint64
Logs []*LogForStorage
L1Fee *big.Int
FeeTokenID *uint16
FeeTokenID *uint64
FeeRate *big.Int
TokenScale *big.Int
FeeLimit *big.Int
Expand All @@ -127,7 +131,7 @@ type v7StoredReceiptRLP struct {
CumulativeGasUsed uint64
Logs []*LogForStorage
L1Fee *big.Int
FeeTokenID *uint16
FeeTokenID *uint64
FeeRate *big.Int
TokenScale *big.Int
FeeLimit *big.Int
Expand Down
4 changes: 2 additions & 2 deletions internal/ethapi/transaction_args.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ type TransactionArgs struct {
Input *hexutil.Bytes `json:"input"`

// AltFeeTxType
FeeTokenID *hexutil.Uint64 `json:"fee_token_id,omitempty"`
FeeLimit *hexutil.Big `json:"fee_limit,omitempty"`
FeeTokenID *hexutil.Uint64 `json:"feeTokenID,omitempty"`
FeeLimit *hexutil.Big `json:"feeLimit,omitempty"`
Comment thread
curryxbo marked this conversation as resolved.

// Introduced by AccessListTxType transaction.
AccessList *types.AccessList `json:"accessList,omitempty"`
Expand Down
Loading