Commit Graph

1729 Commits

Author SHA1 Message Date
DaniPopes 015eeabea8
feat(contract): return multicall pending transaction (#2044)
* feat(contract): return multicall pending transaction

* fix: tests

* docs: update CHANGELOG.md
2023-01-11 19:30:56 -08:00
DaniPopes b4b153a364
perf(utils): avoid unnecessary allocations (#2046)
* perf(utils): avoid unnecessary allocations

* docs: add more to_checksum information

* docs

* use address
2023-01-11 19:20:35 -08:00
joshieDo 3c65997eae
feat(core): add `strum::EnumIter` and `strum::EnumCount` to `Chain` (#2043)
* add strum EnumIter and EnumCount to Chain

* clippy
2023-01-11 19:17:46 -08:00
DaniPopes a1d6b5e3f7
chore: clippy (#2032) 2023-01-11 19:05:39 -08:00
DaniPopes 0187bedd11
feat(abigen): use prettyplease (#2027) 2023-01-09 07:17:22 +02:00
dependabot[bot] c439566625
chore(deps): bump base64 from 0.20.0 to 0.21.0 (#2030)
Bumps [base64](https://github.com/marshallpierce/rust-base64) from 0.20.0 to 0.21.0.
- [Release notes](https://github.com/marshallpierce/rust-base64/releases)
- [Changelog](https://github.com/marshallpierce/rust-base64/blob/master/RELEASE-NOTES.md)
- [Commits](https://github.com/marshallpierce/rust-base64/compare/v0.20.0...v0.21.0)

---
updated-dependencies:
- dependency-name: base64
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-09 07:16:11 +02:00
dependabot[bot] a7f48bc6ee
chore(deps): bump glob from 0.3.0 to 0.3.1 (#2031)
Bumps [glob](https://github.com/rust-lang/glob) from 0.3.0 to 0.3.1.
- [Release notes](https://github.com/rust-lang/glob/releases)
- [Commits](https://github.com/rust-lang/glob/compare/0.3.0...0.3.1)

---
updated-dependencies:
- dependency-name: glob
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-09 07:15:48 +02:00
Peter Davies 801a638a89
etherscan: fix deserializing contract creation NormalTransaction objects (#2029)
* etherscan: fix deserializing contract creation NormalTransaction objects

* Improve tests
2023-01-09 07:12:33 +02:00
DaniPopes bab3e97d3b
fix: signer test (#2028) 2023-01-08 18:58:04 +02:00
m0ham3dx b5eddf1985
mx - CI - mdbook addons - admonition(callouts) and mermaid (code driven diagrams) with example implementation (#2025)
* P1 (#1)

* CI trigger test with changes

* CI trigger test with changes - type fix

* Post Trigger Rendering Test

* remove actions triggers on P1 branch used during testing

* mx - P1 Prep PR - with configured md-admonition and md-mermaid   (#2)

* CI trigger test with changes

* CI trigger test with changes - type fix

* Post Trigger Rendering Test

* remove actions triggers on P1 branch used during testing

* Add example callouts (admonitions) and mermaid diagram in intro.md

* Update book/getting-started/intro.md

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2023-01-08 04:29:16 +02:00
Matthias Seitz 01d3e4310f
feat: support parsing bytecode from evm object (#2024) 2023-01-07 16:22:07 +02:00
DaniPopes 2aa7bc3b99
chore(core): alias&export error as ParseChainError (#2022)
* chore(core): alias&export error as ParseChainError

`pub use TryFromPrimitiveError as ParseChainError`
for backwards compatibility

* fix: comment

* fully alias
2023-01-07 11:14:25 +02:00
Roman Krasiuk 7ddfd84e20
disable native-tls on rusoto (#2021) 2023-01-06 13:08:26 +02:00
Chris Cordle c684220144
feat: Add arbitrum nova api and chain id 42170 (#2020)
* Add arbitrum nova api and chain id

* chore: fmt

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2023-01-06 11:32:54 +02:00
DaniPopes 96f4723c13
fix(abigen): tests (#2015)
* fix: methods tests

* fix: remaining paths in tests
2023-01-06 11:30:34 +02:00
Andrea Simeoni 5917e842d7
ci: fix nonce manager test (#2014)
* Use Anvil instead of Goerli to test the nonce manager

* restore comment

* fix: explicitly assign `inner.max_priority_fee_per_gas`

Co-authored-by: Andrea Simeoni <>
2023-01-06 11:29:46 +02:00
Andrea Simeoni 7e6c3ba983
docs: mock-provider (#2011)
* MockProvider example + mdbook reference

* review: use eyre::Result

Co-authored-by: Andrea Simeoni <>
2023-01-05 17:55:23 +02:00
Gyuho Lee 3ed83d5dd3
nonce_manager: remove current nonce load when initialized (#2013)
If nonce was just initialized, no need for store and load.
Just return the stored value without load.

Signed-off-by: Gyuho Lee <gyuho.lee@avalabs.org>

Signed-off-by: Gyuho Lee <gyuho.lee@avalabs.org>
2023-01-05 11:47:05 +02:00
WillQ 4a8a6ad259
abigen adopt hardhat generated bytecode (#2012)
* abigen adopt hardhat generated bytecode

* update changelog
2023-01-05 11:46:32 +02:00
Dan Cline c0e607da1e
feat(providers): support personal account apis (#2009)
* feat(providers): add personal key mgmt rpcs

 * add personal_importRawKey and personal_unlockAccount

* expose geth personal api

* do not prefix with 0x

* serialize privkey as string

* add allow-insecure-unlock option to Geth
2023-01-04 23:35:44 +02:00
Dan Cline 9147ee8e63
feat(core): add ability to take geth stderr (#2010)
* makes the geth logs accessible by using take() on the GethInstance
   stderr
2023-01-04 23:31:48 +02:00
Dan Cline 5f2476510b
feat(providers): add mining related apis (#2008)
* feat(providers): add miner_start endpoint

* add other mining related apis

 * add eth_mining
 * add miner_stop

* expose Geth miner rpc api
2023-01-04 23:30:03 +02:00
Georgios Konstantopoulos 578b1c4d2d docs: add rw/quorum provider 2023-01-04 14:11:04 +02:00
DaniPopes 24b9ae2404
fix(contract): doctests (#2007) 2023-01-04 13:29:10 +02:00
Georgios Konstantopoulos 71fbf8c6b6
ci: build/deploy book 2023-01-04 13:26:25 +02:00
Georgios Konstantopoulos 9957e0dec9
Delete book.yml 2023-01-04 13:25:27 +02:00
Andrea Simeoni da0363918b
ci: mdbook (#2003)
* Applied same book structure as Reth

* ci: [WIP] added book workflow

* fix warning mdbook version different from template plugin version

* ci: added deploy step

* Http provider docs

* IPC provider docs

* RetryClient docs

* WebSocket provider docs

Co-authored-by: Andrea Simeoni <>
2023-01-04 12:36:31 +02:00
DaniPopes 4fd742f8ce
feat: windows ipc provider (named pipe) (#1976)
* fmt: imports

* fix: ipc tests

* fmt

* chore: move ws macros

* chore: gate ipc to unix family

* chore: make tokio optional

* feat: initial named_pipe

* feat: windows ipc

* chore: update Provider

* chore: clippy

* chore: use Path instead of OsStr

* chore: clippy

* fix: docs

* lf

* lf

* test: better subscription tests

* docs

* fix: ipc doctest

* chore: make winapi optional

* fix: optional tokio
2023-01-03 16:15:51 +02:00
Gyuho Lee 04e3021dc0
ethers-signers/aws: sighash on the inner/updated tx object (#1977)
Signed-off-by: Gyuho Lee <gyuho.lee@avalabs.org>

Signed-off-by: Gyuho Lee <gyuho.lee@avalabs.org>
2023-01-03 16:09:08 +02:00
Andrea Simeoni 04ed534b72
docs: mdbook (#1994)
* mdbook init + summary

* Getting started section

* intro typos

* intro typos and wording

* intro typos and wording

* Big numbers section

* Big numbers: added section titles + docs refinement

* Removed index prefix from file names

* Update docs/mdbook/book.toml

Co-authored-by: Andrea Simeoni <>
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2023-01-03 15:18:38 +02:00
Matthias Seitz d1df3417f7
feat(solc): improve error on case mismatch (#1998) 2023-01-03 15:14:01 +02:00
Matthias Seitz 6ac3e75c6a
fix: use full path of i256 (#2000) 2023-01-03 15:12:47 +02:00
DaniPopes 97582cc346
feat(core, contract): improve `determine_ethers_crates` (#1988)
* refactor: determine_ethers_crates

* feat: improve crate resolution

* export new types and functions

* export

* fix: file name check

* fix: invert condition and check CARGO_MANIFEST_DIR

* use abigen macro to generate multicall

* chore: rm debug

* rm unnecessary .replace

* chore: clippy

* chore: clippy

* Revert "chore: clippy"

This reverts commit bd220f308d.

* Revert "chore: clippy"

This reverts commit 5550f4e856.

* add tests

* better tests, docs

* add another test

* fix docs

* refactor: add an environment struct for determining ethers crates

* fix: use fmt::Debug to escape paths

* docs: rename and rm old docs

* feat: use global path for crates

* fix: docs

* chore: move rand impl to tests mod
2023-01-03 15:11:57 +02:00
DaniPopes fd4da49121
tests: use sepolia (#1989)
* tests: use sepolia

* update ci

* update sleep duration

* deprecate ropsten

* use goerli

* fmt

* keys
2022-12-31 12:47:53 +02:00
Dan Cline 228f9607fe
feat(core): expose all genesis related structs (#1975) 2022-12-30 14:48:47 +02:00
DaniPopes d272318483
chore: update all rust editions to 2021 (#1979) 2022-12-30 14:48:29 +02:00
0xKitsune f94e6f549f
added `from_bytes` for `Wallet` type (#1983)
* added `from_bytes` for `Wallet` type

* added key_from_bytes test for Wallet::from_bytes

* updated changelog
2022-12-30 14:45:19 +02:00
Akram Hussein 69e0ff7301
fix: doc typo regarding Multicall::call_array (#1985) 2022-12-30 14:44:03 +02:00
DaniPopes 4274a27531
fix(examples): deprecated gas oracle (#1986) 2022-12-30 14:43:49 +02:00
dependabot[bot] a42cc9f63f
chore(deps): bump once_cell from 1.16.0 to 1.17.0 (#1987)
Bumps [once_cell](https://github.com/matklad/once_cell) from 1.16.0 to 1.17.0.
- [Release notes](https://github.com/matklad/once_cell/releases)
- [Changelog](https://github.com/matklad/once_cell/blob/master/CHANGELOG.md)
- [Commits](https://github.com/matklad/once_cell/compare/v1.16.0...v1.17.0)

---
updated-dependencies:
- dependency-name: once_cell
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-30 14:43:05 +02:00
DaniPopes c5ff733702
chore: clippy (#1990)
* chore: clippy

* chore: clippy
2022-12-30 14:19:41 +02:00
Georgios Konstantopoulos 48dbbbd829 chore: clippy 2022-12-30 14:18:58 +02:00
Matthias Seitz fcef7c70ad
fix: gwei wei wrong u256 constant (#1992) 2022-12-30 12:46:52 +02:00
Andrea Simeoni 10310ce3ad
refactor: examples (#1940)
* ToC

* Big numbers section

* Middleware examples: builder

* Middleware examples: gas_escalator

* Middleware examples: gas_oracle

* Middleware examples: signer

* Middleware examples: missing stubs

* review: applied DaniPopes suggestions to big numbers

* typo

* Middleware examples: nonce_manager

* cargo +nightly fmt

* update roadmap

* Middleware examples: policy

* Middleware examples: added docs

* Contracts examples: created folder; included abigen example

* Contracts examples: refactor abigen docs. Fixed cargo example reference

* Contracts examples: contract_events; minor docs changes

* Moved each example under its own crate.
Cargo builds locally
TODO: Fix broken examples CI

* Big numbers examples: used regular operators for math

* Single examples run correctly (missing overall CI execution)
Example crates dependencies
Removed duplicates

* review: Applied gakonst note to remove commented items in workspace manifest

* review: Applied gakonst note to restore visibility on contract constructor

* ci:
- Run/Build  examples in a single step to avoid duplicated scripts
- Removed ci.yaml step "Build all examples"

* cargo +nightly fmt

* ci: fix WASM step error

* Removed deprecated EthGasStation example

* WASM example uses local copy of `contract_abi.json`. In this way we keep the WASM example auto-consistent, at the cost of a small duplication

* Cargo.lock aligned to master branch

* Removed useless comments in examples

* review: Applied gakonst note to add panic!() on the policy middleware example

* review: Applied gakonst suggestion to add a custom middleware example

* typos in docs

* Update examples/big-numbers/examples/bn_math_operations.rs

review: Accepted commit suggested by DaniPopes

Co-authored-by: DaniPopes <57450786+DaniPopes@users.noreply.github.com>

* review: Applied DaniPopes suggestion on assert_eq!

* Update examples/big-numbers/README.md

review: Accepted DaniPopes suggestion on big-numbers docs

Co-authored-by: DaniPopes <57450786+DaniPopes@users.noreply.github.com>

* review: All imports now reference the "ethers" crate

* ci: added features ["ws", "rustls"] where needed
cargo +nigthly fmt

* Examples with special features (e.g. ipc, trezor etc.) are built alongside them. This is expressed as a "default" requirement in their respective Cargo.toml

* cargo +nightly fmt

* Examples: Gas oracle API keys from env
Added missing features in middleware Cargo.toml

* typo: use expect() instead of unwrap()

* Updated ToC
Moved 2 examples under more relevant folders

* Gas oracle examples raise panic on middleware errors

* review: removed useless [[example]] in Cargo.toml

* review: removed #[allow(unused_must_use)] from gas_escalator example

* review: Removed prefixes from file names

* review: removed useless [[example]] in Cargo.toml

* docs: Updated description to run examples in the workspace README.md

Co-authored-by: Andrea Simeoni <>
Co-authored-by: DaniPopes <57450786+DaniPopes@users.noreply.github.com>
2022-12-29 14:53:11 +02:00
James Prestwich e26ede21f1
fix: don't override user-set 1559 attributes (#1980)
* fix: don't override user-set 1559 attributes

* fix: enforce cap on prioirity fee per gas
2022-12-29 03:05:08 +02:00
dependabot[bot] 799f752e55
chore(deps): bump serde_path_to_error from 0.1.8 to 0.1.9 (#1969)
Bumps [serde_path_to_error](https://github.com/dtolnay/path-to-error) from 0.1.8 to 0.1.9.
- [Release notes](https://github.com/dtolnay/path-to-error/releases)
- [Commits](https://github.com/dtolnay/path-to-error/compare/0.1.8...0.1.9)

---
updated-dependencies:
- dependency-name: serde_path_to_error
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-25 13:53:42 +02:00
dependabot[bot] ea6d058bbc
chore(deps): bump proc-macro2 from 1.0.47 to 1.0.49 (#1951)
Bumps [proc-macro2](https://github.com/dtolnay/proc-macro2) from 1.0.47 to 1.0.49.
- [Release notes](https://github.com/dtolnay/proc-macro2/releases)
- [Commits](https://github.com/dtolnay/proc-macro2/compare/1.0.47...1.0.49)

---
updated-dependencies:
- dependency-name: proc-macro2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-12-25 13:53:32 +02:00
Vid Kersic b27c7b0773
feat: debug_traceCall (#1949)
* feat: debug_traceCall

* chore: update changelog

* fix: rebase to master and change tracer from string to enum
2022-12-25 13:33:05 +02:00
Andrey Kuznetsov 2e32528292
chore: gitignore .pre-commit-config.yaml (#1973) 2022-12-25 12:20:42 +02:00
Matthias Seitz 8a5b3cc6c9
fix: reexport SourceLocation (#1971) 2022-12-23 14:58:02 +02:00