Compare commits
94 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7bc9c6b953 | ||
|
|
0855d6e9f5 | ||
|
|
948f77050d | ||
|
|
9e57e71dc0 | ||
|
|
dab6ede226 | ||
|
|
1f6c0ab281 | ||
|
|
056d7c8bfc | ||
|
|
47c41143cb | ||
|
|
ef1b28e958 | ||
|
|
e192903050 | ||
|
|
9d9b14b952 | ||
|
|
bc400c7b87 | ||
|
|
120dcd024a | ||
|
|
04f7a9f3b7 | ||
|
|
e70f3fe26f | ||
|
|
ef529dc5e6 | ||
|
|
9f0967f21f | ||
|
|
774c310389 | ||
|
|
21fae9f0ba | ||
|
|
ce85a7e976 | ||
|
|
7c4a9083c2 | ||
|
|
7becc93ed0 | ||
|
|
540a670f94 | ||
|
|
ab628c285e | ||
|
|
9bff2cb3d9 | ||
|
|
96de58122a | ||
|
|
b1c7f5c21a | ||
|
|
905e98aa39 | ||
|
|
dca0d14d38 | ||
|
|
5998fea53d | ||
|
|
dfaa8ee7e6 | ||
|
|
fa4a29028d | ||
|
|
f46aa75ef1 | ||
|
|
d160bac273 | ||
|
|
be518c32ec | ||
|
|
26cdbab59b | ||
|
|
b8cda5dffd | ||
|
|
f67a9a8569 | ||
|
|
bae215eb7f | ||
|
|
54e6e57fce | ||
|
|
38e825cee6 | ||
|
|
16007d4d1e | ||
|
|
cf47ec5fd5 | ||
|
|
ae23bb76a9 | ||
|
|
33a029e457 | ||
|
|
c2a6a012bf | ||
|
|
6807a76b8d | ||
|
|
5f26fd55c9 | ||
|
|
c562150d26 | ||
|
|
4e8f004e9e | ||
|
|
9aac785395 | ||
|
|
1651389571 | ||
|
|
2d98b4fca1 | ||
|
|
f26074b92b | ||
|
|
eb91d708ac | ||
|
|
83891f9258 | ||
|
|
7b134bd5c9 | ||
|
|
e175448380 | ||
|
|
1d419b5829 | ||
|
|
95b2c72b12 | ||
|
|
7b0d02d30e | ||
|
|
0c72e0f1fd | ||
|
|
315ecfd19e | ||
|
|
c61f3bc2a0 | ||
|
|
1be096130c | ||
|
|
9eed04a6d5 | ||
|
|
82d6dcbdde | ||
|
|
4935f93015 | ||
|
|
3df0e06c64 | ||
|
|
18d8d1f34d | ||
|
|
7b80ba20fe | ||
|
|
f635af2684 | ||
|
|
813fcef4ad | ||
|
|
32c9a09762 | ||
|
|
03545aa78b | ||
|
|
03152ea014 | ||
|
|
0578a88efa | ||
|
|
3f5bc6ddc1 | ||
|
|
ab13887cda | ||
|
|
28f383300c | ||
|
|
4ba63acc10 | ||
|
|
3d6a7ec020 | ||
|
|
2f57c6a4ab | ||
|
|
d3d2953e8d | ||
|
|
0403314023 | ||
|
|
eb432aa1f4 | ||
|
|
617714d196 | ||
|
|
42784b8d38 | ||
|
|
50d712d6af | ||
|
|
c7e9715758 | ||
|
|
0844de4eb4 | ||
|
|
caa1983665 | ||
|
|
b8391b0e61 | ||
|
|
1e1c93effa |
74
.github/ISSUE_TEMPLATE/beta-issue.yml
vendored
Normal file
74
.github/ISSUE_TEMPLATE/beta-issue.yml
vendored
Normal file
@@ -0,0 +1,74 @@
|
||||
name: Beta (v6) Bug
|
||||
description: Open an issue for a bug in the v6 beta
|
||||
title: "Title Here"
|
||||
labels: ["v6-beta"]
|
||||
assignees:
|
||||
- ricmoo
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
This form is **only** for issues in the **v6 beta**, which you
|
||||
can access using either the `v6-beta` tag in the repository or
|
||||
install using `ethers@beta` with `npm`.
|
||||
|
||||
The v6 branch will be very lively, undergoing a lot of changes,
|
||||
including backwards compatible changes between beta versions.
|
||||
|
||||
Before opening an issue, please make sure you have
|
||||
**fully updated to the latest version** by removing the
|
||||
`node_modules/` and `package-lock.json` and then running a
|
||||
fresh `npm install`. Otherwise you may end up with incompatible
|
||||
versions which may conflict with each other.
|
||||
|
||||
Thanks for trying out the v6 beta! Cheers!
|
||||
- type: input
|
||||
id: version
|
||||
attributes:
|
||||
label: Ethers Version
|
||||
description: What version of ethers are you using? Before opening an issue, please make sure you are using the latest beta.
|
||||
placeholder: x.y.z
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: about-the-bug
|
||||
attributes:
|
||||
label: Describe the Problem
|
||||
description: Please describe what you expected to happen vs what did happen?
|
||||
placeholder: What happened?
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: code-snippet
|
||||
attributes:
|
||||
label: Code Snippet
|
||||
description: If possible, please include a **short and concise** code snippets that can reproduce this issue. Ideally code that can be pasted into the [Ethers Playground](https://playground.ethers.org).
|
||||
placeholder: e.g. provider.getBlockNumber()
|
||||
render: shell
|
||||
- type: textarea
|
||||
id: errors
|
||||
attributes:
|
||||
label: Errors
|
||||
description: If there is an error, please include the **entire error** (redacting any sensitive information).
|
||||
placeholder: "e.g. Error: invalid name (code='INVALID_ARGUMENT, ...)"
|
||||
render: shell
|
||||
- type: dropdown
|
||||
id: environment
|
||||
attributes:
|
||||
label: Environment
|
||||
description: What environment, platforms or frameworks are you using? Select all that apply.
|
||||
multiple: true
|
||||
options:
|
||||
- node.js
|
||||
- Browser (Chrome, Safari, etc)
|
||||
- React Native/Expo/JavaScriptCore
|
||||
- Hardhat
|
||||
- Geth
|
||||
- Parity
|
||||
- Ganache
|
||||
- Other (please specify)
|
||||
- type: input
|
||||
id: other-envrionment
|
||||
attributes:
|
||||
label: Environment (Other)
|
||||
placeholder: anything else?
|
||||
24
.github/ISSUE_TEMPLATE/bug-report.md
vendored
24
.github/ISSUE_TEMPLATE/bug-report.md
vendored
@@ -1,24 +0,0 @@
|
||||
---
|
||||
name: Bug Report
|
||||
about: Create a report to help us improve
|
||||
title: ''
|
||||
labels: investigate
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
Note: Not all sections may be relevant, but please be as thorough while remaining concise as possible. Remove this Notice and any sections that don't feel pertinent.
|
||||
|
||||
If you are unsure if something is a bug, start a thread in the *"discussions"* tab above..
|
||||
|
||||
**Describe the bug**
|
||||
A clear and concise description of what the bug is.
|
||||
|
||||
**Reproduction steps**
|
||||
Please include code snippets, with console.log output, any contract ABI, contract address, network and the full error.
|
||||
|
||||
**Environment:**
|
||||
Please include anything that may be useful in diagnosing the issue. Node vs Browser? Geth vs Parity vs Ganache? Third Party tools, like Hardhat? Mobile vs. Desktop?
|
||||
|
||||
**Search Terms**
|
||||
Often similar issues have come up before. Include any search terms you have tried in this repository's Issues (including closed issues) and *"Discussions"*, so if there are matching issues, we can be sure to add those keywords and link this issue to it, making it easier for people to find in the future.
|
||||
81
.github/ISSUE_TEMPLATE/bug-report.yml
vendored
Normal file
81
.github/ISSUE_TEMPLATE/bug-report.yml
vendored
Normal file
@@ -0,0 +1,81 @@
|
||||
name: Bug Report
|
||||
description: Open an issue for a bug in Ethers
|
||||
title: "Bug Report Title"
|
||||
labels: ["investigate"]
|
||||
assignees:
|
||||
- ricmoo
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
**READ THIS FIRST** and follow all instructions, please. `:)`
|
||||
|
||||
Thank you for taking the time to report an issue. This form is for reporting **bugs within ethers**.
|
||||
|
||||
If you are **new to ethers** or *uncertain* whether this is a bug in ethers, a bug in another framework or a bug in your own code, please [start a discussion](https://github.com/ethers-io/ethers.js/discussions) first.
|
||||
- type: input
|
||||
id: version
|
||||
attributes:
|
||||
label: Ethers Version
|
||||
description: What version of ethers are you using? Before opening an issue, please make sure you are up to date.
|
||||
placeholder: x.y.z
|
||||
validations:
|
||||
required: true
|
||||
- type: input
|
||||
id: search-terms
|
||||
attributes:
|
||||
label: Search Terms
|
||||
description: Have you searched for answers [in the documentation](https://docs.ethers.io), through [the issues](https://github.com/ethers-io/ethers.js/issues) and [on the discusions](https://github.com/ethers-io/ethers.js/discussions)? Please include the search terms you have tried. This helps us add more keywords where needed.
|
||||
placeholder: e.g. abi, network, utf8
|
||||
- type: textarea
|
||||
id: about-the-bug
|
||||
attributes:
|
||||
label: Describe the Problem
|
||||
description: Please describe what you expected to happen vs what did happen?
|
||||
placeholder: What happened?
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: code-snippet
|
||||
attributes:
|
||||
label: Code Snippet
|
||||
description: If possible, please include a **short and concise** code snippets that can reproduce this issue. Ideally code that can be pasted into the [Ethers Playground](https://playground.ethers.org).
|
||||
placeholder: e.g. provider.getBlockNumber()
|
||||
render: shell
|
||||
- type: textarea
|
||||
id: contract-abi
|
||||
attributes:
|
||||
label: Contract ABI
|
||||
description: If this involves a contract, please include any **concise and relevant** ABI fragments.
|
||||
placeholder: e.g. [ 'function balanceOf(address owner) view returns (uint)' ]
|
||||
render: shell
|
||||
- type: textarea
|
||||
id: errors
|
||||
attributes:
|
||||
label: Errors
|
||||
description: If there is an error, please include the **entire error** (redacting any sensitive information).
|
||||
placeholder: "e.g. Error: invalid name (code='INVALID_ARGUMENT, ...)"
|
||||
render: shell
|
||||
- type: dropdown
|
||||
id: environment
|
||||
attributes:
|
||||
label: Environment
|
||||
description: What environment, platforms or frameworks are you using? Select all that apply.
|
||||
multiple: true
|
||||
options:
|
||||
- Ethereum (mainnet, ropsten, rinkeby, goerli, etc.)
|
||||
- Altcoin (Matic, BNB, etc.)
|
||||
- node.js (v12 or newer)
|
||||
- node.js (older than v12)
|
||||
- Browser (Chrome, Safari, etc)
|
||||
- React Native/Expo/JavaScriptCore
|
||||
- Hardhat
|
||||
- Geth
|
||||
- Parity
|
||||
- Ganache
|
||||
- Other (please specify)
|
||||
- type: input
|
||||
id: other-envrionment
|
||||
attributes:
|
||||
label: Environment (Other)
|
||||
placeholder: anything else?
|
||||
16
.github/ISSUE_TEMPLATE/documentation.md
vendored
16
.github/ISSUE_TEMPLATE/documentation.md
vendored
@@ -1,16 +0,0 @@
|
||||
---
|
||||
name: Documentation
|
||||
about: Documentation request or suggestion
|
||||
title: ''
|
||||
labels: documentation
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
Please include anything about the [documentation](https://docs.ethers.io) you would like to see improved.
|
||||
|
||||
- Missing information or details?
|
||||
- Wrong Information?
|
||||
- Dead or wrong links?
|
||||
- Something needs code examples?
|
||||
- General feedback or anything else?
|
||||
23
.github/ISSUE_TEMPLATE/documentation.yml
vendored
Normal file
23
.github/ISSUE_TEMPLATE/documentation.yml
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
name: Documentation
|
||||
description: Documentation update, change or suggestion
|
||||
title: "Documentation Title"
|
||||
labels: ["documentation"]
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please include anything about the [documentation](https://docs.ethers.io) you would like to see improved.
|
||||
|
||||
- Missing information or details?
|
||||
- Spelling or Grammar mistakes?
|
||||
- Wrong Information?
|
||||
- Dead or wrong links?
|
||||
- Something needs code examples?
|
||||
- General feedback or anything else?
|
||||
- type: textarea
|
||||
id: suggestion
|
||||
attributes:
|
||||
label: Suggestion
|
||||
placeholder: e.g. please add an example for ropsten
|
||||
validations:
|
||||
required: true
|
||||
22
.github/ISSUE_TEMPLATE/feature-request.md
vendored
22
.github/ISSUE_TEMPLATE/feature-request.md
vendored
@@ -1,22 +0,0 @@
|
||||
---
|
||||
name: Feature Request
|
||||
about: Suggest a new feature for ethers
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
Note: The best place to start a Feature Request is usually in the Discussions, to mull through the desired feature, current options and think through the impact on the library overall.
|
||||
|
||||
**Is your feature request related to a problem? Please describe.**
|
||||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||
|
||||
**Describe the solution you'd like**
|
||||
A clear and concise description of what you want to happen.
|
||||
|
||||
**Describe alternatives you've considered**
|
||||
A clear and concise description of any alternative solutions or features you've considered.
|
||||
|
||||
**Additional context**
|
||||
Add any other context or screenshots about the feature request here.
|
||||
26
.github/ISSUE_TEMPLATE/feature-request.yml
vendored
Normal file
26
.github/ISSUE_TEMPLATE/feature-request.yml
vendored
Normal file
@@ -0,0 +1,26 @@
|
||||
name: Feature Request
|
||||
description: Suggest a new feature or addition to Ethers
|
||||
title: "Feature Request Title"
|
||||
labels: [ "enhancement" ]
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
The best place to start a new feature request is by starting an [Idea discussion](https://github.com/ethers-io/ethers.js/discussions), to mull over the feature, discuss current options and think through the impact on the overall library.
|
||||
|
||||
Keep in mind that features increase the library size, and may require additional dependencies. Ethers strives to remain lean and the number of dependencies low, so many features may make more sense as ancillary packages.
|
||||
- type: textarea
|
||||
id: about-the-feature
|
||||
attributes:
|
||||
label: Describe the Feature
|
||||
description: Please describe the feature, the problem it is solving, your solution and alternatives you've considered.
|
||||
placeholder: e.g. I want Ethers to be more/less magical.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: code-example
|
||||
attributes:
|
||||
label: Code Example
|
||||
description: Optionally, provide an example of how the feature would be used in code.
|
||||
placeholder: e.g. provider.doMagic()
|
||||
render: shell
|
||||
16
.github/ISSUE_TEMPLATE/other.md
vendored
16
.github/ISSUE_TEMPLATE/other.md
vendored
@@ -1,16 +0,0 @@
|
||||
---
|
||||
name: Other
|
||||
about: Something else
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
Generally this issue template should be used.
|
||||
|
||||
If your issue is **not** a **Feature Request**, a **Bug Report** or problem with the **Documentation** you should probably be using the *"Discussion"* tab at the top.
|
||||
|
||||
But for truly exceptional issues, please include the details here.
|
||||
|
||||
Please also include any search terms you used when searching issues and discussions, so we can better tag those in the future.
|
||||
27
.github/ISSUE_TEMPLATE/other.yml
vendored
Normal file
27
.github/ISSUE_TEMPLATE/other.yml
vendored
Normal file
@@ -0,0 +1,27 @@
|
||||
name: Other
|
||||
description: Open a general issue
|
||||
title: Other Issue Title
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
**READ THIS FIRST**
|
||||
|
||||
This form should almost **NEVER** be used. Consider closely why your issue does not fit into one of the [other categories](https://github.com/ethers-io/ethers.js/issues/new/choose).
|
||||
|
||||
You almost certainly wish to use [the discussions](https://github.com/ethers-io/ethers.js/discussions) instead, to ask a question or seek further guidance.
|
||||
- type: textarea
|
||||
id: about
|
||||
attributes:
|
||||
label: Describe your Issue
|
||||
description: Please include as much relevant context as possible, be concise and clearly explain what you are looking for.
|
||||
placeholder: e.g. What is the answer to life, the universe and everything?
|
||||
validations:
|
||||
required: true
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: This is an exception issue
|
||||
description: This form is **only** for *exceptional issues*, which do not match any [other categoeries](https://github.com/ethers-io/ethers.js/issues/new/choose).
|
||||
options:
|
||||
- label: I understand this form is for exceptional issues and believe my issue qualifies.
|
||||
required: true
|
||||
2
.github/workflows/nodejs.yml
vendored
2
.github/workflows/nodejs.yml
vendored
@@ -15,7 +15,7 @@ jobs:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
node-version: [ 8.x, 10.x, 12.x, 13.x ]
|
||||
node-version: [ 12.x, 14.x, 16.x ]
|
||||
|
||||
steps:
|
||||
- name: Use Node.js ${{ matrix.node-version }}
|
||||
|
||||
70
CHANGELOG.md
70
CHANGELOG.md
@@ -4,6 +4,74 @@ Changelog
|
||||
This change log is managed by `admin/cmds/update-versions` but may be manually updated.
|
||||
|
||||
|
||||
ethers/v5.6.4 (2022-04-13 16:56)
|
||||
--------------------------------
|
||||
|
||||
- Support new OpenEthereum NONCE_EXPIRED string. ([#2845](https://github.com/ethers-io/ethers.js/issues/2845), [#2846](https://github.com/ethers-io/ethers.js/issues/2846); [0855d6e](https://github.com/ethers-io/ethers.js/commit/0855d6e9f593515b639c10a3f65bad712c68221c))
|
||||
|
||||
ethers/v5.6.3 (2022-04-13 00:23)
|
||||
--------------------------------
|
||||
|
||||
- Mimic Hardhard error strings in CALL_EXCEPTION for popular matchers. ([#2849](https://github.com/ethers-io/ethers.js/issues/2849), [#2862](https://github.com/ethers-io/ethers.js/issues/2862); [dab6ede](https://github.com/ethers-io/ethers.js/commit/dab6ede226e572706655e2865d4c953e37741a5c))
|
||||
- Fix pocket API key not being passed in for default provider. ([#2890](https://github.com/ethers-io/ethers.js/issues/2890); [056d7c8](https://github.com/ethers-io/ethers.js/commit/056d7c8bfc5896759c383d7cfae8ed0ec5c5eefb))
|
||||
|
||||
ethers/v5.6.2 (2022-03-25 17:56)
|
||||
--------------------------------
|
||||
|
||||
- Fixed left-padding in arrayify. ([#2833](https://github.com/ethers-io/ethers.js/issues/2833); [e192903](https://github.com/ethers-io/ethers.js/commit/e19290305080ebdfa2cb2ab2719cb53fee5a6cc7))
|
||||
- More robust JSON-RPC error handling for reverted executions. ([#2603](https://github.com/ethers-io/ethers.js/issues/2603); [9d9b14b](https://github.com/ethers-io/ethers.js/commit/9d9b14b95299b793c1a0f4cb8f42e4e0252fed1c))
|
||||
- Added IPNS support for ENS contenthash. ([e70f3fe](https://github.com/ethers-io/ethers.js/commit/e70f3fe26f3b0dfd44fdbc163e2cc6c8eb9433f8))
|
||||
- Added initial AnkrProvider ([96de581](https://github.com/ethers-io/ethers.js/commit/96de58122af57be761e431e9268958eeaa352480))
|
||||
|
||||
ethers/v5.6.1 (2022-03-16 01:25)
|
||||
--------------------------------
|
||||
|
||||
- Fix issue with CCIP Read using wrong sender. ([#2478](https://github.com/ethers-io/ethers.js/issues/2478); [5998fea](https://github.com/ethers-io/ethers.js/commit/5998fea53d5ea26358c2f10939dfdf0bc679936d), [905e98a](https://github.com/ethers-io/ethers.js/commit/905e98aa392e2a52d6b0339b21bfce5237fd8662))
|
||||
|
||||
ethers/v5.6.0 (2022-03-09 14:57)
|
||||
--------------------------------
|
||||
|
||||
- Tweaked test case to re-order transaction after event listeners added. ([fa4a290](https://github.com/ethers-io/ethers.js/commit/fa4a29028d97d598b43b2f5ff98077e8cadf56a4))
|
||||
- Ignore errors when resolving ENS resolver properties. ([d160bac](https://github.com/ethers-io/ethers.js/commit/d160bac273775f928a9441b0275dbdb6032368fa))
|
||||
- Enable CCIP Read for ENS resolvers. ([#2478](https://github.com/ethers-io/ethers.js/issues/2478); [be518c3](https://github.com/ethers-io/ethers.js/commit/be518c32ec7db9dd4769b57cdf130eb333aebb72))
|
||||
- Fix missing events on certain network conditions. ([#1798](https://github.com/ethers-io/ethers.js/issues/1798), [#1814](https://github.com/ethers-io/ethers.js/issues/1814), [#1830](https://github.com/ethers-io/ethers.js/issues/1830), [#2274](https://github.com/ethers-io/ethers.js/issues/2274), [#2652](https://github.com/ethers-io/ethers.js/issues/2652); [f67a9a8](https://github.com/ethers-io/ethers.js/commit/f67a9a8569cdfd0ef9ce5fbf09866aab6e4814d4), [f46aa75](https://github.com/ethers-io/ethers.js/commit/f46aa75ef1f3428e640cd046db3f080d264b32f3))
|
||||
- Added defaultProvider option to omit specific Providers. ([bae215e](https://github.com/ethers-io/ethers.js/commit/bae215eb7fb3efea8473a544579abac1bebb7ef0))
|
||||
- Add support for pending blocks. ([#2225](https://github.com/ethers-io/ethers.js/issues/2225); [54e6e57](https://github.com/ethers-io/ethers.js/commit/54e6e57fcece4c1718a577ecbeb1af97998e8bdc))
|
||||
- Help URLs for errors. ([#2489](https://github.com/ethers-io/ethers.js/issues/2489); [38e825c](https://github.com/ethers-io/ethers.js/commit/38e825cee624ff935ec6b70023cf288126a6bb85), [c562150](https://github.com/ethers-io/ethers.js/commit/c562150d2678710f50e5ee3ffa88d0e62d6f696f))
|
||||
- Added CCIP support to provider.call. ([#2478](https://github.com/ethers-io/ethers.js/issues/2478); [ae23bb7](https://github.com/ethers-io/ethers.js/commit/ae23bb76a937924bf57baf679e6efd8cdf59bc47))
|
||||
- Adjust default maxPriorityFeePerGas to 1.5 gwei. ([33a029e](https://github.com/ethers-io/ethers.js/commit/33a029e457320a226c68a01f4cfa2d110125a8b8))
|
||||
- Fix contracts when name resolution fails without any checks. ([#2737](https://github.com/ethers-io/ethers.js/issues/2737); [c2a6a01](https://github.com/ethers-io/ethers.js/commit/c2a6a012bf1d8fcd5805e45754cebdfe211c6933))
|
||||
- Preserve explicit chainId in JsonRpcProvider during transaction serialization. ([#2691](https://github.com/ethers-io/ethers.js/issues/2691); [6807a76](https://github.com/ethers-io/ethers.js/commit/6807a76b8ddfdd121f98b21e269de3b195a7673e))
|
||||
- Fixed eth_chainId response for Eip1193Bridge. ([#2711](https://github.com/ethers-io/ethers.js/issues/2711); [5f26fd5](https://github.com/ethers-io/ethers.js/commit/5f26fd55c9d010c00f830a4c83a480a54773858d))
|
||||
- Remove spurious console.log from Interface. ([#2714](https://github.com/ethers-io/ethers.js/issues/2714); [4e8f004](https://github.com/ethers-io/ethers.js/commit/4e8f004e9e42892840663311cafe042c0b24c61e))
|
||||
- Allow raw WebSocket to be passed into WebSocketProvider. ([#2562](https://github.com/ethers-io/ethers.js/issues/2562), [#2644](https://github.com/ethers-io/ethers.js/issues/2644); [9aac785](https://github.com/ethers-io/ethers.js/commit/9aac785395e9b47655477a3ba7baf05df3274de9))
|
||||
- Added Cloudflare Worker support. ([#1886](https://github.com/ethers-io/ethers.js/issues/1886); [2d98b4f](https://github.com/ethers-io/ethers.js/commit/2d98b4fca1eb2544fec728f7c1c7b0d450e0dbee), [1651389](https://github.com/ethers-io/ethers.js/commit/1651389571b5dd16c1c056dcd94729b48a4bdd85))
|
||||
- Add support for EIP-2098 compact signatures. ([#2246](https://github.com/ethers-io/ethers.js/issues/2246); [f26074b](https://github.com/ethers-io/ethers.js/commit/f26074b92b0fc8efd3d85c68e84cc6ff8897e4a8))
|
||||
- Add EIP-2544 Wildcard support. ([#2477](https://github.com/ethers-io/ethers.js/issues/2477), [#2582](https://github.com/ethers-io/ethers.js/issues/2582), [#2583](https://github.com/ethers-io/ethers.js/issues/2583); [83891f9](https://github.com/ethers-io/ethers.js/commit/83891f9258492f9801aa579ac50764b6491b6180))
|
||||
|
||||
ethers/v5.5.4 (2022-01-24 16:45)
|
||||
--------------------------------
|
||||
|
||||
- Support invalid but popular IPFS URI format. ([#2271](https://github.com/ethers-io/ethers.js/issues/2271), [#2527](https://github.com/ethers-io/ethers.js/issues/2527), [#2590](https://github.com/ethers-io/ethers.js/issues/2590); [03545aa](https://github.com/ethers-io/ethers.js/commit/03545aa78b0e7bd177e22432e4842b0580a11d7d))
|
||||
|
||||
ethers/v5.5.3 (2022-01-06 03:52)
|
||||
--------------------------------
|
||||
|
||||
- Fixed case-folding in schemes for ENS avatars. ([#2500](https://github.com/ethers-io/ethers.js/issues/2500); [3f5bc6d](https://github.com/ethers-io/ethers.js/commit/3f5bc6ddc1013f0a5974f2ee6f542d6c91480c13))
|
||||
- Added Kintsugi network. ([#2434](https://github.com/ethers-io/ethers.js/issues/2434); [ab13887](https://github.com/ethers-io/ethers.js/commit/ab13887cda3939703dc1f7e27d139ef6001b7dd2))
|
||||
- Fix browser random in WebWorkers. ([#2405](https://github.com/ethers-io/ethers.js/issues/2405); [4ba63ac](https://github.com/ethers-io/ethers.js/commit/4ba63acc107fdd0a6d6ef3e27349e65edb007447))
|
||||
- Add support for IPFS metadata imageUrl in getAvatar. ([#2426](https://github.com/ethers-io/ethers.js/issues/2426); [3d6a7ec](https://github.com/ethers-io/ethers.js/commit/3d6a7ec020eacd993b4b0fd3274574de3ddcc257))
|
||||
- Do not swallow ENS not supported errors. ([#2387](https://github.com/ethers-io/ethers.js/issues/2387); [2f57c6a](https://github.com/ethers-io/ethers.js/commit/2f57c6a4ab44083b2c03f5e57b2702ab7078d286))
|
||||
|
||||
ethers/v5.5.2 (2021-11-30 19:16)
|
||||
--------------------------------
|
||||
|
||||
- Fixed test case for getAvatar; url has moved ([617714d](https://github.com/ethers-io/ethers.js/commit/617714d19632c7b4789f042ef8357f858421fbae))
|
||||
- Added basic redirect support. ([42784b8](https://github.com/ethers-io/ethers.js/commit/42784b8d38a96170d19ea8adcbc42ebf7415804c))
|
||||
- Added arbitrum and optimism to networks and providers. ([#2335](https://github.com/ethers-io/ethers.js/issues/2335); [0844de4](https://github.com/ethers-io/ethers.js/commit/0844de4eb45eb4170fafb6f2a239b53b6be22f1c))
|
||||
- Added support for data URLs for avatar metadata. ([b8391b0](https://github.com/ethers-io/ethers.js/commit/b8391b0e61bf3627702668920c4fd6506f9bdc60))
|
||||
- Fixed getAvatar for unconfigured ENS names. ([1e1c93e](https://github.com/ethers-io/ethers.js/commit/1e1c93effa083765be52f3dee10400a9b3eeb003))
|
||||
|
||||
ethers/v5.5.1 (2021-10-20 03:59)
|
||||
--------------------------------
|
||||
|
||||
@@ -423,4 +491,4 @@ ethers/v5.0.0 (2020-06-12 19:58)
|
||||
--------------------------------
|
||||
|
||||
- Preserve config canary string. ([7157816](https://github.com/ethers-io/ethers.js/commit/7157816fa53f660d750811b293e3b1d5a2f70bd4))
|
||||
- Updated docs. ([9e4c7e6](https://github.com/ethers-io/ethers.js/commit/9e4c7e609d9eeb5f2a11d6a90bfa9d32ee696431))
|
||||
- Updated docs. ([9e4c7e6](https://github.com/ethers-io/ethers.js/commit/9e4c7e609d9eeb5f2a11d6a90bfa9d32ee696431))
|
||||
|
||||
41
README.md
41
README.md
@@ -26,10 +26,12 @@ A complete Ethereum wallet implementation and utilities in JavaScript (and TypeS
|
||||
Keep Updated
|
||||
------------
|
||||
|
||||
For the latest news and advisories, please follow the [@ethersproject](https://twitter.com/ethersproject)
|
||||
on Twitter (low-traffic, non-marketing, important information only) as well as watch this GitHub project.
|
||||
For the latest news and advisories, please follow the
|
||||
[@ethersproject](https://twitter.com/ethersproject) on Twitter (low-traffic,
|
||||
non-marketing, important information only) as well as watch this GitHub project.
|
||||
|
||||
For the latest changes, see the [CHANGELOG](https://github.com/ethers-io/ethers.js/blob/master/CHANGELOG.md).
|
||||
For the latest changes, see the
|
||||
[CHANGELOG](https://github.com/ethers-io/ethers.js/blob/master/CHANGELOG.md).
|
||||
|
||||
|
||||
Installing
|
||||
@@ -44,7 +46,7 @@ Installing
|
||||
**browser (UMD)**
|
||||
|
||||
```
|
||||
<script src="https://cdn.ethers.io/lib/ethers-5.1.umd.min.js" type="text/javascript">
|
||||
<script src="https://cdn.ethers.io/lib/ethers-5.6.umd.min.js" type="text/javascript">
|
||||
</script>
|
||||
```
|
||||
|
||||
@@ -52,7 +54,7 @@ Installing
|
||||
|
||||
```
|
||||
<script type="module">
|
||||
import { ethers } from "https://cdn.ethers.io/lib/ethers-5.1.esm.min.js";
|
||||
import { ethers } from "https://cdn.ethers.io/lib/ethers-5.6.esm.min.js";
|
||||
</script>
|
||||
```
|
||||
|
||||
@@ -66,7 +68,34 @@ Browse the [documentation](https://docs.ethers.io/v5/) online:
|
||||
- [Full API Documentation](https://docs.ethers.io/v5/api/)
|
||||
- [Various Ethereum Articles](https://blog.ricmoo.com/)
|
||||
|
||||
Or browse the entire documentation as a [single page](https://docs.ethers.io/v5/single-page/) to make searching easier.
|
||||
|
||||
Providers
|
||||
---------
|
||||
|
||||
Ethers works closely with an ever-growing list of third-party providers
|
||||
to ensure getting started is quick and easy, by providing default keys
|
||||
to each service.
|
||||
|
||||
These built-in keys mean you can use `ethers.getDefaultProvider()` and
|
||||
start developing right away.
|
||||
|
||||
However, the API keys provided to ethers are also shared and are
|
||||
intentionally throttled to encourage developers to eventually get
|
||||
their own keys, which unlock many other features, such as faster
|
||||
responses, more capacity, analytics and other features like archival
|
||||
data.
|
||||
|
||||
When you are ready to sign up and start using for your own keys, please
|
||||
check out the [Provider API Keys](https://docs.ethers.io/v5/api-keys/) in
|
||||
the documentation.
|
||||
|
||||
A special thanks to these services for providing community resources:
|
||||
|
||||
- [Ankr](https://www.ankr.com/)
|
||||
- [Etherscan](https://etherscan.io/)
|
||||
- [INFURA](https://infura.io/)
|
||||
- [Alchemy](https://dashboard.alchemyapi.io/signup?referral=55a35117-028e-4b7c-9e47-e275ad0acc6d)
|
||||
- [Pocket](https://pokt.network/pocket-gateway-ethereum-mainnet/)
|
||||
|
||||
|
||||
Ancillary Packages
|
||||
|
||||
@@ -25,7 +25,7 @@ free tier, which (depending on the service) includes many advantages:
|
||||
- useful **metric tracking** for performance tuning and to analyze your customer behaviour
|
||||
- more **advanced APIs**, such as archive data or advanced log queries
|
||||
|
||||
_subsection: Etherscan @<api-keys--etherscan>
|
||||
_subsection: Etherscan @NOTE<(see the [[EtherscanProvider]])> @<api-keys--etherscan>
|
||||
|
||||
Etherscan is an Ethereum block explorer, which is possibly the most useful
|
||||
developer tool for building and debugging Ethereum applications.
|
||||
@@ -40,13 +40,17 @@ operations required to interact with the Ethereum Blockchain.
|
||||
- higher rate limit (since you are not using the [shared rate limit](link-etherscan-ratelimit))
|
||||
- customer usage metrics
|
||||
|
||||
_subsection: INFURA @<api-keys--infura>
|
||||
_definition: **Networks:**
|
||||
``homestead``, ``ropsten``, ``rinkeby``, ``goerli`` and ``kovan``.
|
||||
|
||||
|
||||
_subsection: INFURA @NOTE<(see the [[InfuraProvider]])> @<api-keys--infura>
|
||||
|
||||
The INFURA service has been around for quite some time and is very robust
|
||||
and reliable and highly recommended.
|
||||
|
||||
They offer a standard JSON-RPC interface and a WebSocket interface, which makes
|
||||
interaction with standard tools versatile, simple and straight forward.
|
||||
interaction with standard tools versatile, simple and straightforward.
|
||||
|
||||
[Sign up for a free Project ID on INFURA](link-infura-signup)
|
||||
|
||||
@@ -56,7 +60,13 @@ interaction with standard tools versatile, simple and straight forward.
|
||||
- customer usage metrics
|
||||
- access to archive data (requires paid upgrade)
|
||||
|
||||
_subsection: Alchemy @<api-keys--alchemy>
|
||||
_definition: **Networks:**
|
||||
``homestead``, ``ropsten``, ``rinkeby``, ``goerli``, ``kovan``, ``matic``,
|
||||
``maticmum``, ``optimism``, ``optimism-kovan``, ``arbitrum`` and
|
||||
``arbitrum-rinkeby``.
|
||||
|
||||
|
||||
_subsection: Alchemy @NOTE<(see the [[AlchemyProvider]])> @<api-keys--alchemy>
|
||||
|
||||
The Alchemy service has been around a few years and is also very robust
|
||||
and reliable.
|
||||
@@ -74,9 +84,17 @@ with debugging.
|
||||
- access to advanced token balance and metadata APIs
|
||||
- access to advanced debugging trace and revert reason APIs
|
||||
|
||||
_subsection: Pocket Gateway@<api-keys--pocket-gateway>
|
||||
_definition: **Networks:**
|
||||
``homestead``, ``ropsten``, ``rinkeby``, ``goerli``, ``kovan``, ``matic``,
|
||||
``maticmum``, ``optimism``, ``optimism-kovan``, ``arbitrum`` and
|
||||
``arbitrum-rinkeby``.
|
||||
|
||||
|
||||
_subsection: Pocket Gateway @NOTE<(see the [[PocketProvider]])> @<api-keys--pocket-gateway>
|
||||
|
||||
They offer a standard JSON-RPC interface using either a load-balanced
|
||||
network or non-load-balanced fleet.
|
||||
|
||||
[Sign up for a free API key on Pocket](link-pocket-signup)
|
||||
|
||||
**Benefits:**
|
||||
@@ -86,6 +104,26 @@ _subsection: Pocket Gateway@<api-keys--pocket-gateway>
|
||||
- Stake as opposed to paying a monthly fee
|
||||
- Highly redundant global set of nodes incentivized by cryptoeconomic incentives
|
||||
|
||||
_definition: **Networks:**
|
||||
``homestead``
|
||||
|
||||
|
||||
_subsection: Ankr @NOTE<(see the [[AnkrProvider]])> @<api-keys--ankr>
|
||||
|
||||
They offer a standard JSON-RPC interface and have fairly high capacity without
|
||||
the need for an API key early on in the development cycle.
|
||||
|
||||
[See their free tier features on Ankr](link-ankr-public)
|
||||
|
||||
**Benefits:**
|
||||
|
||||
- higher rate limit
|
||||
- customer usage metrics
|
||||
- access to archive data (requires paid upgrade)
|
||||
|
||||
_definition: **Networks:**
|
||||
``homestead``, ``matic`` and ``arbitrum``
|
||||
|
||||
|
||||
_subsection: Creating a Default Provider @<api-keys--getDefaultProvider>
|
||||
|
||||
@@ -100,6 +138,8 @@ using the default API key for that service.
|
||||
It is **highly recommended** that you provide an API for each service, to
|
||||
maximize your applications performance.
|
||||
|
||||
If the API key ``"-"`` is used, the corresponding Provider will be omitted.
|
||||
|
||||
_code: Passing API Keys into getDefaultProvider @lang<script>
|
||||
|
||||
// Use the mainnet
|
||||
@@ -122,5 +162,6 @@ const provider = ethers.getDefaultProvider(network, {
|
||||
// pocket: {
|
||||
// applicationId: ,
|
||||
// applicationSecretKey:
|
||||
// }
|
||||
// },
|
||||
ankr: YOUR_ANKR_API_KEY
|
||||
});
|
||||
|
||||
@@ -23,7 +23,7 @@ Consumes the output of the Solidity compiler, extracting the ABI
|
||||
and bytecode from it, allowing for the various formats the solc
|
||||
compiler has emitted over its life.
|
||||
|
||||
_property: contractFactory.connect(signer) => [[Contract]] @<ContractFactory-connect>
|
||||
_property: contractFactory.connect(signer) => [[ContractFactory]] @<ContractFactory-connect>
|
||||
|
||||
Returns a **new instance** of the ContractFactory with the same //interface//
|
||||
and //bytecode//, but with a different //signer//.
|
||||
|
||||
@@ -98,11 +98,12 @@ at run-time during the **Contract** constructor.
|
||||
|
||||
_heading: Read-Only Methods (constant) @<Contract--readonly>
|
||||
|
||||
A constant method is read-only and evaluates a small amount of EVM
|
||||
code against the current blockchain state and can be computed by
|
||||
asking a single node, which can return a result. It is therefore
|
||||
free and does not require any ether, but **cannot make changes** to
|
||||
the blockchain state..
|
||||
A constant method (denoted by ``pure`` or ``view`` in Solidity)
|
||||
is read-only and evaluates a small amount of EVM code against the
|
||||
current blockchain state and can be computed by asking a single
|
||||
node, which can return a result. It is therefore free and does
|
||||
not require any ether, but **cannot make changes** to the
|
||||
blockchain state..
|
||||
|
||||
_property: contract.METHOD_NAME(...args [, overrides ]) => Promise<any> @<Contract-functionsCall>
|
||||
The type of the result depends on the ABI. If the method returns a single
|
||||
@@ -111,7 +112,7 @@ be returned with each parameter available positionally and if the parameter
|
||||
is named, it will also be available by its name.
|
||||
|
||||
For values that have a simple meaning in JavaScript, the types are fairly
|
||||
straight forward; strings and booleans are returned as JavaScript strings
|
||||
straightforward; strings and booleans are returned as JavaScript strings
|
||||
and booleans.
|
||||
|
||||
For numbers, if the **type** is in the JavaScript safe range (i.e. less
|
||||
|
||||
@@ -11,7 +11,7 @@ To mitigate these issues, it is recommended you use a
|
||||
[Default Provider](providers-getDefaultProvider).
|
||||
|
||||
|
||||
_subsection: EtherscanProvider @<EtherscanProvider> @inherit<[[Provider]]> @src<providers:class.EtherscanProvider>
|
||||
_subsection: EtherscanProvider @<EtherscanProvider> @inherit<[[BaseProvider]]> @src<providers:class.EtherscanProvider>
|
||||
|
||||
The **EtherscanProvider** is backed by a combination of the various
|
||||
[Etherscan APIs](link-etherscan-api).
|
||||
@@ -39,11 +39,11 @@ It is highly recommended for production, you register with
|
||||
|
||||
_definition: **Supported Networks**
|
||||
|
||||
- Homestead (Mainnet)
|
||||
- Ropsten (proof-of-work testnet)
|
||||
- Rinkeby (proof-of-authority testnet)
|
||||
- Görli (clique testnet)
|
||||
- Kovan (proof-of-authority testnet)
|
||||
- ``homestead`` - Homestead (Mainnet)
|
||||
- ``ropsten`` - Ropsten (proof-of-work testnet)
|
||||
- ``rinkeby`` - Rinkeby (proof-of-authority testnet)
|
||||
- ``goerli`` - Görli (clique testnet)
|
||||
- ``kovan`` - Kovan (proof-of-authority testnet)
|
||||
|
||||
_code: Etherscan Examples @lang<javascript>
|
||||
|
||||
@@ -106,11 +106,17 @@ It is highly recommended for production, you register with
|
||||
|
||||
_definition: **Supported Networks**
|
||||
|
||||
- Homestead (Mainnet)
|
||||
- Ropsten (proof-of-work testnet)
|
||||
- Rinkeby (proof-of-authority testnet)
|
||||
- Görli (clique testnet)
|
||||
- Kovan (proof-of-authority testnet)
|
||||
- ``homestead`` - Homestead (Mainnet)
|
||||
- ``ropsten`` - Ropsten (proof-of-work testnet)
|
||||
- ``rinkeby`` - Rinkeby (proof-of-authority testnet)
|
||||
- ``goerli`` - Görli (clique testnet)
|
||||
- ``kovan`` - Kovan (proof-of-authority testnet)
|
||||
- ``matic`` - Polygon
|
||||
- ``maticmum`` - Polygon Mumbai Testnet
|
||||
- ``optimism`` - Optimism (L2; optimistic roll-up)
|
||||
- ``optimism-kovan`` - Optimism Testnet (L2; optimistic roll-up testnet)
|
||||
- ``arbitrum`` - Arbitrum (L2; optimistic roll-up)
|
||||
- ``arbitrum-rinkeby`` - Arbitrum Testnet (L2; optimistic roll-up testnet)
|
||||
|
||||
_code: INFURA Examples @lang<javascript>
|
||||
|
||||
@@ -161,11 +167,17 @@ It is highly recommended for production, you register with
|
||||
|
||||
_definition: **Supported Networks**
|
||||
|
||||
- Homestead (Mainnet)
|
||||
- Ropsten (proof-of-work testnet)
|
||||
- Rinkeby (proof-of-authority testnet)
|
||||
- Görli (clique testnet)
|
||||
- Kovan (proof-of-authority testnet)
|
||||
- ``homestead`` - Homestead (Mainnet)
|
||||
- ``ropsten`` - Ropsten (proof-of-work testnet)
|
||||
- ``rinkeby`` - Rinkeby (proof-of-authority testnet)
|
||||
- ``goerli`` - Görli (clique testnet)
|
||||
- ``kovan`` - Kovan (proof-of-authority testnet)
|
||||
- ``matic`` - Polygon
|
||||
- ``maticmum`` - Polygon Mumbai Testnet
|
||||
- ``optimism`` - Optimism (L2; optimistic roll-up)
|
||||
- ``optimism-kovan`` - Optimism Testnet (L2; optimistic roll-up testnet)
|
||||
- ``arbitrum`` - Arbitrum (L2; optimistic roll-up)
|
||||
- ``arbitrum-rinkeby`` - Arbitrum Testnet (L2; optimistic roll-up testnet)
|
||||
|
||||
_code: Alchemy Examples @lang<javascript>
|
||||
|
||||
@@ -197,7 +209,7 @@ Create a new **CloudflareProvider** connected to mainnet (i.e. "homestead").
|
||||
|
||||
_definition: **Supported Networks**
|
||||
|
||||
- Homestead (Mainnet)
|
||||
- ``homestead`` - Homestead (Mainnet)
|
||||
|
||||
_code: Cloudflare Examples @lang<javascript>
|
||||
|
||||
@@ -205,3 +217,98 @@ _code: Cloudflare Examples @lang<javascript>
|
||||
|
||||
// Connect to mainnet (homestead)
|
||||
provider = new CloudflareProvider();
|
||||
|
||||
|
||||
_subsection: PocketProvider @<PocketProvider> @inherit<[[UrlJsonRpcProvider]]> @src<providers:class.PocketProvider>
|
||||
|
||||
The **PocketProvider** is backed by [Pocket](link-pocket).
|
||||
|
||||
_property: new ethers.providers.PocketProvider([ network = "homestead", [ apiKey ] ])
|
||||
Create a new **PocketProvider** connected to //network// with
|
||||
the optional //apiKey//.
|
||||
|
||||
The //network// may be specified as a **string** for a common
|
||||
network name, a **number** for a common chain ID or a
|
||||
[Network Object](providers-Network).
|
||||
|
||||
_note: Note: Default API keys
|
||||
If no //apiKey// is provided, a shared API key will be used,
|
||||
which may result in reduced performance and throttled requests.
|
||||
|
||||
It is highly recommended for production, you register with
|
||||
[Pocket](link-pocket) for your own API key.
|
||||
|
||||
_definition: **Supported Networks**
|
||||
|
||||
- ``homestead`` - Homestead (Mainnet)
|
||||
- ``ropsten`` - Ropsten (proof-of-work testnet)
|
||||
- ``rinkeby`` - Rinkeby (proof-of-authority testnet)
|
||||
- ``goerli`` - Görli (clique testnet)
|
||||
|
||||
_code: Pocket Examples @lang<javascript>
|
||||
|
||||
//_hide: const PocketProvider = ethers.providers.PocketProvider;
|
||||
//_hide: const applicationId = "...";
|
||||
//_hide: const applicationSecretKey = "...";
|
||||
//_hide: const loadBalancer = true;
|
||||
|
||||
// Connect to mainnet (homestead)
|
||||
provider = new PocketProvider();
|
||||
|
||||
// Connect to the ropsten testnet
|
||||
// (see EtherscanProvider above for other network examples)
|
||||
provider = new PocketProvider("ropsten");
|
||||
|
||||
// Connect to mainnet with an Application ID (these are equivalent)
|
||||
provider = new PocketProvider(null, applicationId);
|
||||
provider = new PocketProvider("homestead", applicationId);
|
||||
|
||||
// Connect to mainnet with an application ID, application secret
|
||||
// and specify whether to use the load balances
|
||||
provider = new PocketProvider("homestead", {
|
||||
applicationId: applicationId,
|
||||
applicationSecretKey: applicationSecretKey,
|
||||
loadBalancer: loadBalancer // true or false
|
||||
});
|
||||
|
||||
|
||||
_subsection: AnkrProvider @<AnkrProvider> @inherit<[[UrlJsonRpcProvider]]> @src<providers:class.AnkrProvider>
|
||||
|
||||
The **AnkrProvider** is backed by [Ankr](link-ankr).
|
||||
|
||||
_property: new ethers.providers.AnkrProvider([ network = "homestead", [ apiKey ] ])
|
||||
Create a new **AnkrProvider** connected to //network// with
|
||||
the optional //apiKey//.
|
||||
|
||||
The //network// may be specified as a **string** for a common
|
||||
network name, a **number** for a common chain ID or a
|
||||
[Network Object](providers-Network).
|
||||
|
||||
_note: Note: Default API keys
|
||||
If no //apiKey// is provided, a shared API key will be used,
|
||||
which may result in reduced performance and throttled requests.
|
||||
|
||||
It is highly recommended for production, you register with
|
||||
[Ankr](link-ankr) for your own API key.
|
||||
|
||||
_definition: **Supported Networks**
|
||||
|
||||
- ``homestead`` - Homestead (Mainnet)
|
||||
- ``matic`` - Polygon
|
||||
- ``arbitrum`` - Arbitrum (L2; optimistic roll-up)
|
||||
|
||||
_code: Ankr Examples @lang<javascript>
|
||||
|
||||
//_hide: const AnkrProvider = ethers.providers.AnkrProvider;
|
||||
//_hide: const apiKey = "...";
|
||||
|
||||
// Connect to mainnet (homestead)
|
||||
provider = new AnkrProvider();
|
||||
|
||||
// Connect to polygont
|
||||
// (see EtherscanProvider above for other network examples)
|
||||
provider = new AnkrProvider("matic");
|
||||
|
||||
// Connect to mainnet with an API Key (these are equivalent)
|
||||
provider = new AnkrProvider(null, apiKey);
|
||||
provider = new AnkrProvider("homestead", apiKey);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
_section: JsonRpcProvider @<JsonRpcProvider> @INHERIT<[[Provider]]> @SRC<providers:class.JsonRpcProvider>
|
||||
_section: JsonRpcProvider @<JsonRpcProvider> @INHERIT<[[BaseProvider]]> @SRC<providers:class.JsonRpcProvider>
|
||||
|
||||
The [JSON-RPC API](link-jsonrpc) is a popular method for interacting
|
||||
with Ethereum and is available in all major Ethereum node implementations
|
||||
@@ -19,6 +19,9 @@ command-line flags, configuration or settings in their UI to enable
|
||||
JSON-RPC, unlock accounts or expose specific APIs. Please consult
|
||||
their documentation.
|
||||
|
||||
_property: jsonRpcProvider.connection => [[ConnectionInfo]]
|
||||
The fully formed [[ConnectionInfo]] the Provider is connected to.
|
||||
|
||||
_property: jsonRpcProvider.getSigner([ addressOrIndex ]) => [[JsonRpcSigner]] @<JsonRpcProvider-getSigner> @SRC<providers/json-rpc-provider>
|
||||
Returns a [[JsonRpcSigner]] which is managed by this Ethereum node, at
|
||||
//addressOrIndex//. If no //addressOrIndex// is provided, the first
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
_section: Other Providers
|
||||
|
||||
_subsection: FallbackProvider @<FallbackProvider> @INHERIT<[[Provider]]> @SRC<providers/fallback-provider:class.FallbackProvider>
|
||||
_subsection: FallbackProvider @<FallbackProvider> @INHERIT<[[BaseProvider]]> @SRC<providers/fallback-provider:class.FallbackProvider>
|
||||
|
||||
The **FallbackProvider** is the most advanced [[Provider]] available in
|
||||
ethers.
|
||||
@@ -68,6 +68,18 @@ _property: ipcProvider.path => string
|
||||
The path this [[Provider]] is connected to.
|
||||
|
||||
|
||||
_subsection: JsonRpcBatchProvider @<JsonRpcBatchProvider> @INHERIT<[[JsonRpcProvider]]> @SRC<providers:class.JsonRpcBatchProvider>
|
||||
|
||||
The **JsonRpcBatchProvider** operated identically to any other Provider,
|
||||
except the calls are implicly batched during an event-loop and sent using
|
||||
the JSON-RPC batch protocol to the backend.
|
||||
|
||||
This results in fewer connections and fewer requests, which may result
|
||||
in lower costs or faster responses, depending on your use case.
|
||||
|
||||
Keep in mind some backends may not support batched requests.
|
||||
|
||||
|
||||
_subsection: UrlJsonRpcProvider @<UrlJsonRpcProvider> @INHERIT<[[JsonRpcProvider]]> @SRC<providers:class.UrlJsonRpcProvider>
|
||||
|
||||
This class is intended to be sub-classed and not used directly. It
|
||||
|
||||
@@ -96,6 +96,10 @@ reading and debugging much simpler.
|
||||
The provider offers some basic operations to help resolve and
|
||||
work with ENS names.
|
||||
|
||||
_property: provider.getAvatar(name) => Promise<string>
|
||||
Returns the URL for the avatar associated to the ENS name, or null
|
||||
if no avatar was configured.
|
||||
|
||||
_property: provider.getResolver(name) => Promise<[[EnsResolver]]>
|
||||
Returns an EnsResolver instance which can be used to further inquire
|
||||
about specific entries for an ENS name.
|
||||
@@ -163,6 +167,18 @@ await resolver.getAddress();
|
||||
await resolver.getAddress(0);
|
||||
//_log:
|
||||
|
||||
_property: resolver.getAvatar() => Promise<AvatarInfo>
|
||||
Returns an object the provides the URL of the avatar and the
|
||||
linkage representing each stage in the avatar resolution.
|
||||
|
||||
If there is no avatar found (or the owner of any NFT does not
|
||||
match the name owner), null is returned.
|
||||
|
||||
The AvatarInfo has the properties:
|
||||
|
||||
- ``info.linkage`` - An array of info on each step resolving the avatar
|
||||
- ``info.url`` - The URL of the avatar
|
||||
|
||||
_property: resolver.getContentHash() => Promise<string>
|
||||
Returns a Promise which resolves to any stored [[link-eip-1577]] content hash.
|
||||
|
||||
@@ -534,3 +550,17 @@ _subsection: Inspection Methods @<Provider--inspection-methods>
|
||||
_property: Provider.isProvider(object) => boolean @<Provider-isProvider> @SRC<abstract-provider>
|
||||
Returns true if and only if //object// is a Provider.
|
||||
|
||||
|
||||
_subsection: BaseProvider @<BaseProvider> @INHERIT<[[Provider]]> @SRC<providers:class.BaseProvider>
|
||||
|
||||
Most Providers available in ethers are sub-classes of BaseProvider, which
|
||||
simplifies sub-classes, as it handles much of the event operations, such as
|
||||
polling and formatting.
|
||||
|
||||
_property: provider.polling => boolean
|
||||
Indicates if the Provider is currently polling. If there are no events to
|
||||
poll for or polling has been explicitly disabled, this will be false.
|
||||
|
||||
_property: provider.pollingInterval => number
|
||||
The frequency at which the provider polls.
|
||||
|
||||
|
||||
@@ -210,7 +210,7 @@ _property: transactionRequest.gasLimit => [[BigNumber]] | Promise<[[BigNumber]]>
|
||||
The maximum amount of gas this transaction is permitted to use.
|
||||
|
||||
If left unspecified, ethers will use ``estimateGas`` to determine the value
|
||||
to use. For transactions with unpredicatable gas estiamtes, this may be required
|
||||
to use. For transactions with unpredicatable gas estimates, this may be required
|
||||
to specify explicitly.
|
||||
|
||||
_property: transactionRequest.gasPrice => [[BigNumber]] | Promise<[[BigNumber]]>
|
||||
@@ -221,7 +221,7 @@ if ``maxFeePerGas`` or ``maxPriorityFeePerGas`` is given.
|
||||
|
||||
_property: transactionRequest.maxFeePerGas => [[BigNumber]] | Promise<[[BigNumber]]>
|
||||
The maximum price (in wei) per unit of gas this transaction will pay for the
|
||||
[[link-eip-1559]] base fee.
|
||||
combined [[link-eip-1559]] block's base fee and this transaction's priority fee.
|
||||
|
||||
Most developers should leave this unspecified and use the default value that
|
||||
ethers determines from the network.
|
||||
@@ -230,9 +230,10 @@ This may not be specified for transactions with ``type`` set to ``0`` or if ``ga
|
||||
is specified..
|
||||
|
||||
_property: transactionRequest.maxPriorityFeePerGas => [[BigNumber]] | Promise<[[BigNumber]]>
|
||||
The price (in wei) per unit of gas this transaction will pay for the
|
||||
[[link-eip-1559]] priority fee. This is **included in** the ``maxFeePerGass``,
|
||||
so this will **not affect** the total maximum cost set with ``maxFeePerGas``.
|
||||
The price (in wei) per unit of gas this transaction will allow in addition to
|
||||
the [[link-eip-1559]] block's base fee to bribe miners into giving this transaction
|
||||
priority. This is **included in** the ``maxFeePerGas``, so this will **not affect**
|
||||
the total maximum cost set with ``maxFeePerGas``.
|
||||
|
||||
Most developers should leave this unspecified and use the default value that
|
||||
ethers determines from the network.
|
||||
@@ -363,6 +364,16 @@ must be considered.
|
||||
_property: receipt.gasUsed => [[BigNumber]]
|
||||
The amount of gas actually used by this transaction.
|
||||
|
||||
_property: receipt.effectiveGasPrice => [[BigNumber]]
|
||||
The effective gas price the transaction was charged at.
|
||||
|
||||
Prior to EIP-1559 or on chains that do not support it, this value will
|
||||
simply be equal to the transaction ``gasPrice``.
|
||||
|
||||
On EIP-1559 chains, this is equal to the block ``baseFee`` for the block
|
||||
that the transaction was included in, plus the transaction
|
||||
``maxPriorityFeePerGas`` clamped to the transaction ``maxFeePerGas``.
|
||||
|
||||
_property: receipt.logsBloom => string<[[DataHexString]]>
|
||||
A [bloom-filter](link-wiki-bloomfilter), which
|
||||
includes all the addresses and topics included in any log in this
|
||||
|
||||
@@ -228,7 +228,7 @@ does not have a secure entropy source, an error is thrown.
|
||||
Wallets created using this method will have a mnemonic.
|
||||
|
||||
_property: ethers.Wallet.fromEncryptedJson(json, password [ , progress ]) => Promise<[[Wallet]]> @<Wallet-fromEncryptedJson> @SRC<wallet>
|
||||
Create an instance from an encrypted JSON wallet.
|
||||
Create an instance by decrypting an encrypted JSON wallet.
|
||||
|
||||
If //progress// is provided it will be called during decryption
|
||||
with a value between 0 and 1 indicating the progress towards
|
||||
|
||||
@@ -29,13 +29,13 @@ all the properties the ABI requires:
|
||||
- payability (for constructors and methods)
|
||||
- whether inputs are indexed (for events)
|
||||
|
||||
This allows for a simple format which is both machine-readalbe (since
|
||||
This allows for a simple format which is both machine-readable (since
|
||||
the parser is a machine) and human-readable (at least **developer-readable**),
|
||||
as well as simple for humans to type and inline into code, which improves
|
||||
code readability. The Human-Readable ABI is also considerably smaller, which
|
||||
helps reduce code size.
|
||||
|
||||
A Huamn-Readable ABI is simple an array of strings, where each string is
|
||||
A Human-Readable ABI is simple an array of strings, where each string is
|
||||
the Solidity signature.
|
||||
|
||||
Signatures may be minimally specified (i.e. names of inputs and outputs
|
||||
|
||||
@@ -169,7 +169,7 @@ Returns true if and only if the value of //BigNumber// is zero.
|
||||
_heading: Conversion
|
||||
|
||||
_property: BigNumber.toBigInt() => bigint @SRC<bignumber>
|
||||
Returns the value of //BigNumber// as a [JavScript BigInt](link-js-bigint) value,
|
||||
Returns the value of //BigNumber// as a [JavaScript BigInt](link-js-bigint) value,
|
||||
on platforms which support them.
|
||||
|
||||
_property: BigNumber.toNumber() => number @SRC<bignumber>
|
||||
|
||||
@@ -38,8 +38,10 @@ _heading: Signature @<Signature>
|
||||
|
||||
- **r** and **s** --- The x co-ordinate of **r** and the **s** value of the signature
|
||||
- **v** --- The parity of the y co-ordinate of **r**
|
||||
- **_vs** --- The [compact representation](link-eip-2098) of the **s** and **v**
|
||||
- **yParityAndS** --- The [compact representation](link-eip-2098) of the **s** and **v**
|
||||
- **_vs** --- Deprecated property; renamed to yParityAndS
|
||||
- **recoveryParam** --- The normalized (i.e. 0 or 1) value of **v**
|
||||
- **compact** - The full siggnature using [compact representation](link-eip-2098)
|
||||
|
||||
_heading: Raw Signature @<signature-raw> @inherit<string\<[[DataHexString]]\<65\>\>>
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
_section: Constants @<constants>
|
||||
|
||||
The **ethers.contants** Object contains commonly used values.
|
||||
The **ethers.constants** Object contains commonly used values.
|
||||
|
||||
|
||||
_subsection: Bytes
|
||||
|
||||
@@ -33,6 +33,12 @@ How long to wait before rejecting with a //timeout// error.
|
||||
_property: connection.headers => { [ key: string]: string }
|
||||
Additional headers to include in the connection.
|
||||
|
||||
_property: connection.skipFetchSetup => boolean
|
||||
Normally a connection will specify the default values for a connection
|
||||
such as CORS-behavior and caching policy, to ensure compatibility across
|
||||
platforms. On some services, such as Cloudflare Workers, specifying any
|
||||
value (inclluding the default values) will cause failure. Setting this
|
||||
to true will prevent any values being passed to the underlying API.
|
||||
|
||||
_heading: PollOptions @<PollOptions>
|
||||
|
||||
|
||||
@@ -91,7 +91,7 @@ _code: ERC-20 Transfer Filter Examples @lang<javascript>
|
||||
filter = {
|
||||
address: tokenAddress,
|
||||
topics: [
|
||||
id("Transfer(address,address,uint256)"),
|
||||
utils.id("Transfer(address,address,uint256)"),
|
||||
hexZeroPad(myAddress, 32)
|
||||
]
|
||||
};
|
||||
@@ -100,7 +100,7 @@ filter = {
|
||||
filter = {
|
||||
address: tokenAddress,
|
||||
topics: [
|
||||
id("Transfer(address,address,uint256)"),
|
||||
utils.id("Transfer(address,address,uint256)"),
|
||||
null,
|
||||
hexZeroPad(myAddress, 32)
|
||||
]
|
||||
@@ -110,7 +110,7 @@ filter = {
|
||||
filter = {
|
||||
address: tokenAddress,
|
||||
topics: [
|
||||
id("Transfer(address,address,uint256)"),
|
||||
utils.id("Transfer(address,address,uint256)"),
|
||||
null,
|
||||
[
|
||||
hexZeroPad(myAddress, 32),
|
||||
|
||||
@@ -26,7 +26,7 @@ importantly securely released.
|
||||
|
||||
[Historically](https://github.com/nodejs/node/issues/4660),
|
||||
``new Buffer(16)`` would re-use old memory that had been
|
||||
released. This would mean that code runnint later, may have
|
||||
released. This would mean that code running later, may have
|
||||
access to data that was discarded.
|
||||
|
||||
As an example of the dangers, imagine if you had used a Buffer
|
||||
@@ -37,9 +37,9 @@ have that left-over private key, which it could then use to
|
||||
steal the funds from that account.
|
||||
|
||||
There are also many debugging tools and systems designed to
|
||||
assist develoeprs inspect the memory contents of JavaScript
|
||||
assist developers inspect the memory contents of JavaScript
|
||||
programs. In these cases, any //private key// or //mnemonic//
|
||||
siiting in memory may be visible to other users on the system,
|
||||
sitting in memory may be visible to other users on the system,
|
||||
or malicious scripts.
|
||||
|
||||
_heading: Timing Attack
|
||||
@@ -65,9 +65,9 @@ will. By timing how long the code took to execute, they now know
|
||||
whether garbage collection occured and therefore whether the simple
|
||||
or complex path was taken.
|
||||
|
||||
Advancced timing attacks are very difficult to mitigate in any
|
||||
Advanced timing attacks are very difficult to mitigate in any
|
||||
garbage-collection-based language. Most libraries where this
|
||||
matters will hopefully mitigated this for you as much as possible,
|
||||
matters will hopefully mitigate this for you as much as possible,
|
||||
but it is still good to be aware of.
|
||||
|
||||
_heading: General Concerns
|
||||
@@ -128,7 +128,7 @@ progress callback which will be periodically called with a number between
|
||||
In general a progress bar makes the experience feel faster, as well as
|
||||
more comfortable since there is a clear indication how much (relative) time
|
||||
is remaining. Additionally, using language like //"decrypting..."// in
|
||||
a progress bar makes a user feel like there time is not being //needlessly//
|
||||
a progress bar makes a user feel like their time is not being //needlessly//
|
||||
wasted.
|
||||
|
||||
_heading: Work-Arounds (not recommended)
|
||||
|
||||
@@ -226,6 +226,7 @@ module.exports = {
|
||||
externalLinks: {
|
||||
"link-mail": "mailto:me@ricmoo.com",
|
||||
"link-alchemy": { name: "Alchemy", url: "https:/\/alchemyapi.io" },
|
||||
"link-ankr": { name: "Ankr", url: "https:/\/www.ankr.com" },
|
||||
"link-cloudflare": { name: "Cloudflare", url: "https:/\/developers.cloudflare.com/distributed-web/ethereum-gateway/" },
|
||||
"link-ens": { name: "ENS", url: "https:/\/ens.domains/" },
|
||||
"link-ethereum": { name: "Ethereum", url: "https:/\/ethereumorg" },
|
||||
@@ -250,6 +251,8 @@ module.exports = {
|
||||
"link-sphinx": { name: "Sphinx", url: "https:/\/www.sphinx-doc.org/" },
|
||||
|
||||
"link-alchemy-signup": "https:/\/dashboard.alchemyapi.io/signup?referral=55a35117-028e-4b7c-9e47-e275ad0acc6d",
|
||||
"link-ankr-public": "https:/\/www.ankr.com/protocol/public/",
|
||||
"link-ankr-premium": "https:/\/www.ankr.com/protocol/plan/",
|
||||
"link-etherscan-signup": "https:/\/etherscan.io/apis",
|
||||
"link-etherscan-ratelimit": "https:/\/info.etherscan.com/api-return-errors/",
|
||||
"link-infura-signup": "https:/\/infura.io/register",
|
||||
@@ -340,7 +343,7 @@ module.exports = {
|
||||
"link-wiki-hmac": "https:/\/en.wikipedia.org/wiki/HMAC",
|
||||
"link-wiki-iban": "https:/\/en.wikipedia.org/wiki/International_Bank_Account_Number",
|
||||
"link-wiki-ieee754": "https:/\/en.wikipedia.org/wiki/Double-precision_floating-point_format",
|
||||
"link-wiki-observer-pattern": { name: "Obeserver Pattern", url: "https:/\/en.wikipedia.org/wiki/Observer_pattern" },
|
||||
"link-wiki-observer-pattern": { name: "Observer Pattern", url: "https:/\/en.wikipedia.org/wiki/Observer_pattern" },
|
||||
"link-wiki-phishing": "https:/\/en.wikipedia.org/wiki/Phishing",
|
||||
"link-wiki-ripemd": "https:/\/en.m.wikipedia.org/wiki/RIPEMD",
|
||||
"link-wiki-sha2": "https:/\/en.wikipedia.org/wiki/SHA-2",
|
||||
|
||||
@@ -31,7 +31,7 @@ have a public discussion and figure out the best way to address the problem/feat
|
||||
_subsection: Building @<contributing--building>
|
||||
|
||||
The build process for ethers is unfortunatly not super trivial, but
|
||||
I have attempted to make it as straight-forward as possible.
|
||||
I have attempted to make it as straightforward as possible.
|
||||
|
||||
It is a mono-repo which attempts to be compatibile with a large
|
||||
number of environments, build tools and platforms, which is why
|
||||
|
||||
@@ -88,6 +88,9 @@ _code: Connecting to MetaMask @lang<script>
|
||||
// what MetaMask injects as window.ethereum into each page
|
||||
const provider = new ethers.providers.Web3Provider(window.ethereum)
|
||||
|
||||
// MetaMask requires requesting permission to connect users accounts
|
||||
await provider.send("eth_requestAccounts", []);
|
||||
|
||||
// The MetaMask plugin also allows signing transactions to
|
||||
// send ether and pay to change state within the blockchain.
|
||||
// For this, you need the account signer...
|
||||
@@ -301,7 +304,7 @@ filterFrom = daiContract.filters.Transfer(myAddress, null);
|
||||
filterTo = daiContract.filters.Transfer(null, myAddress);
|
||||
//_log: filterTo
|
||||
|
||||
// List all transfers sent from me a specific block range
|
||||
// List all transfers sent from me in a specific block range
|
||||
//_result:
|
||||
await daiContract.queryFilter(filterFrom, 9843470, 9843480)
|
||||
//_log:
|
||||
|
||||
@@ -151,7 +151,7 @@ This section is still a work in progress, but will outline some of the more nuan
|
||||
aspects of the test cases and their values.
|
||||
|
||||
There will likely be an overhaul of the test cases in the next major version, to
|
||||
make code coverage testing more straight forward and to collapse some of the redundancy.
|
||||
make code coverage testing more straightforward and to collapse some of the redundancy.
|
||||
|
||||
For example, there is no longer a need to separate the ABI and ABIv2 test case and the
|
||||
accounts and transactions suites can be merged into one large collection.
|
||||
|
||||
15
docs.wrm/troubleshooting/building.wrm
Normal file
15
docs.wrm/troubleshooting/building.wrm
Normal file
@@ -0,0 +1,15 @@
|
||||
_section: Building @<troubleshooting-building>
|
||||
|
||||
@TODO
|
||||
|
||||
_subsection: Packages
|
||||
|
||||
Sometimes packages get out of sync.
|
||||
|
||||
_code:
|
||||
|
||||
/home/ethers> rm package-lock.json node_modules/
|
||||
|
||||
/home/ethers> rm yarn.lock
|
||||
|
||||
/home/ethers> npm install
|
||||
249
docs.wrm/troubleshooting/errors.wrm
Normal file
249
docs.wrm/troubleshooting/errors.wrm
Normal file
@@ -0,0 +1,249 @@
|
||||
_section: Error Codes @<error-codes>
|
||||
|
||||
All errors in ethers are created by the [[Logger]] class, which includes
|
||||
a number of additional properties and extra data, which can assist in
|
||||
debugging and when submitting issues.
|
||||
|
||||
When submitting an issue, please include as much of any error as possible,
|
||||
but also make sure you understand the error and have tried suggested solutions
|
||||
both in this trouble-shooting document and any other issues you find when
|
||||
searching the GitHub issues.
|
||||
|
||||
|
||||
_subsection: CALL_EXCEPTION @<help-CALL_EXCEPTION>
|
||||
|
||||
This error occurs when a call or transaction is used to interact with
|
||||
the blockchain reverts (via ``revert``, ``require``, et cetera).
|
||||
|
||||
Due to the overall flexibility of Ethereum and Turing Completeness,
|
||||
there is a large variety of reasons this can occur and troubleshooting
|
||||
requires attention.
|
||||
|
||||
|
||||
_heading: Common Causes
|
||||
|
||||
- The code does not exist on-chain. This may happen if you failed to wait
|
||||
until the contract was deployed, the address is incorrect or if you
|
||||
are connected to a different network than the contract has been deployed.
|
||||
Check the code exists using ``provider.getCode(address)``.
|
||||
- The wrong code is being accessed, for example if an artifact file was
|
||||
not correctly updated so an older instance of the contract is being called
|
||||
- The contract is failing during a ``require`` statement. For example, if
|
||||
a contract method requires an //admin account// to be used, but the
|
||||
contract is connected to another [[Signer]].
|
||||
- The wrong ABI is being used to interact with a contract.
|
||||
|
||||
_heading: Debugging
|
||||
|
||||
- Always double check the address and network you are connected to and use
|
||||
``provider.getCode(address)`` to verify the deployed code matches your
|
||||
most recent version.
|
||||
- Try accessing other, simpler contract methods to verify the account is correct.
|
||||
|
||||
|
||||
_subsection: INSUFFICIENT_FUNDS @<help-INSUFFICIENT_FUNDS>
|
||||
|
||||
This usually occurs when a transaction is attempted, but the sending account
|
||||
does not have enough ether to cover the cost of the transaction.
|
||||
|
||||
A transaction has an intrinsic cost which must be met, which accounts for
|
||||
the value being sent, the base fee of the transaction, additional fees per byte
|
||||
of calldata and whether the transaction will create a new account (i.e. the ``to``
|
||||
is empty).
|
||||
|
||||
This error can also happen if ``provider.estimateGas`` is used with a non-zero
|
||||
fee (i.e. ``gasPrice``, ``maxFeePerGas`` or ``maxPriorityFeePerGas``). If any
|
||||
fee properties are specified, the ``from`` account must have sufficient ether
|
||||
to execute the transaction.
|
||||
|
||||
|
||||
_subsection: MISSING_NEW @<help-MISSING_NEW>
|
||||
|
||||
Classes in ethers must be instantiated with the ``new`` operator. This
|
||||
error indicates that a Class is attempting to be used as a function.
|
||||
|
||||
_code: Examples @lang<javascript>
|
||||
|
||||
//_hide: privateKey = "0x0123456789012345678901234567890123456789012345678901234567890123";
|
||||
//_hide: Wallet = ethers.Wallet;
|
||||
|
||||
// Bad:
|
||||
//_throws:
|
||||
ethers.Wallet(privateKey)
|
||||
//_log:
|
||||
|
||||
// Good:
|
||||
//_result:
|
||||
new ethers.Wallet(privateKey)
|
||||
//_log:
|
||||
|
||||
|
||||
_subsection: NONCE_EXPIRED @<help-NONCE_EXPIRED>
|
||||
|
||||
This error occurs when a transaction is being sent with a ``nonce`` that
|
||||
is lower than next required ``nonce``.
|
||||
|
||||
Each Ethereum transaction requires a ``nonce`` property equal to the index
|
||||
of that transaction for that account for all time. So, if an account has
|
||||
send four transactions over its lifetime, that means the nonces 0 though 3
|
||||
(inclusive) have been used. The next transaction must use a nonce of 4.
|
||||
Attempting to re-use a nonce less than 4 will result in this error.
|
||||
|
||||
|
||||
_subsection: NUMERIC_FAULT @<help-NUMERIC_FAULT>
|
||||
|
||||
A [numeric fault](errors--numeric-fault) is a consequence of
|
||||
performing an illegal operation with numeric values, such as
|
||||
dividing by zero.
|
||||
|
||||
The error will indicate the ``operation``, which further indicates
|
||||
the reason for the error.
|
||||
|
||||
|
||||
_heading: Overflow @<help-NUMERIC_FAULT-overflow>
|
||||
|
||||
JavaScript uses [IEEE 754 double-precision binary floating point](link-wiki-ieee754)
|
||||
numbers to represent numeric values. As a result, there are //holes//
|
||||
in the integer set after 9,007,199,254,740,991; which is
|
||||
problematic for //Ethereum// because that is only around 0.009
|
||||
ether (in wei), which means any value over that will begin to
|
||||
experience rounding errors.
|
||||
|
||||
As a result, any attempt to use a number which is outside the safe
|
||||
range, which would result in incorrect values, an error is thrown.
|
||||
|
||||
In general, numbers should be kept as strings, [[BigNumber]] instances or
|
||||
using ES2020 bigints, which all can safely be used without loss of precission.
|
||||
|
||||
_code: Examples @lang<javascript>
|
||||
|
||||
// One ether is outside the safe range
|
||||
//_throws:
|
||||
BigNumber.from(1000000000000000000)
|
||||
//_log:
|
||||
|
||||
// Providing the value as a string is safe
|
||||
//_result:
|
||||
BigNumber.from("1000000000000000000")
|
||||
//_log:
|
||||
|
||||
// As is using a bigint (notice the `n` suffix)
|
||||
//_result:
|
||||
BigNumber.from(1000000000000000000n)
|
||||
//_log:
|
||||
|
||||
// But most often, the `parseEther` function solves this
|
||||
//_result:
|
||||
utils.parseEther("1.0")
|
||||
//_log:
|
||||
|
||||
|
||||
_heading: Numeric Underflow @<help-NUMERIC_FAULT-underflow>
|
||||
|
||||
Numeric underflow sbould not be confused with overflow.
|
||||
|
||||
Numeric underflow occurs when the precission of a value cannot be
|
||||
safely represented in the current data type.
|
||||
|
||||
**Common Causes**
|
||||
|
||||
- Using values with fractional componets (e.g. ``BigNumber.from(1.2)``).
|
||||
If you require fractions, you must use the [[FixedNumber]] class.
|
||||
- Parsing string values that have more decimals than the unit supports
|
||||
(e.g. ``parseUints("1.33", 1)``).
|
||||
|
||||
_code: Examples @lang<javascript>
|
||||
|
||||
// BigNumbers cannot be created with a fractional component
|
||||
//_throws:
|
||||
BigNumber.from(1.2)
|
||||
//_log:
|
||||
|
||||
// Parsing a value with more decimals than the type
|
||||
//_throws:
|
||||
utils.parseUnits("1.34", 1);
|
||||
//_log:
|
||||
|
||||
|
||||
_heading: Division by zero @<help-NUMERIC_FAULT-division-by-zero>
|
||||
|
||||
This error occurs when dividing by zero or attempting to take the modulo zero.
|
||||
|
||||
|
||||
_heading: Unbound Result @<help-NUMERIC_FAULT-unbound-result>
|
||||
|
||||
The ethers [[BigNumber]] does not support bitwise operators
|
||||
on negative numbers which can result in the need for an infinite
|
||||
number of set bits.
|
||||
|
||||
Other implementations may use negative values to indicate this,
|
||||
but this is considered out of scope for ethers.
|
||||
|
||||
|
||||
_heading: Unsupported Operation @<help-NUMERIC_FAULT-unsupported>
|
||||
|
||||
The ethers [[BigNumber]] does not support negative powers or bitwise
|
||||
shift operation using negative values.
|
||||
|
||||
_code: Examples @lang<javascript>
|
||||
|
||||
two = BigNumber.from(2);
|
||||
|
||||
//_throws:
|
||||
two.pow(-2)
|
||||
//_log:
|
||||
|
||||
// Cannot use negative values to alter shift direction
|
||||
//_throws:
|
||||
two.shr(-1)
|
||||
//_log:
|
||||
|
||||
|
||||
_subsection: REPLACEMENT_UNDERPRICED @<help-REPLACEMENT_UNDERPRICED>
|
||||
|
||||
To prevent nodes from being overloaded with junk transactions, a transaction
|
||||
is only accepted into the memory pool if it has a reasonable chance of being
|
||||
actually mined, which means that the account has sufficient balance, the nonce
|
||||
is correct and the fee seems reasonable.
|
||||
|
||||
Once a transaction is in the memory pool though, to prevent an account from
|
||||
flooding the network with many different transactions with the same nonce (each
|
||||
of which satisfies the above criteria), to replace an existing transaction
|
||||
an additional committment of a fee must be made by increasing the promised fee.
|
||||
|
||||
When replacing a legacy non-EIP1559 transaction, the ``gasPrice`` must be
|
||||
increased. When replacing a modern, EIP-1559 transaction, the ``maxPriorityFeePerGas``
|
||||
should be increased.
|
||||
|
||||
|
||||
_subsection: TRANSACTION_REPLACED @<help-TRANSACTION_REPLACED>
|
||||
|
||||
This error is thrown when waiting for a transaction which has been
|
||||
replaced by another, by the sender submitting a second transaction
|
||||
with the same nonce, while the transaction was pending in the
|
||||
transaction pool.
|
||||
|
||||
You can learn more about this feature in the ``.wait`` method of
|
||||
[TransactionResponse](providers-TransactionResponse).
|
||||
|
||||
|
||||
_subsection: UNPREDICTABLE_GAS_LIMIT @<help-UNPREDICTABLE_GAS_LIMIT>
|
||||
|
||||
During gas estimation it is possible that a transaction would actually
|
||||
fail (and hence has no reasonable estimate of gas requirements) or that
|
||||
the transaction is complex in a way that does not permit a node to
|
||||
estiamte the gas requirements, in which case this error is thrown.
|
||||
|
||||
In almost all cases, this will unfortunately require you specify an
|
||||
explicit ``gasLimit`` for your transaction, which will disable ether's
|
||||
automatic population of the ``gasLimit`` field, which will cause this
|
||||
error to go away.
|
||||
|
||||
To dial in an appropriate gas limit, try a value that is much higher
|
||||
than you expect, and then make a few transactions to discover reasonable
|
||||
values and then you can reduce this value down to that ballpark.
|
||||
|
||||
Keep in mind this error can also occur if the transaction would
|
||||
legitimately fail, in which case the root cause must be addressed, such
|
||||
as ensuring the correct [[Signer]] is being used, the appropriate allowance
|
||||
for an ERC-20 token has been approved, etc.
|
||||
62
docs.wrm/troubleshooting/help.wrm
Normal file
62
docs.wrm/troubleshooting/help.wrm
Normal file
@@ -0,0 +1,62 @@
|
||||
_section: Getting Help @<troubleshooting-issues>
|
||||
|
||||
@TODO
|
||||
|
||||
_subsection: Starting a discussion
|
||||
|
||||
Before opening an issue
|
||||
|
||||
|
||||
_subsection: Opening an Issue
|
||||
|
||||
Keep in mind that opening an issue should be a last resort, as it
|
||||
requires time and energy by the library developers to look at that
|
||||
could otherwise be spent on improving the library, documentation
|
||||
and tools.
|
||||
|
||||
Before opening an issue, please make sure you have searched any
|
||||
public information, such as:
|
||||
|
||||
- Documentation
|
||||
- GitHub Discussions
|
||||
- GitHub Issues (including closed issues)
|
||||
|
||||
There are several types of issues tracked by ethers. Using the correct
|
||||
one helps you receive feedback quicker and helps us keep the right
|
||||
person
|
||||
|
||||
_heading: Feature Requests
|
||||
|
||||
|
||||
|
||||
_heading: Bugs
|
||||
|
||||
This type of issue is for anything you you believe to be a bug in ethers.
|
||||
|
||||
Keep in mind that ethers is used extensively by thousands of people every
|
||||
day, so while chances are possible you found a bug, please make sure to
|
||||
do your due diligence to rule out user error.
|
||||
|
||||
If you are new to ethers, or are doing a fairly common operation, it is
|
||||
quite likely what you are experiencing is a misunderstanding of how to
|
||||
use a function, method or class. You should consider opening a discussion first.
|
||||
|
||||
|
||||
Please make sure you include as much information as is useful:
|
||||
|
||||
- Are you using a third-party library, like Hardhat or Truffle?
|
||||
- What platform are you on, a web browser, React Native, node, etc.?
|
||||
- What network are you on, such as Ethereum mainnet, Optimism, etc.?
|
||||
- What backend are you using, such as Geth, INFURA, Provider Engine, etc.?
|
||||
|
||||
|
||||
_heading: Docuementation
|
||||
|
||||
If you have found a typo in the documentation, a feature which isn't
|
||||
documented (or documented well) or just find something described in
|
||||
the documentation confusing, please feel free to create an issue and
|
||||
we will try to improve it.
|
||||
|
||||
_heading: Other
|
||||
|
||||
This should never be used.
|
||||
11
docs.wrm/troubleshooting/index.wrm
Normal file
11
docs.wrm/troubleshooting/index.wrm
Normal file
@@ -0,0 +1,11 @@
|
||||
_section: TroubleShooting
|
||||
|
||||
|
||||
|
||||
_toc:
|
||||
building
|
||||
errors
|
||||
network
|
||||
help
|
||||
|
||||
_subsection: About Trbouble-Shooting
|
||||
9
docs.wrm/troubleshooting/network.wrm
Normal file
9
docs.wrm/troubleshooting/network.wrm
Normal file
@@ -0,0 +1,9 @@
|
||||
_section: Troubleshooting Network @<troubleshooting-network>
|
||||
|
||||
@TODO
|
||||
|
||||
_subsection: Links
|
||||
|
||||
_subsection: Cross-Origin Resource Sharing (CORS)
|
||||
|
||||
_subsection: Mobile Development (Device Firewalls)
|
||||
0
misc/admin/lib/cmds/peg-version.d.ts
vendored
Normal file
0
misc/admin/lib/cmds/peg-version.d.ts
vendored
Normal file
16
misc/admin/lib/cmds/peg-version.js
Normal file
16
misc/admin/lib/cmds/peg-version.js
Normal file
@@ -0,0 +1,16 @@
|
||||
/*
|
||||
import { dirnames, getPackage } from "../local";
|
||||
import { colorify } from "../log";
|
||||
|
||||
const dirname = process.argv[2];
|
||||
if (dirname == null) {
|
||||
console.log("Usage: peg-version DIRNAME");
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
(async function(dirname) {
|
||||
const { name, version } = getPackage(dirname);
|
||||
console.log(colorify.bold(`Pegging ${ name } to ${ version }...`));
|
||||
|
||||
})(dirname);
|
||||
*/
|
||||
@@ -23,16 +23,16 @@ const Words = fs_1.default.readFileSync("/usr/share/dict/words").toString().spli
|
||||
`
|
||||
// Words missing from the dictionary
|
||||
accessing addresses aligned autofill avatar called cancelled changed censored
|
||||
clamping compiled computed configured consumed creating decoded decoding
|
||||
clamping compiled computed configured consumed contained creating decoded decoding
|
||||
decreased decrypt decrypted decrypting deployed deploying deprecated detected
|
||||
discontinued earliest email emitted enabled encoded encoder encoding encrypt
|
||||
encrypted encrypting entries euro exceeded existing expected
|
||||
discontinued earliest email emitted enabled encoded encoder encoding encountered
|
||||
encrypt encrypted encrypting entries euro exceeded existing expected
|
||||
expired failed fetches formatted formatting funding generated
|
||||
hardened has highly ignoring implemented implementer imported including instantiate
|
||||
joined keyword labelled larger lookup matches mined modified modifies multi
|
||||
named needed nested neutered numeric offline optimizer overriding owned packed
|
||||
padded parsed parsing passed payload placeholder processing properties prototyping reached
|
||||
recommended recovered redacted remaining replaced repriced required reverted
|
||||
recommended recovered recursively redacted remaining replaced repriced required reverted
|
||||
serializes shared signed signing skipped stats stored supported tagging targetted
|
||||
throttled transactions typed uninstall unstake unsubscribe untyped
|
||||
using verifies verifying website
|
||||
@@ -56,15 +56,15 @@ ABIEncoder testcase numberish Wordlist
|
||||
|
||||
// Common Code Strings
|
||||
abi addr api app arg arrayify asm backend basex bigint bignumber bn byte
|
||||
bytecode callback calldata charset checksum ciphertext cli codepoint
|
||||
bytecode callback calldata ccip charset checksum ciphertext cli codepoint
|
||||
commify config
|
||||
contenthash ctr ctrl debug dd dklen eexist encseed eof eq erc ethaddr
|
||||
ethseed ethers eval exec filename func gz gzip hid http https hw iv
|
||||
info init ipc json kdf kdfparams labelhash lang lib metadata mm multihash nfc
|
||||
nfkc nfd nfkd nodehash notok nowait nullish oob opcode pbkdf pc plugin
|
||||
nfkc nfd nfkd nodehash notok nowait nullish offchain oob opcode org pbkdf pc plugin
|
||||
pragma pre prf recid repl rpc sighash topichash solc stdin stdout subclasses
|
||||
subnode timeout todo txt typeof ufixed utc utf util url urlencoded uuid vm
|
||||
vs websocket wikipedia www wx xe xpriv xpub xx yyyy zlib
|
||||
vs websocket wikipedia wildcard wildcards www wx xe xpriv xpub xx yyyy zlib
|
||||
|
||||
// AbiV2
|
||||
abiv
|
||||
@@ -72,14 +72,14 @@ abiv
|
||||
// Query parameters
|
||||
apikey asc endblock startblock
|
||||
|
||||
alchemyapi Cloudflare Etherscan INFURA IPFS MetaMask Nodesmith
|
||||
alchemyapi ankr arbitrum Cloudflare com Etherscan INFURA IPFS IPNS MetaMask Nodesmith
|
||||
Trezor ledgerhq axic bitcoinjs browserify easyseed ethereumjs
|
||||
goerli homestead kotti kovan mainnet morden mordor rinkeby
|
||||
goerli homestead kotti kovan mainnet morden mordor rinkeby kintsugi
|
||||
ropsten testnet lb maticmum
|
||||
|
||||
// Demo words
|
||||
args foo eth foo foobar ll localhost passwd ricmoo tx xxx yna
|
||||
brantly
|
||||
brantly ricmoose
|
||||
|
||||
// nameprep tags
|
||||
ALCat BiDi LCat nameprep
|
||||
|
||||
@@ -47,7 +47,11 @@ function getPackage(name, version) {
|
||||
if (version == null) {
|
||||
const versions = Object.keys(infos.versions);
|
||||
versions.sort(semver_1.default.compare);
|
||||
version = versions.pop();
|
||||
// HACK: So v5 continues working while v6 is managed by reticulate
|
||||
version = "6.0.0";
|
||||
while (version.indexOf("beta") >= 0 || semver_1.default.gte(version, "6.0.0")) {
|
||||
version = versions.pop();
|
||||
}
|
||||
}
|
||||
const info = infos.versions[version];
|
||||
return {
|
||||
|
||||
16
misc/admin/src.ts/cmds/peg-version.ts
Normal file
16
misc/admin/src.ts/cmds/peg-version.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
/*
|
||||
import { dirnames, getPackage } from "../local";
|
||||
import { colorify } from "../log";
|
||||
|
||||
const dirname = process.argv[2];
|
||||
if (dirname == null) {
|
||||
console.log("Usage: peg-version DIRNAME");
|
||||
process.exit(1);
|
||||
}
|
||||
|
||||
(async function(dirname) {
|
||||
const { name, version } = getPackage(dirname);
|
||||
console.log(colorify.bold(`Pegging ${ name } to ${ version }...`));
|
||||
|
||||
})(dirname);
|
||||
*/
|
||||
@@ -14,16 +14,16 @@ const Words = fs.readFileSync("/usr/share/dict/words").toString().split("\n").re
|
||||
`
|
||||
// Words missing from the dictionary
|
||||
accessing addresses aligned autofill avatar called cancelled changed censored
|
||||
clamping compiled computed configured consumed creating decoded decoding
|
||||
clamping compiled computed configured consumed contained creating decoded decoding
|
||||
decreased decrypt decrypted decrypting deployed deploying deprecated detected
|
||||
discontinued earliest email emitted enabled encoded encoder encoding encrypt
|
||||
encrypted encrypting entries euro exceeded existing expected
|
||||
discontinued earliest email emitted enabled encoded encoder encoding encountered
|
||||
encrypt encrypted encrypting entries euro exceeded existing expected
|
||||
expired failed fetches formatted formatting funding generated
|
||||
hardened has highly ignoring implemented implementer imported including instantiate
|
||||
joined keyword labelled larger lookup matches mined modified modifies multi
|
||||
named needed nested neutered numeric offline optimizer overriding owned packed
|
||||
padded parsed parsing passed payload placeholder processing properties prototyping reached
|
||||
recommended recovered redacted remaining replaced repriced required reverted
|
||||
recommended recovered recursively redacted remaining replaced repriced required reverted
|
||||
serializes shared signed signing skipped stats stored supported tagging targetted
|
||||
throttled transactions typed uninstall unstake unsubscribe untyped
|
||||
using verifies verifying website
|
||||
@@ -47,15 +47,15 @@ ABIEncoder testcase numberish Wordlist
|
||||
|
||||
// Common Code Strings
|
||||
abi addr api app arg arrayify asm backend basex bigint bignumber bn byte
|
||||
bytecode callback calldata charset checksum ciphertext cli codepoint
|
||||
bytecode callback calldata ccip charset checksum ciphertext cli codepoint
|
||||
commify config
|
||||
contenthash ctr ctrl debug dd dklen eexist encseed eof eq erc ethaddr
|
||||
ethseed ethers eval exec filename func gz gzip hid http https hw iv
|
||||
info init ipc json kdf kdfparams labelhash lang lib metadata mm multihash nfc
|
||||
nfkc nfd nfkd nodehash notok nowait nullish oob opcode pbkdf pc plugin
|
||||
nfkc nfd nfkd nodehash notok nowait nullish offchain oob opcode org pbkdf pc plugin
|
||||
pragma pre prf recid repl rpc sighash topichash solc stdin stdout subclasses
|
||||
subnode timeout todo txt typeof ufixed utc utf util url urlencoded uuid vm
|
||||
vs websocket wikipedia www wx xe xpriv xpub xx yyyy zlib
|
||||
vs websocket wikipedia wildcard wildcards www wx xe xpriv xpub xx yyyy zlib
|
||||
|
||||
// AbiV2
|
||||
abiv
|
||||
@@ -63,14 +63,14 @@ abiv
|
||||
// Query parameters
|
||||
apikey asc endblock startblock
|
||||
|
||||
alchemyapi Cloudflare Etherscan INFURA IPFS MetaMask Nodesmith
|
||||
alchemyapi ankr arbitrum Cloudflare com Etherscan INFURA IPFS IPNS MetaMask Nodesmith
|
||||
Trezor ledgerhq axic bitcoinjs browserify easyseed ethereumjs
|
||||
goerli homestead kotti kovan mainnet morden mordor rinkeby
|
||||
goerli homestead kotti kovan mainnet morden mordor rinkeby kintsugi
|
||||
ropsten testnet lb maticmum
|
||||
|
||||
// Demo words
|
||||
args foo eth foo foobar ll localhost passwd ricmoo tx xxx yna
|
||||
brantly
|
||||
brantly ricmoose
|
||||
|
||||
// nameprep tags
|
||||
ALCat BiDi LCat nameprep
|
||||
|
||||
@@ -32,7 +32,12 @@ export async function getPackage(name: string, version?: string): Promise<Packag
|
||||
if (version == null) {
|
||||
const versions = Object.keys(infos.versions);
|
||||
versions.sort(semver.compare);
|
||||
version = versions.pop();
|
||||
|
||||
// HACK: So v5 continues working while v6 is managed by reticulate
|
||||
version = "6.0.0";
|
||||
while (version.indexOf("beta") >= 0 || semver.gte(version, "6.0.0")) {
|
||||
version = versions.pop();
|
||||
}
|
||||
}
|
||||
|
||||
const info = infos.versions[version];
|
||||
|
||||
1341
package-lock.json
generated
1341
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -65,11 +65,11 @@
|
||||
"@types/node": "^12.7.4",
|
||||
"@types/semver": "^7.3.4",
|
||||
"aes-js": "3.0.0",
|
||||
"aws-sdk": "2.137.0",
|
||||
"aws-sdk": "2.1039.0",
|
||||
"diff": "4.0.1",
|
||||
"flatworm": "0.0.2-beta.7",
|
||||
"jison": "0.4.18",
|
||||
"karma": "6.3.2",
|
||||
"karma": "6.3.17",
|
||||
"karma-chrome-launcher": "3.1.0",
|
||||
"karma-mocha": "2.0.1",
|
||||
"libnpmpublish": "3.0.1",
|
||||
|
||||
2
packages/abi/lib.esm/_version.d.ts
vendored
2
packages/abi/lib.esm/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "abi/5.5.0";
|
||||
export declare const version = "abi/5.6.1";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,2 +1,2 @@
|
||||
export const version = "abi/5.5.0";
|
||||
export const version = "abi/5.6.1";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"file":"interface.d.ts","sourceRoot":"","sources":["../src.ts/interface.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAC;AACnE,OAAO,EAAY,SAAS,EAA0D,MAAM,sBAAsB,CAAC;AAGnH,OAAO,EAAkB,WAAW,EAAa,MAAM,2BAA2B,CAAC;AAEnF,OAAO,EAAE,QAAQ,EAAmB,MAAM,aAAa,CAAC;AACxD,OAAO,EAAE,iBAAiB,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AACpE,OAAO,EAAE,mBAAmB,EAAE,aAAa,EAAE,aAAa,EAAe,QAAQ,EAAE,gBAAgB,EAAE,YAAY,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAMlJ,OAAO,EAAE,iBAAiB,EAAE,MAAM,EAAE,CAAC;AAErC,qBAAa,cAAe,SAAQ,WAAW,CAAC,cAAc,CAAC;IAC3D,QAAQ,CAAC,aAAa,EAAE,aAAa,CAAC;IACtC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,KAAK,EAAE,MAAM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}
|
||||
let bytes = arrayify(data);
|
||||
let reason = null;
|
||||
let message = "";
|
||||
let errorArgs = null;
|
||||
let errorName = null;
|
||||
let errorSignature = null;
|
||||
@@ -323,6 +324,12 @@ export class Interface {
|
||||
if (builtin.reason) {
|
||||
reason = errorArgs[0];
|
||||
}
|
||||
if (errorName === "Error") {
|
||||
message = `; VM Exception while processing transaction: reverted with reason string ${JSON.stringify(errorArgs[0])}`;
|
||||
}
|
||||
else if (errorName === "Panic") {
|
||||
message = `; VM Exception while processing transaction: reverted with panic code ${errorArgs[0]}`;
|
||||
}
|
||||
}
|
||||
else {
|
||||
try {
|
||||
@@ -331,16 +338,14 @@ export class Interface {
|
||||
errorName = error.name;
|
||||
errorSignature = error.format();
|
||||
}
|
||||
catch (error) {
|
||||
console.log(error);
|
||||
}
|
||||
catch (error) { }
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return logger.throwError("call revert exception", Logger.errors.CALL_EXCEPTION, {
|
||||
return logger.throwError("call revert exception" + message, Logger.errors.CALL_EXCEPTION, {
|
||||
method: functionFragment.format(),
|
||||
errorArgs, errorName, errorSignature, reason
|
||||
data: hexlify(data), errorArgs, errorName, errorSignature, reason
|
||||
});
|
||||
}
|
||||
// Encode the result for a function call (e.g. for eth_call)
|
||||
|
||||
File diff suppressed because one or more lines are too long
2
packages/abi/lib/_version.d.ts
vendored
2
packages/abi/lib/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "abi/5.5.0";
|
||||
export declare const version = "abi/5.6.1";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,5 +1,5 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.version = void 0;
|
||||
exports.version = "abi/5.5.0";
|
||||
exports.version = "abi/5.6.1";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"file":"interface.d.ts","sourceRoot":"","sources":["../src.ts/interface.ts"],"names":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E,MAAM,EAAE,aAAa,CAAC,GAAG,CAAC,GAAG;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;KAAE;IA4CjH,cAAc,CAAC,aAAa,EAAE,aAAa,GAAG,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,GAAG,MAAM;IA4F9G,gBAAgB,CAAC,EAAE,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,CAAC,EAAE,YAAY,CAAA;KAAE,GAAG,sBAAsB;IAoBpF,QAAQ,CAAC,GAAG,EAAE;QAAE,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAC,GAAG,cAAc;IAmBrE,UAAU,CAAC,IAAI,EAAE,SAAS,GAAG,gBAAgB;IA4B7C,MAAM,CAAC,WAAW,CAAC,KAAK,EAAE,GAAG,GAAG,KAAK,IAAI,SAAS;CAGrD"}
|
||||
@@ -346,6 +346,7 @@ var Interface = /** @class */ (function () {
|
||||
}
|
||||
var bytes = (0, bytes_1.arrayify)(data);
|
||||
var reason = null;
|
||||
var message = "";
|
||||
var errorArgs = null;
|
||||
var errorName = null;
|
||||
var errorSignature = null;
|
||||
@@ -366,6 +367,12 @@ var Interface = /** @class */ (function () {
|
||||
if (builtin.reason) {
|
||||
reason = errorArgs[0];
|
||||
}
|
||||
if (errorName === "Error") {
|
||||
message = "; VM Exception while processing transaction: reverted with reason string " + JSON.stringify(errorArgs[0]);
|
||||
}
|
||||
else if (errorName === "Panic") {
|
||||
message = "; VM Exception while processing transaction: reverted with panic code " + errorArgs[0];
|
||||
}
|
||||
}
|
||||
else {
|
||||
try {
|
||||
@@ -374,15 +381,14 @@ var Interface = /** @class */ (function () {
|
||||
errorName = error.name;
|
||||
errorSignature = error.format();
|
||||
}
|
||||
catch (error) {
|
||||
console.log(error);
|
||||
}
|
||||
catch (error) { }
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return logger.throwError("call revert exception", logger_1.Logger.errors.CALL_EXCEPTION, {
|
||||
return logger.throwError("call revert exception" + message, logger_1.Logger.errors.CALL_EXCEPTION, {
|
||||
method: functionFragment.format(),
|
||||
data: (0, bytes_1.hexlify)(data),
|
||||
errorArgs: errorArgs,
|
||||
errorName: errorName,
|
||||
errorSignature: errorSignature,
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,15 +1,15 @@
|
||||
{
|
||||
"author": "Richard Moore <me@ricmoo.com>",
|
||||
"dependencies": {
|
||||
"@ethersproject/address": "^5.5.0",
|
||||
"@ethersproject/bignumber": "^5.5.0",
|
||||
"@ethersproject/bytes": "^5.5.0",
|
||||
"@ethersproject/constants": "^5.5.0",
|
||||
"@ethersproject/hash": "^5.5.0",
|
||||
"@ethersproject/keccak256": "^5.5.0",
|
||||
"@ethersproject/logger": "^5.5.0",
|
||||
"@ethersproject/properties": "^5.5.0",
|
||||
"@ethersproject/strings": "^5.5.0"
|
||||
"@ethersproject/address": "^5.6.0",
|
||||
"@ethersproject/bignumber": "^5.6.0",
|
||||
"@ethersproject/bytes": "^5.6.0",
|
||||
"@ethersproject/constants": "^5.6.0",
|
||||
"@ethersproject/hash": "^5.6.0",
|
||||
"@ethersproject/keccak256": "^5.6.0",
|
||||
"@ethersproject/logger": "^5.6.0",
|
||||
"@ethersproject/properties": "^5.6.0",
|
||||
"@ethersproject/strings": "^5.6.0"
|
||||
},
|
||||
"description": "Utilities and Classes for parsing, formatting and managing Ethereum ABIs.",
|
||||
"ethereum": "donations.ethers.eth",
|
||||
@@ -43,7 +43,7 @@
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"sideEffects": false,
|
||||
"tarballHash": "0x32c0119e32be278064ae36bc915b7c5baf33479b8ad26dad71ee38a6f78b4296",
|
||||
"tarballHash": "0xa0d59e36648dee1339d01bd85e3132c9ab6c2dc090209350bb290ceeb2f364cf",
|
||||
"types": "./lib/index.d.ts",
|
||||
"version": "5.5.0"
|
||||
"version": "5.6.1"
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
export const version = "abi/5.5.0";
|
||||
export const version = "abi/5.6.1";
|
||||
|
||||
@@ -390,6 +390,7 @@ export class Interface {
|
||||
let bytes = arrayify(data);
|
||||
|
||||
let reason: string = null;
|
||||
let message = "";
|
||||
let errorArgs: Result = null;
|
||||
let errorName: string = null;
|
||||
let errorSignature: string = null;
|
||||
@@ -408,23 +409,26 @@ export class Interface {
|
||||
errorName = builtin.name;
|
||||
errorSignature = builtin.signature;
|
||||
if (builtin.reason) { reason = errorArgs[0]; }
|
||||
if (errorName === "Error") {
|
||||
message = `; VM Exception while processing transaction: reverted with reason string ${ JSON.stringify(errorArgs[0]) }`;
|
||||
} else if (errorName === "Panic") {
|
||||
message = `; VM Exception while processing transaction: reverted with panic code ${ errorArgs[0] }`;
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
const error = this.getError(selector);
|
||||
errorArgs = this._abiCoder.decode(error.inputs, bytes.slice(4));
|
||||
errorName = error.name;
|
||||
errorSignature = error.format();
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
}
|
||||
} catch (error) { }
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return logger.throwError("call revert exception", Logger.errors.CALL_EXCEPTION, {
|
||||
return logger.throwError("call revert exception" + message, Logger.errors.CALL_EXCEPTION, {
|
||||
method: functionFragment.format(),
|
||||
errorArgs, errorName, errorSignature, reason
|
||||
data: hexlify(data), errorArgs, errorName, errorSignature, reason
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
export declare const version = "abstract-provider/5.5.1";
|
||||
export declare const version = "abstract-provider/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,2 +1,2 @@
|
||||
export const version = "abstract-provider/5.5.1";
|
||||
export const version = "abstract-provider/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
@@ -18,6 +18,7 @@ export declare type TransactionRequest = {
|
||||
maxPriorityFeePerGas?: BigNumberish;
|
||||
maxFeePerGas?: BigNumberish;
|
||||
customData?: Record<string, any>;
|
||||
ccipReadEnabled?: boolean;
|
||||
};
|
||||
export interface TransactionResponse extends Transaction {
|
||||
hash: string;
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -89,7 +89,7 @@ export class Provider {
|
||||
// We may want to compute this more accurately in the future,
|
||||
// using the formula "check if the base fee is correct".
|
||||
// See: https://eips.ethereum.org/EIPS/eip-1559
|
||||
maxPriorityFeePerGas = BigNumber.from("2500000000");
|
||||
maxPriorityFeePerGas = BigNumber.from("1500000000");
|
||||
maxFeePerGas = block.baseFeePerGas.mul(2).add(maxPriorityFeePerGas);
|
||||
}
|
||||
return { maxFeePerGas, maxPriorityFeePerGas, gasPrice };
|
||||
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src.ts/index.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;AAEb,OAAO,EAAE,SAAS,EAAgB,MAAM,0BAA0B,CAAC;AACnE,OAAO,EAAa,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAE9D,OAAO,EAAc,WAAW,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAIvG,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAC/C,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AACrC,MAAM,MAAM,GAAG,IAAI,MAAM,CAAC,OAAO,CAAC,CAAC;AA6ClC,CAAC;AAkED,CAAC;AAsBF,qCAAqC;AACrC,0EAA0E;AAC1E,IAAI;AAEJ,MAAM,OAAgB,SAAU,SAAQ,WAAW;IAK/C,MAAM,CAAC,WAAW,CAAC,KAAU;QACzB,OAAO,CAAC,CAAC,CAAC,KAAK,IAAI,KAAK,CAAC,YAAY,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.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "abstract-provider/5.5.1";
|
||||
export declare const version = "abstract-provider/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,5 +1,5 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.version = void 0;
|
||||
exports.version = "abstract-provider/5.5.1";
|
||||
exports.version = "abstract-provider/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
1
packages/abstract-provider/lib/index.d.ts
vendored
1
packages/abstract-provider/lib/index.d.ts
vendored
@@ -18,6 +18,7 @@ export declare type TransactionRequest = {
|
||||
maxPriorityFeePerGas?: BigNumberish;
|
||||
maxFeePerGas?: BigNumberish;
|
||||
customData?: Record<string, any>;
|
||||
ccipReadEnabled?: boolean;
|
||||
};
|
||||
export interface TransactionResponse extends Transaction {
|
||||
hash: string;
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -160,7 +160,7 @@ var Provider = /** @class */ (function () {
|
||||
// We may want to compute this more accurately in the future,
|
||||
// using the formula "check if the base fee is correct".
|
||||
// See: https://eips.ethereum.org/EIPS/eip-1559
|
||||
maxPriorityFeePerGas = bignumber_1.BigNumber.from("2500000000");
|
||||
maxPriorityFeePerGas = bignumber_1.BigNumber.from("1500000000");
|
||||
maxFeePerGas = block.baseFeePerGas.mul(2).add(maxPriorityFeePerGas);
|
||||
}
|
||||
return [2 /*return*/, { maxFeePerGas: maxFeePerGas, maxPriorityFeePerGas: maxPriorityFeePerGas, gasPrice: gasPrice }];
|
||||
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src.ts/index.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEb,sDAAmE;AACnE,8CAA8D;AAE9D,wDAAuG;AAIvG,gDAA+C;AAC/C,uCAAqC;AACrC,IAAM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oBAAoB,GAAG,qBAAS,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;4BACpD,YAAY,GAAG,KAAK,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,oBAAoB,CAAC,CAAC;yBACvE;wBAED,sBAAO,EAAE,YAAY,cAAA,EAAE,oBAAoB,sBAAA,EAAE,QAAQ,UAAA,EAAE,EAAC;;;;KAC3D;IAmCD,iBAAiB;IACjB,8BAAW,GAAX,UAAY,SAAoB,EAAE,QAAkB;QAChD,OAAO,IAAI,CAAC,EAAE,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IACxC,CAAC;IAED,kBAAkB;IAClB,iCAAc,GAAd,UAAe,SAAoB,EAAE,QAAkB;QACnD,OAAO,IAAI,CAAC,GAAG,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IACzC,CAAC;IAYM,mBAAU,GAAjB,UAAkB,KAAU;QACxB,OAAO,CAAC,CAAC,CAAC,KAAK,IAAI,KAAK,CAAC,WAAW,CAAC,CAAC;IAC1C,CAAC;IAyCL,eAAC;AAAD,CAAC,AA/HD,IA+HC;AA/HqB,4BAAQ"}
|
||||
@@ -1,13 +1,13 @@
|
||||
{
|
||||
"author": "Richard Moore <me@ricmoo.com>",
|
||||
"dependencies": {
|
||||
"@ethersproject/bignumber": "^5.5.0",
|
||||
"@ethersproject/bytes": "^5.5.0",
|
||||
"@ethersproject/logger": "^5.5.0",
|
||||
"@ethersproject/networks": "^5.5.0",
|
||||
"@ethersproject/properties": "^5.5.0",
|
||||
"@ethersproject/transactions": "^5.5.0",
|
||||
"@ethersproject/web": "^5.5.0"
|
||||
"@ethersproject/bignumber": "^5.6.0",
|
||||
"@ethersproject/bytes": "^5.6.0",
|
||||
"@ethersproject/logger": "^5.6.0",
|
||||
"@ethersproject/networks": "^5.6.0",
|
||||
"@ethersproject/properties": "^5.6.0",
|
||||
"@ethersproject/transactions": "^5.6.0",
|
||||
"@ethersproject/web": "^5.6.0"
|
||||
},
|
||||
"description": "An Abstract Class for describing an Ethereum Provider for ethers.",
|
||||
"ethereum": "donations.ethers.eth",
|
||||
@@ -41,7 +41,7 @@
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"sideEffects": false,
|
||||
"tarballHash": "0x2bfa68ddd70e2bae7207dbdca73308cf780b5a896a2b8fcc518a912192898860",
|
||||
"tarballHash": "0x27d91252dc988dbfc32462fa6dbdb94c2e169bc142b722e1177e32c2ec643176",
|
||||
"types": "./lib/index.d.ts",
|
||||
"version": "5.5.1"
|
||||
"version": "5.6.0"
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
export const version = "abstract-provider/5.5.1";
|
||||
export const version = "abstract-provider/5.6.0";
|
||||
|
||||
@@ -34,6 +34,7 @@ export type TransactionRequest = {
|
||||
maxFeePerGas?: BigNumberish;
|
||||
|
||||
customData?: Record<string, any>;
|
||||
ccipReadEnabled?: boolean;
|
||||
}
|
||||
|
||||
export interface TransactionResponse extends Transaction {
|
||||
@@ -246,7 +247,7 @@ export abstract class Provider implements OnceBlockable {
|
||||
// We may want to compute this more accurately in the future,
|
||||
// using the formula "check if the base fee is correct".
|
||||
// See: https://eips.ethereum.org/EIPS/eip-1559
|
||||
maxPriorityFeePerGas = BigNumber.from("2500000000");
|
||||
maxPriorityFeePerGas = BigNumber.from("1500000000");
|
||||
maxFeePerGas = block.baseFeePerGas.mul(2).add(maxPriorityFeePerGas);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
export declare const version = "abstract-signer/5.5.0";
|
||||
export declare const version = "abstract-signer/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,2 +1,2 @@
|
||||
export const version = "abstract-signer/5.5.0";
|
||||
export const version = "abstract-signer/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
@@ -13,7 +13,7 @@ import { Logger } from "@ethersproject/logger";
|
||||
import { version } from "./_version";
|
||||
const logger = new Logger(version);
|
||||
const allowedTransactionKeys = [
|
||||
"accessList", "chainId", "customData", "data", "from", "gasLimit", "gasPrice", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "to", "type", "value"
|
||||
"accessList", "ccipReadEnabled", "chainId", "customData", "data", "from", "gasLimit", "gasPrice", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "to", "type", "value"
|
||||
];
|
||||
const forwardErrors = [
|
||||
Logger.errors.INSUFFICIENT_FUNDS,
|
||||
|
||||
File diff suppressed because one or more lines are too long
2
packages/abstract-signer/lib/_version.d.ts
vendored
2
packages/abstract-signer/lib/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "abstract-signer/5.5.0";
|
||||
export declare const version = "abstract-signer/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,5 +1,5 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.version = void 0;
|
||||
exports.version = "abstract-signer/5.5.0";
|
||||
exports.version = "abstract-signer/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
@@ -57,7 +57,7 @@ var logger_1 = require("@ethersproject/logger");
|
||||
var _version_1 = require("./_version");
|
||||
var logger = new logger_1.Logger(_version_1.version);
|
||||
var allowedTransactionKeys = [
|
||||
"accessList", "chainId", "customData", "data", "from", "gasLimit", "gasPrice", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "to", "type", "value"
|
||||
"accessList", "ccipReadEnabled", "chainId", "customData", "data", "from", "gasLimit", "gasPrice", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "to", "type", "value"
|
||||
];
|
||||
var forwardErrors = [
|
||||
logger_1.Logger.errors.INSUFFICIENT_FUNDS,
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"author": "Richard Moore <me@ricmoo.com>",
|
||||
"dependencies": {
|
||||
"@ethersproject/abstract-provider": "^5.5.0",
|
||||
"@ethersproject/bignumber": "^5.5.0",
|
||||
"@ethersproject/bytes": "^5.5.0",
|
||||
"@ethersproject/logger": "^5.5.0",
|
||||
"@ethersproject/properties": "^5.5.0"
|
||||
"@ethersproject/abstract-provider": "^5.6.0",
|
||||
"@ethersproject/bignumber": "^5.6.0",
|
||||
"@ethersproject/bytes": "^5.6.0",
|
||||
"@ethersproject/logger": "^5.6.0",
|
||||
"@ethersproject/properties": "^5.6.0"
|
||||
},
|
||||
"description": "An Abstract Class for desribing an Ethereum Signer for ethers.",
|
||||
"ethereum": "donations.ethers.eth",
|
||||
@@ -39,7 +39,7 @@
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"sideEffects": false,
|
||||
"tarballHash": "0x02eb8a3e41b27927d5717202f6818d00c95b77a3e7227ce3c7312ed21d2ff8ba",
|
||||
"tarballHash": "0x5dd2973bd5c7dca7fa339f56320d464ff2823e82899f5cc7c0e2dacbd3311b5b",
|
||||
"types": "./lib/index.d.ts",
|
||||
"version": "5.5.0"
|
||||
"version": "5.6.0"
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
export const version = "abstract-signer/5.5.0";
|
||||
export const version = "abstract-signer/5.6.0";
|
||||
|
||||
@@ -10,7 +10,7 @@ import { version } from "./_version";
|
||||
const logger = new Logger(version);
|
||||
|
||||
const allowedTransactionKeys: Array<string> = [
|
||||
"accessList", "chainId", "customData", "data", "from", "gasLimit", "gasPrice", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "to", "type", "value"
|
||||
"accessList", "ccipReadEnabled", "chainId", "customData", "data", "from", "gasLimit", "gasPrice", "maxFeePerGas", "maxPriorityFeePerGas", "nonce", "to", "type", "value"
|
||||
];
|
||||
|
||||
const forwardErrors = [
|
||||
|
||||
2
packages/address/lib.esm/_version.d.ts
vendored
2
packages/address/lib.esm/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "address/5.5.0";
|
||||
export declare const version = "address/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,2 +1,2 @@
|
||||
export const version = "address/5.5.0";
|
||||
export const version = "address/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
2
packages/address/lib/_version.d.ts
vendored
2
packages/address/lib/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "address/5.5.0";
|
||||
export declare const version = "address/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,5 +1,5 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.version = void 0;
|
||||
exports.version = "address/5.5.0";
|
||||
exports.version = "address/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"author": "Richard Moore <me@ricmoo.com>",
|
||||
"dependencies": {
|
||||
"@ethersproject/bignumber": "^5.5.0",
|
||||
"@ethersproject/bytes": "^5.5.0",
|
||||
"@ethersproject/keccak256": "^5.5.0",
|
||||
"@ethersproject/logger": "^5.5.0",
|
||||
"@ethersproject/rlp": "^5.5.0"
|
||||
"@ethersproject/bignumber": "^5.6.0",
|
||||
"@ethersproject/bytes": "^5.6.0",
|
||||
"@ethersproject/keccak256": "^5.6.0",
|
||||
"@ethersproject/logger": "^5.6.0",
|
||||
"@ethersproject/rlp": "^5.6.0"
|
||||
},
|
||||
"description": "Utilities for handling Ethereum Addresses for ethers.",
|
||||
"ethereum": "donations.ethers.eth",
|
||||
@@ -39,7 +39,7 @@
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"sideEffects": false,
|
||||
"tarballHash": "0xfa99c21467355e5473cdc8ce0e315c73cebad21c774010607622fa99f30f3b13",
|
||||
"tarballHash": "0x57eb9b8a268690eb5990a85ad9ae1ad0cb547c2741cfb5214ad03719acd27031",
|
||||
"types": "./lib/index.d.ts",
|
||||
"version": "5.5.0"
|
||||
"version": "5.6.0"
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
export const version = "address/5.5.0";
|
||||
export const version = "address/5.6.0";
|
||||
|
||||
2
packages/asm/lib.esm/_version.d.ts
vendored
2
packages/asm/lib.esm/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "asm/5.5.0";
|
||||
export declare const version = "asm/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,2 +1,2 @@
|
||||
export const version = "asm/5.5.0";
|
||||
export const version = "asm/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
2
packages/asm/lib/_version.d.ts
vendored
2
packages/asm/lib/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "asm/5.5.0";
|
||||
export declare const version = "asm/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,5 +1,5 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.version = void 0;
|
||||
exports.version = "asm/5.5.0";
|
||||
exports.version = "asm/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"author": "Richard Moore <me@ricmoo.com>",
|
||||
"dependencies": {
|
||||
"ethers": "^5.5.0"
|
||||
"ethers": "^5.6.0"
|
||||
},
|
||||
"description": "ASM libraries and tools for the Ethereum EVM.",
|
||||
"ethereum": "donations.ethers.eth",
|
||||
@@ -36,7 +36,7 @@
|
||||
"generate": "node ./generate.js",
|
||||
"test": "echo \"Error: no test specified\" && exit 1"
|
||||
},
|
||||
"tarballHash": "0x83b38ffcff16cd1e171859581851f4188ed87adc2e102d5517d9177859538a5c",
|
||||
"tarballHash": "0x00b07c395a39d0fb4a57c380af1da06afb50db477e08c8c05c3a1ba59a5e73a3",
|
||||
"types": "./lib/index.d.ts",
|
||||
"version": "5.5.0"
|
||||
"version": "5.6.0"
|
||||
}
|
||||
|
||||
@@ -1 +1 @@
|
||||
export const version = "asm/5.5.0";
|
||||
export const version = "asm/5.6.0";
|
||||
|
||||
2
packages/base64/lib.esm/_version.d.ts
vendored
2
packages/base64/lib.esm/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "base64/5.5.0";
|
||||
export declare const version = "base64/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
@@ -1,2 +1,2 @@
|
||||
export const version = "base64/5.5.0";
|
||||
export const version = "base64/5.6.0";
|
||||
//# sourceMappingURL=_version.js.map
|
||||
2
packages/base64/lib/_version.d.ts
vendored
2
packages/base64/lib/_version.d.ts
vendored
@@ -1,2 +1,2 @@
|
||||
export declare const version = "base64/5.5.0";
|
||||
export declare const version = "base64/5.6.0";
|
||||
//# sourceMappingURL=_version.d.ts.map
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user