Commit Graph

14 Commits

Author SHA1 Message Date
ucwong
fa1305f8bf
internal/ethapi: fix comment typo (#25548) 2022-08-19 09:01:09 +03:00
lightclient
0be9d76e37
internal/ethapi: rework setDefaults for tx args so fee logic is separate (#25197)
Co-authored-by: bobpkr <bob.p@krustuniverse.com>
2022-08-11 10:56:53 +02:00
lightclient
434ca026c9
internal/ethapi: error if tx args includes chain id that doesn't match local (#25157)
* internal/ethapi: error if tx args includes chain id that doesn't match local

* internal/ethapi: simplify code a bit

Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2022-07-14 13:17:25 +03:00
Denver
03aaea11d1
internal/ethapi: use same receiver names (#24252)
* Chore: use same receiver names

* Fix syntax issues
2022-01-20 10:38:42 +02:00
lightclient
ffae2043f0
internal/ethapi: support both input and data for personal_sendTransaction (#23476)
Currently, setDefaults overwrites the transaction input value if only input is provided. This causes personal_sendTransaction to estimate the gas based on a transaction with empty data. eth_estimateGas never calls setDefaults so it was unaffected by this.
2021-08-27 14:11:15 +02:00
Marius van der Wijden
d02c605367
core: only check sendernoeoa in non fake mode (#23424) 2021-08-23 12:49:39 +03:00
Martin Holst Swende
278ec7176a
internal/ethapi: add back missing check for maxfee < maxPriorityFee 2021-08-12 08:14:21 +02:00
Martin Holst Swende
5c13012b56
accounts/external, internal/ethapi: fixes for London tx signing (#23274)
Ticket #23273 found a flaw where we were unable to sign legacy-transactions
using the external signer, even if we're still on non-london network. That's
fixed in this PR.

Additionally, I found that even when supplying all parameters, it was impossible
to sign a london-transaction on an unsynched node. It's a pretty common usecase
that someone wants to sign a transaction using an unsynced 'vanilla' node,
providing all necessary data. Our setDefaults, however, insisted on checking the
current block against the config. This PR therefore adds a case, so that if both
MaxPriorityFeePerGas and MaxFeePerGas are provided, we accept them as given.

OBS This PR fixes a regression -- on current master, we are unable to sign a
london-transaction unless the node is synched, which may break scenarios where
geth (or clef) is used as a cold wallet.

Fixes #23273
2021-07-29 14:00:06 +02:00
gary rong
846badc480
internal/ethapi: fix transaction APIs (#23179)
* internal/ethapi: fix transaction APIs

* internal/ethapi: fix typo

* internal/ethapi: address comments

* internal/ethapi: address comment from Peter
2021-07-13 13:40:01 +03:00
Péter Szilágyi
f68a68a313
core, internal: support various eth_call invocations post 1559 2021-06-10 08:02:51 +03:00
Martin Holst Swende
7a00378e2b
cmd/clef, signer: support for eip-1559 txs in clef (#22966) 2021-06-09 13:48:47 +02:00
Péter Szilágyi
c503f98f6d
all: rename internal 1559 gas fields, add support for graphql (#23010)
* all: rename internal 1559 gas fields, add support for graphql

* cmd/evm/testdata, core: use public 1559 gas names on API surfaces
2021-06-08 12:05:41 +02:00
Martin Holst Swende
5cff9754d7
core, eth, internal, les: RPC methods and fields for EIP 1559 (#22964)
* internal/ethapi: add baseFee to RPCMarshalHeader

* internal/ethapi: add FeeCap, Tip and correct GasPrice to EIP-1559 RPCTransaction results

* core,eth,les,internal: add support for tip estimation in gas price oracle

* internal/ethapi,eth/gasprice: don't suggest tip larger than fee cap

* core/types,internal: use correct eip1559 terminology for json marshalling

* eth, internal/ethapi: fix rebase problems

* internal/ethapi: fix rpc name of basefee

* internal/ethapi: address review concerns

* core, eth, internal, les: simplify gasprice oracle (#25)

* core, eth, internal, les: simplify gasprice oracle

* eth/gasprice: fix typo

* internal/ethapi: minor tweak in tx args

* internal/ethapi: calculate basefee for pending block

* internal/ethapi: fix panic

* internal/ethapi, eth/tracers: simplify txargs ToMessage

* internal/ethapi: remove unused param

* core, eth, internal: fix regressions wrt effective gas price in the evm

* eth/gasprice: drop weird debug println

* internal/jsre/deps: hack in 1559 gas conversions into embedded web3

* internal/jsre/deps: hack basFee to decimal conversion

* internal/ethapi: init feecap and tipcap for legacy txs too

* eth, graphql, internal, les: fix gas price suggestion on all combos

* internal/jsre/deps: handle decimal tipcap and feecap

* eth, internal: minor review fixes

* graphql, internal: export max fee cap RPC endpoint

* internal/ethapi: fix crash in transaction_args

* internal/ethapi: minor refactor to make the code safer

Co-authored-by: Ryan Schneider <ryanleeschneider@gmail.com>
Co-authored-by: lightclient@protonmail.com <lightclient@protonmail.com>
Co-authored-by: gary rong <garyrong0905@gmail.com>
Co-authored-by: Péter Szilágyi <peterke@gmail.com>
2021-06-02 16:13:10 +03:00
gary rong
51b32cc7e4
internal/ethapi: merge CallArgs and SendTxArgs (#22718)
There are two transaction parameter structures defined in
the codebase, although for different purposes. But most of
the parameters are shared. So it's nice to reduce the code
duplication by merging them together.

Co-authored-by: Martin Holst Swende <martin@swende.se>
2021-05-25 22:30:21 +02:00