stop draining it asshole; we can fix this properly by making
the goerli PK a Github Secret but this will make the experience
for 3rd party contributors worse because they won't be able to run
integration tests
* 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 <>
* Added support for I256 in format_units. Added two complement support for I256.
* Add I256 support into parse_units
Co-authored-by: Dave Belvedere <dave@protonmail.com>
* ci: install anvil
* test: use anvil instead of ganache
* ci: fix anvil ver
* ci: re-enable example tests
* test: remove unnecessary assertions
* test: enable anvil launch test
* docs: typo
* test: fix anvil chain id
* ci: install ganache
Ganache is needed for the Ganache tests
* chore: remove legacy feature from some examples
* ci: correctly build examples
* test: use correct account balance for anvil
* chore: remove sub_id == 1 check
this was only possible in ganache because it gives serial
sub ids, but in every other reasonable client the ids are generated
randomly, so we cannot test for its value
* test: ensure txs are different
There is a bug in Ganache's mempool which accepts duplicate transactions (here with the same nonce), whereas here we pre-set all the nonces so that they end up having a different transaction hash.
* test: ignore ganache tests
* fix: terzor api changes
* ci(examples): install Anvil, remove geth/ganache
* test(provider): Anvil instead of Geth
some tests start to fail now
* fix: revert usage of Anvil in ipc tests
Anvil does not support IPC yet
* fix: update examples script
* ci: use anvil for wasm example
* replace last ganache usage
Co-authored-by: Oliver Nordbjerg <hi@notbjerg.me>
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
* feat(middleware): fetch chainid from middleware
Require SignerMiddleware to fetch the inner middleware's to set for the
signer. SignerMiddleware now requires an instantiated middleware with
an accessible get_chainid method.
* ci: update ganache
newer ganache version is needed to specify the ganache provider chain id
in tests
* set SignerMiddleware constructor return to result
* create new method for pulling chainid
* add consistent chainid CHANGELOG entry
* remove awaits
* switch test_derive_eip712 to use consistent signer
* remove gas estimation equality assert in deploy_and_call_contract -
updated version of ganache no longer returns the same value for gas
estimation and gas_used
* revert with_signer to non-async non-result
* cargo fmt
* expand SignerMiddleware::new comment
* remove doc indent
* feat(etherscan, middleware): implement gas-related endpoints and use them in gas oracle
* cleanup deps
* better comment
* revertme: add debug print
* Revert "revertme: add debug print"
This reverts commit 63993642c4.
* make etherscan tests serial
* run each etherscan test at least 200ms
* 200ms -> 250ms
* Revert "200ms -> 250ms"
This reverts commit 29c7f6ed9a.
* add separate etherscan key for celo tests
* 200ms -> 250ms
* add Chain::Sepolia to match
* feat(ethers-solc): deserialize bytecode as bytes
* feat(ethers-solc): add method to fetch compact contract
* feat(ethers-solc): use Abi type instead of Vec<serde_json::Value>
* test(contract): use new Solc bindings
* test(middleware): use new Solc bindings
* chore: remove solc from ethers-core
* chore: remove concurrent setup code from ethers-core
* feat(ethers-solc): add ArtifactOutput::Nothing as a no-op artifact logger
* feat: add ethers-solc to top level crate
* examples: use new solc building pattern
* chore(solc): re-use opt str impl for error code decoding
* fix abigen example
* chore: fix doctests
* chore: remove setup feature
* fix: decode string to bytes correctly
* chore: clippy lints
* test: fix duplicate tx flakes by rotating through a list of wallets
* fix: make typed_txs test more robust
* fix: ensure wallets are loaded in a thread-safe way
without fetch_add, it's possible that 2 loads happen for the same id before the `store` mutex is acquired'
* chore(core): remove ethers dep
* chore(providers): remove ethers dep
tests using higher-rank crates are temporarily disabled
* chore(middleware): remove ethers dep and move tests over from providers
* chore(signers): remove ethers dep
* fix(contracts): correctly determine ethers sub-crates & remove ethers
* fix: re-enable tests for all members
* fix: make contract compile without middleware dep
move over the test using middleware to ethers-middleware
* chore: cargo fmt
* chore(contract): add missing import
* WIP
* WIP
* fix(middleware): use rustls as dev dep
* chore: cargo fmt
* fix: use different key for nonce manager to avoid nonce conflicts
* chore: fix celo test ported over to middlewares
the test had the same private key with an existing middleware test,
causing potential nonce reuses
it now also uses a different storage contract, so we had to change
it to use u256 instead of string
* fix(middleware): enable contracts/celo feature
* chore: ignore non-eip2718 txs to rinkeby
* feat: partial wasm32 support
* make compile for wasm32
* feat: att async-trait attr
* make compatible with wasm
* add type alias for archs
* rustfmt
* add wasm ci
* make compile with wasm-pack test
* make compile with wasm-pack test
* make compile with wasm-pack test
* make compile with wasm-pack test
* ci: disable wasmpack
* feat: use wasm timer delay
* feat: add wasm provider
* rustfmt
* misc refactor
* add wasm example
* make example a directory
* untrack error log
* move profile to root
* fix unused imports
* ci: enable wasm-pack test
* style: unify websocket implementations
* fix: typos
* fix: make policy compatible with wasm target
* chore: do not include ethers-wasm example as top level workspace member
* chore: modify wasm32 dependencies
* chore: make note about getrandom
Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
* fix: re-enable ethgasstation tests and add new fields on response
* fix: re-enable etherchain tests and add new fields on response
* feat: add new etherscan response fields
* feat: use gasnow v3
* chore: derive more traits for response types
* feat(contract): use eip-1559 txs by default
This may break any tests which use Ganache, since it only supports legacy transactions.
We should replace Ganache with hardhat where possible
* fix(providers): always try setting default_sender
* chore: make all test transactions legacy
* feat(multicall): allow submitting legacy txs
* chore: default to legacy txs via feature flag
This is useful for chains like Celo that do not support the Typed Envelope
* fix: use legacy txs in ds proxy deployment / tests
* chore: fix review comments
* feat(providers): add eth_feeHistory api
* add access list
* feat: fill transactions with access list / default sender info
* feat: add helpers for operating on the txs enum
* feat: send_transaction takes TypedTransaction now
* fix(contract): temp wrap all contract txs as Legacy txs
* feat(middleware): use TypedTransaction in Transformer
* feat(signers): use TypedTransaction in Wallet/Ledger
* feat(core): add helpers for setting typed tx fields
* feat(signer): use typed transactions
* fix(middleware): adjust nonce/gas/escalators for TypedTxs
The GPO and the Escalators will throw an error if they are provided an EIP1559 transaction
* fix(providers): ensure the correct account's nonce is filled
* fix: add .into() to txs until we make the fn call more generic
* Revert "fix: add .into() to txs until we make the fn call more generic"
This reverts commit 04dc34b26d0e3f418ed3fc69ea35ad538b83dd50.
* feat: generalize send_transaction interface
* fix: only set the nonce manually in the Signer middleware
* fix(transformer): fill the transaction after transformation
* chore: fix compilation errors & lints
* fix(signer): set the correct account's nonce
* feat: make trace_call / call take TypedTransaction
* fix: set sender to transaction in signer
* chore: ethgasstation broke
* chore: cargo fmt / lints
* Fix(signer): pass the chain id
* fix: final tx encoding fixes
1. Normalize v values for eip1559/2730
2. Make access lists mandatory for 1559
3. do not double-rlp on rlp_signed
* fix: set access list only if available
* test: check 1559 / 2930 txs
* fix: do not prepend a 0 for Legacy txs & test
* chore: code review comments
* chore: fix aws signer signature
* feat: add eip2930 tx type
* feat: add typed transaction enum
* chore: rlp_opt take reference to option
* feat: add eip-1559 tx type
* feat: add eip-1559 to the typed tx enum
* fix: references to rlp_opt / add access list setter
* chore: ignore etherchain and ethgasstation
Their APIs had a breaking change
* fix(1559/2930): serialize properly
1. The AccessList struct should have used RlpEncodableWrapper, otherwise we get extra bytes
2. The 1559/2930 types do not use eip-155-style replay protection
* feat: add helpers for operating on the txs enum
* chore: cargo fmt / lints
* chore: update deps (#352)
* chore(deps): bump elliptic-curve from 0.10.4 to 0.10.5
Bumps [elliptic-curve](https://github.com/RustCrypto/traits) from 0.10.4 to 0.10.5.
- [Release notes](https://github.com/RustCrypto/traits/releases)
- [Commits](https://github.com/RustCrypto/traits/compare/elliptic-curve-v0.10.4...elliptic-curve-v0.10.5)
---
updated-dependencies:
- dependency-name: elliptic-curve
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
* chore: bump deps
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* fix(core): make chain id mandatory
* fix(signers): make chain id mandatory
* test: make chain id mandatory
* test: add missing chain id
* fix: add missing chain id
* chore(wallet): set chain_id by default to 1
* ci: run CI on master
* fix(yubi): add missing chain id
* chore: skip ganache test with celo features
* ci: run only on push to master
* fix: add missing chain id
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Add support for EIP-234
* Add support for EIP-1898
* Remove redundant field names
* Remove useless conversion
* Change `unwrap_or` to `unwrap_or_else`
* feat(providers): tokio 1.0
BREAKING: This removes async-std as a compatibility option
* feat: tokio 1.0 in rest of crates
* fix: patch Cargo.toml until deps are released
* fix(contract): load ws deps
* feat: bytes 1.0 (#121)
* feat(core): move to bytes::Bytes
* feat: adjust rest of crates to Bytes
* chore: bump deps
CI fails due to:
https://github.com/snapview/tokio-tungstenite/pull/142#discussion_r550445144
* chore: use latest tokio-tungstenite
* ci: split tests into jobs (#129)
* Switch to `hex` (#128)
* fix(core): replace rustc_hex with hex
* fix(providers): replace rustc_hex with hex
* chore: replace rustc-hex with hex
* chore: cargo fmt
* fix(ledger): copy address from string correctly
* chore: fix flaky tests
Fixes#105
* feat(providers): return a PendingTransaction from send_tx calls
* feat(providers): expose the internal provider to all middlewares
* fix(middleware): use the returned PendingTx instead of using a hash
* fix(contract): use the pending tx returned value
Note1: To support that, we need to clone the tx when sending in order to make lifetimes work out
Note2: Multicall does not support that feature
* fix(ethers): adjust examples
* chore: fix provider test
* chore: fix celo test
BREAKING CHANGE