Commit Graph

221 Commits

Author SHA1 Message Date
Simon Bihel cd8a9b5a97
Add ENS avatar and TXT records resolution (#889)
* Add ENS avatar resolution

As well as arbitrary fields.

* Use try_join

* Improve reqwest's error passing

* Split avatar resolution in ERC token parsing and resolution

* no_run examples

* Rename token to NFT

* A bit more documentation

* Nightly cargo fmt

* Use different ERC-721 test

* Update CHANGELOG

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2022-02-16 16:25:41 +02:00
dependabot[bot] 903edab7bf
chore(deps): bump tokio-util from 0.6.9 to 0.7.0 (#895)
Bumps [tokio-util](https://github.com/tokio-rs/tokio) from 0.6.9 to 0.7.0.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/commits)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-11 13:12:20 +02:00
wolflo 14551a90c1
fix(providers): PendingTransaction::log() missing deref (#886) 2022-02-09 08:48:03 +02:00
wolflo b657e47e6b
feat(providers): Log methods for PendingTransaction (#884)
* feat(providers): Log method for PendingTransaction

* feat(poviders): Add PendingTransaction inspect() method

* Apply suggestions from code review

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2022-02-09 00:55:35 +02:00
MistApproach 5005a3621a
Hide Infura API key from docs (#863) 2022-02-04 16:58:53 +02:00
dependabot[bot] 8d0d5a2d9a
chore(deps): bump tracing from 0.1.29 to 0.1.30 (#862)
Bumps [tracing](https://github.com/tokio-rs/tracing) from 0.1.29 to 0.1.30.
- [Release notes](https://github.com/tokio-rs/tracing/releases)
- [Commits](https://github.com/tokio-rs/tracing/compare/tracing-0.1.29...tracing-0.1.30)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-04 10:09:02 +02:00
wolflo 885aa9c967
fix(providers): doc test for dev_rpc (#857) 2022-02-02 19:20:01 +02:00
rakita 24e7c471e4
add eth_syncing RPC (#848)
* add eth_syncing RPC

* Changelo updated

* small comments

* Intermediate SyncingStatus
2022-02-01 12:58:45 +02:00
Dan Cline 01544ec4b7
Implement RLP decoding for transactions (#805)
* Implement RLP decoding for transactions

* set chain_id in fill_transaction
2022-01-30 21:21:16 +02:00
Tarrence van As 9e6ed0522a
fix(ethers-providers): make http crate required (#836) 2022-01-28 08:51:13 +02:00
th4s a97526d6fe
Add authorization for http and websocket (#829)
* Added  basic and bearer authentication for http and websocket transport

* Improved api for websocket `connect_with_auth`

* Bugfix in doc

* Moved use statement into non-wasm imports

* Adapted changelog

* Fixed doc test

* Added constructors for Authorization

* Improved code quality and implemented feedback

* Made bas64 crate for basic auth encoding non-optional

* Added `Display` for `Authorization` instead of `into_auth_string`
2022-01-27 12:04:53 +02:00
Georgios Konstantopoulos 78dfd7591d chore: remove broken celo test
the error was on the alfajores testnet:
'missing trie node c04caafad74d59d8ca27dbbbc49e257d4f4d490bbe40534691dbb101618e2e87'

unclear why this is happening, but tx validation for celo is working otherwise
2022-01-24 19:40:46 +02:00
Erwan f9f77e829b
fix(ws): propagate deserialization errors upstream + infura quickfix (#827)
* fix(ws): propagate error when deserialization fails

* fix(ws): tolerate case-insensitive match on the jsonrpc field

Infura streams notifications with jsonrpc all capitalized. This fails to
deserialize on our end because serde expect a precise match ressembling
the Notification jsonrpc field.

Fixes #684.

* chore(fmt): use nightly rustfmt

* chore: fmt

* chore: fix failing celo test

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2022-01-24 15:38:00 +02:00
Georgios Konstantopoulos a30a4ecd16 test(providers): use new celo txhash which has not been wiped 2022-01-16 22:18:25 +02:00
Matthias Seitz d2318d285d
chore(deps): bump solang (#796)
* chore(deps): bump solang

* fix: breaking test
2022-01-15 17:53:46 +02:00
Eugene cbfbd6052c
Implement trace_callMany (#792)
* Implement trace_callMany

* cargo fix and ignore flaky test for now

* Update ethers-providers/src/provider.rs

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2022-01-15 12:41:43 +02:00
Matthias Seitz d2b59d7097
chore: silence unused ws macro (#788) 2022-01-13 02:59:02 +02:00
dependabot[bot] c95c12e0d1
chore(deps): bump tempfile from 3.2.0 to 3.3.0 (#780)
Bumps [tempfile](https://github.com/Stebalien/tempfile) from 3.2.0 to 3.3.0.
- [Release notes](https://github.com/Stebalien/tempfile/releases)
- [Changelog](https://github.com/Stebalien/tempfile/blob/master/NEWS)
- [Commits](https://github.com/Stebalien/tempfile/compare/v3.2.0...v3.3.0)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-11 12:03:09 +02:00
dependabot[bot] e3c86231de
chore(deps): bump reqwest from 0.11.8 to 0.11.9 (#785)
Bumps [reqwest](https://github.com/seanmonstar/reqwest) from 0.11.8 to 0.11.9.
- [Release notes](https://github.com/seanmonstar/reqwest/releases)
- [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.8...v0.11.9)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-01-11 11:18:03 +02:00
georgewhewell bb0cd7acdd
mark TransactionFut as Send (#723)
* mark TransactionFut as Send

* no send when wasm32
2021-12-23 16:29:51 +02:00
Georgios Konstantopoulos d7c29cc615
fix: configure rustls & openssl via feature flag (#703)
* chore(etherscan): allow specifying openssl or rustls

* chore(contract): allow specifying openssl or rustls

* chore(solc): allow specifying openssl or rustls

* chore: expose new rustls/openssl features at top level crate

* chore: bump tokio-tungstenite / remove dup rustls version

* chore: bump svm-rs

* fix: feature gate sha2-asm

* ci: remove --all-features from windows tests

* chore: do not enable sha2-asm by default

* fix: do not pull in svm-rs in wasm builds

* chore: use upstream svm again
2021-12-19 16:56:54 +02:00
Matthias Seitz e24117a1e1
chore(clippy): make clippy happy (#705) 2021-12-19 06:28:38 +02:00
James Prestwich 060dd6033d
refactor: move fill_transaction impl to provider rather than default (#697)
* refactor: move fill_transaction impl to provider rather than default

* chore: changelog and docstring for fill_transaction
2021-12-16 01:09:09 +02:00
Alex Xiong 6cbdc89187
fix: avoid futures-util yanked err (#693) 2021-12-15 03:32:36 +01:00
James Prestwich 3338cdead1
feature: set nonce in fill transaction (#687)
* feature: set nonce in fill transaction

* chore: update changelog

* refactor: remove nonce_setting in fill_transaction

* refactor: set nonce in send_escalating
2021-12-14 00:50:13 +02:00
James Prestwich 47e9e7d3c7
refactor: move FeeHistory to core types (#688) 2021-12-14 00:49:49 +02:00
Matthias Seitz f4c89c6cb1
ci: test on windows targets (#682)
* ci: test on windows targets

* make ipc optional

* fix: only activate ipc on unix families

* add cfg

* only check default members

* no parallel limits

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2021-12-13 23:25:10 +02:00
Nicholas Rodrigues Lordello 79f2e1d5ef
Serialize block count as quantity 2 (#669)
* Serialize eth_feeHistory block count as QUANTITY

* update changelog

* Make sure to first convert to U256 :face_palm:

* Fix issue with move of `block_count` value.

* fix merge issue

* Revert changelog
2021-12-10 09:16:20 -07:00
Nicholas Rodrigues Lordello 7bd42be0d8
Serialize `eth_feeHistory` block count as `QUANTITY` (#668)
* Serialize eth_feeHistory block count as QUANTITY

* update changelog
2021-12-10 08:49:27 -07:00
Daniil Naumetc fffb965f2f
fix: nonce too low for different providers (#655) 2021-12-07 01:15:51 +02:00
guanqun 8d07610e4a
fix(provider::ws): ignore the websocket response when the request has been cancelled. (#641) 2021-12-03 20:14:13 +02:00
Daniil Naumetc 9fc75ef245
Fix handling of `nonce too low` error (#643)
* fix: nonce too low from error as debug

* chore: cargo fmt

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2021-12-03 20:08:53 +02:00
wolflo bccc7b9b5e
Add dev-rpc middleware (#640)
* Add dev-rpc middleware

* Dont run dev-rpc tests with celo

* providers: clean up match statement

* providers: fix clippy lint

* doc(providers) doctest and changelog for DevRpcMiddleware
2021-12-03 19:11:09 +02:00
dependabot[bot] 9214bacc03
chore(deps): bump reqwest from 0.11.6 to 0.11.7 (#636)
Bumps [reqwest](https://github.com/seanmonstar/reqwest) from 0.11.6 to 0.11.7.
- [Release notes](https://github.com/seanmonstar/reqwest/releases)
- [Changelog](https://github.com/seanmonstar/reqwest/blob/master/CHANGELOG.md)
- [Commits](https://github.com/seanmonstar/reqwest/compare/v0.11.6...v0.11.7)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-12-01 04:28:56 -06:00
Georgios Konstantopoulos bb3a2fd27c
release: 0.6.0 (#611)
* release(core): 0.6.0

* release(providers): 0.6.0

* release(contract-abigen): 0.6.0

* release(contract-derive): 0.6.0

* release(derive-eip712): 0.2.0

* release(ethers-solc): 0.1.0

* release(contract): 0.6.0

* release(etherscan): 0.2.0

* release(signers): 0.6.0

* release(middleware): 0.6.0

* chore: update dev deps

* refactor(core): move docs to readme

* refactor(contract): move docs to readme

* refactor(providers): move docs to readme

* chore: bump ethers cargo toml

* refactor(signers): move docs to readme

* refactor(middleware): move docs to readme

* fix(ethers): adjust re-exports to allow searching internal packages

* docs: fix broken links

we cannot use relative crate imports because the readmes
are also imported by the parent crate

* alias readmes to be accessible to ethers crate
2021-11-23 21:23:12 +02:00
dependabot[bot] fb42f043a2
chore(deps): bump futures-util from 0.3.17 to 0.3.18 (#609)
Bumps [futures-util](https://github.com/rust-lang/futures-rs) from 0.3.17 to 0.3.18.
- [Release notes](https://github.com/rust-lang/futures-rs/releases)
- [Changelog](https://github.com/rust-lang/futures-rs/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rust-lang/futures-rs/compare/0.3.17...0.3.18)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-11-23 13:23:53 +02:00
univerz ec00325aa2
revert: unify get_block_receipts for eth/parity RPCs (#601) 2021-11-21 18:14:35 +02:00
Georgios Konstantopoulos a28476dccc
fix: lowercase node client type (#600) 2021-11-21 18:12:40 +02:00
Rohit Narurkar ab60a5e738
add net_version call (#595)
* add net_version call

* add change log
2021-11-18 20:56:31 +02:00
Eduard S 8493451917
Fix/providers (#590)
* ethers-providers: Fix http Provider request id data race

* ethers-providers: Remove Serialize from JsonRpcClient Response

* Update changelog
2021-11-18 11:59:29 +02:00
James Prestwich 0f22afeb49
Prestwich/escalator fixes (#581)
* refactor: handle nonce-too-low cases indicating previous conf.

* feature: add sign_transaction to Middleware trait and fix escalation signing
2021-11-14 14:26:02 +02:00
James Prestwich 203b2e8ea3
Prestwich/super pending (#566)
* feature: pending_escalator

* feature: send_escalating in Middleware

* bug: don't drop unready futures in escalator.poll

* chore: docs and must_use

* chores: lints, clippies, wasm fixes, dedup pinboxfut

* chore: more lints

* refactor: use Delay in polling interval to ensure re-waking

* refactor: simplify Sleeping state transition as last will never be None again

* bug: properly set last when broadcasts resolve

* feature: debug implementation for EscalatingPending

* refactor: with_ setters and escalations argument

* refactor: use FuturesUnOrdered instead of a vec of futures

* chore: update CHANGELOG with recent PR info

* chore: update all comments on pending escalator

* chore: run rustfmt
2021-11-12 03:23:46 +02:00
James Prestwich e9d40120a7
chore: re-export http client error in providers transports (#570)
* chore: re-export http client error in providers transports

* chore: re-export we client error in providers transports
2021-11-10 18:53:07 +02:00
dependabot[bot] 7ad4d28ae3
chore(deps): bump auto_impl from 0.4.1 to 0.5.0 (#564)
Bumps [auto_impl](https://github.com/auto-impl-rs/auto_impl) from 0.4.1 to 0.5.0.
- [Release notes](https://github.com/auto-impl-rs/auto_impl/releases)
- [Commits](https://github.com/auto-impl-rs/auto_impl/compare/v0.4.1...v0.5.0)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-11-08 09:43:55 +00:00
Matthias Seitz c08f8ba876
fix: failing test and check --all-targets in ci (#560)
* fix: update failing example

* ci: check all targets
2021-11-05 19:58:03 +02:00
Matthias Seitz 6bf45a0b5d
fix: send error back (#556) 2021-11-05 03:21:23 +02:00
dependabot[bot] 2c8a425898
chore(deps): bump tokio-util from 0.6.8 to 0.6.9 (#549)
Bumps [tokio-util](https://github.com/tokio-rs/tokio) from 0.6.8 to 0.6.9.
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-util-0.6.8...tokio-util-0.6.9)

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

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-11-01 13:00:48 +02:00
Alexey Shekhirin dc3ac427f4
feat(providers): unify get_block_receipts for eth/parity RPCs (#541)
* feat(providers): unify get_block_receipts for eth/parity RPCs

* add besu

* impl tryfrom for nodeclient

* better node client storage

* fix lint

* tryfrom<&str> -> fromstr

* fix: remove nested Option

Co-authored-by: Georgios Konstantopoulos <me@gakonst.com>
2021-10-30 16:50:46 +03:00
Matthias Seitz dcf20022c6
chore: add rustfmt.toml (#537)
* chore: add rustfmt.toml

* rustfmt

* chore: Update readme with fmt info

* ci: update ci

* chore: rustfmt

* rustfmt

* rustfmt

* ci: install libudev

* chore(clippy): make clippy happy

* chore(clippy): make clippy happy

* revert ci

* ci: install libudev
2021-10-29 14:29:35 +02:00
Georgios Konstantopoulos ef9b3988ce
fix: ensure gas estimation includes the access list in 1559/2930 txs (#523)
* fix: ensure gas estimation includes the access list in 1559/2930 txs

* feat: add gas_price to typed tx

* feat: add access list to typed tx

* chore(providers): cleanup fill_transaction

* chore: fmt

* chore: enable 712 on ethers-contract at top level crate

* fix: do not error if eth_createAccessList is not available

* feat: only use access list if needed
2021-10-20 23:18:58 +03:00