Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: typed txs provider / middleware changes (part 3) #357

Merged
merged 30 commits into from
Aug 9, 2021

Conversation

gakonst
Copy link
Owner

@gakonst gakonst commented Aug 1, 2021

  • Introduces new functions for manipulating the contents of TypedTransaction
  • Makes the gas price and gas escalator middlewares error with eip1559 txs (primarily because they are deprecated by eip1559)
  • Adds support for eth_feeHistory and eth_createAccessList
  • Adjust send_transaction to take T: Into<TypedTransaction>
  • Adjust estimate_gas, call, trace_call to take TypedTransaction (from TransactionRequest). You'll need to add a .into() in your calls to convert TransactionRequests to TypedTransactions.
  • Adds helper function at the base of the middleware stack for filling a transaction's information, to avoid leaking typed tx internals to other packages

@gakonst gakonst changed the title feat: typed txs provider / middleware changes feat: typed txs provider / middleware changes (part 3) Aug 1, 2021
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.

few nits.

ethers-core/src/types/transaction/eip2718.rs Outdated Show resolved Hide resolved
ethers-middleware/src/gas_escalator/mod.rs Show resolved Hide resolved
ethers-middleware/src/gas_escalator/mod.rs Outdated Show resolved Hide resolved
ethers-middleware/src/gas_escalator/mod.rs Outdated Show resolved Hide resolved
ethers-middleware/src/nonce_manager.rs Outdated Show resolved Hide resolved
ethers-providers/src/lib.rs Outdated Show resolved Hide resolved
ethers-providers/src/lib.rs Outdated Show resolved Hide resolved
ethers-providers/src/lib.rs Outdated Show resolved Hide resolved
Base automatically changed from feat/typed-txs-enum to master August 8, 2021 22:59
The GPO and the Escalators will throw an error if they are provided an EIP1559 transaction
1. Normalize v values for eip1559/2730
2. Make access lists mandatory for 1559
3. do not double-rlp on rlp_signed
@gakonst gakonst merged commit dcbfacf into master Aug 9, 2021
@gakonst gakonst deleted the feat/typed-txs-rpc branch August 9, 2021 00:31
meetmangukiya pushed a commit to meetmangukiya/ethers-rs that referenced this pull request Mar 21, 2022
* setup cli structure

(cherry picked from commit c9f4a6409f4079d355bc8043df6f7821e5c15bf5)

* setup cli structure

(cherry picked from commit 00628941e46cceaff7949a9e7e241a54f6e906e4)

* chore: move etherscan_api_key to foundry-utils crate

(cherry picked from commit 2ff02af62df0d8b57522e09156f645835c80fc5d)

* choore: move etherscan_api_aky to foundry-utils, add abi2decode

(cherry picked from commit e75c7621512243015322f4b797b9d0612f495e60)

* feat: generate interface from address

(cherry picked from commit 054cd8f05d2e19e913c12d89e897e0f15ed85538)

* fix: add pragma to interface output

(cherry picked from commit 5333a2183a96b22779f2a1d77545ef4f17dc1456)

* fix: compiler warnings

(cherry picked from commit 8aa1e9f634eda3c1092417dfc3a009033b5cd280)

* fix: remove unwrap_or_stdin

(cherry picked from commit 46ab0e5d33062c73efa489e20bfdf7839491a1ee)

* fix: interface print, create dir if not exist

(cherry picked from commit acdc408536af204f650075f6fbc9f0184a31c2e3)

* fix: improve dir management with pathbuf

(cherry picked from commit fb2cc003e227774e70368e8f0a20551205a77e2d)

* fix: multiple interfaces in the same file

(cherry picked from commit 2413a74f2057f2d62c68e18d979801b81803fbb5)

* fix: add pragma as input to command

(cherry picked from commit 8a9ddd95c018b2d30f24a5665b475cae357c596d)

* chore: more idiomatic rust_to_solidity

(cherry picked from commit 8dbcce14b99938fc989fd49dc0d2273b2b73b930)

* chore: add newline between structs

(cherry picked from commit 662af48a2448499a5066d59e7d18a232107db850)

* chore: improve pragma version, handle both empty and None

(cherry picked from commit 1adc61b5a3952fc97d0c6cf205da382676b0451b)

* fix: add function keyword

(cherry picked from commit 17b9528e31753b79025175972d16d63cf8aec379)

* fix: add space before return

(cherry picked from commit d5bd450c20ce8080e42bf6f1daa26c38beb78dbd)

* fix: remove unecessary mut variable while matching

(cherry picked from commit 548da17f292cf33444aa894787ce05b2558d5edb)

* feat: add chain selection

(cherry picked from commit a35fcfde148ed6444e3d51e28126b10d6ce26662)

* feat: add abi2solidity test

(cherry picked from commit 0620a56b7bbf59a23dabc7a0615c75fbda994c87)

* fix: cherry pick gone awry

* fix: extra space

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>

* fix: add features flag to tokio, serde; expand tests

* chore: cargo update, fmt, clippy

* chore: improve devex with flag arguments

* feat: flag args, etherscan as arg, abi from local file

* chore: add pragma as default to structopt, remove option

* chore: add mainnet default chain to structopt, remove option

* chore: add default Interface name for ABIs with no name provided

* Address gakonst comments

* fix: merge errors, chore: format/clippy

* fix: doc test

* chore: remove ;

* fix: address gakonst comments

* refactor(cli): use helper cli struct for Chain enum

* feat(cast): improve error msgs for getting etherscan source

These should probably be upstreamed in ethers-solc

* chain ops

* chore: cleanup concatenation of interfaces

* test(utils): fix sol test vectors

* feat(abi2sol): initial abi encoder v2 support

does not support nested structs, so won't fully work with interfaces like DyDx Solo margin,
but is a nice start

* chore: fmt / lints

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
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.

None yet

2 participants