Skip to content

Commit fe2f0f7

Browse files
committed
Updated dist files.
1 parent 9f20258 commit fe2f0f7

23 files changed

+152
-50
lines changed

CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,11 @@ Changelog
33

44
This change log is managed by `scripts/cmds/update-versions` but may be manually updated.
55

6-
ethers/v5.0.6 (2020-07-14 22:56)
6+
ethers/v5.0.6 (2020-07-16 05:35)
77
--------------------------------
88

9+
- Longer Etherscan throttle slot interval. ([9f20258](https://github.com/ethers-io/ethers.js/commit/9f20258d5d39cd901d2078275323071eb0f3505b))
10+
- Fixed ENS overrides for the default provider. ([#959](https://github.com/ethers-io/ethers.js/issues/959); [63dd3d4](https://github.com/ethers-io/ethers.js/commit/63dd3d4682b564445948988243fa9139c598587b))
911
- Added Retry-After support and adjustable slot interval to fetchJson. ([7d43545](https://github.com/ethers-io/ethers.js/commit/7d435453039f009b339d835ddee47e35a843711b))
1012
- Added initial throttling support. ([#139](https://github.com/ethers-io/ethers.js/issues/139), [#904](https://github.com/ethers-io/ethers.js/issues/904), [#926](https://github.com/ethers-io/ethers.js/issues/926); [88c7eae](https://github.com/ethers-io/ethers.js/commit/88c7eaed061ae9a6798733a97e4e87011d36b8e7))
1113
- Use status code 1000 on WebSocket hangup for compatibility. ([588f64c](https://github.com/ethers-io/ethers.js/commit/588f64c760ee49bfb5109bfbaafb4beafe41c52a))

packages/ethers/dist/ethers-all.esm.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/ethers/dist/ethers-all.umd.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/ethers/dist/ethers.esm.js

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19185,8 +19185,12 @@ const version$k = "networks/5.0.2";
1918519185

1918619186
"use strict";
1918719187
const logger$o = new Logger(version$k);
19188+
;
19189+
function isRenetworkable(value) {
19190+
return (value && typeof (value.renetwork) === "function");
19191+
}
1918819192
function ethDefaultProvider(network) {
19189-
return function (providers, options) {
19193+
const func = function (providers, options) {
1919019194
if (options == null) {
1919119195
options = {};
1919219196
}
@@ -19230,14 +19234,22 @@ function ethDefaultProvider(network) {
1923019234
}
1923119235
return providerList[0];
1923219236
};
19237+
func.renetwork = function (network) {
19238+
return ethDefaultProvider(network);
19239+
};
19240+
return func;
1923319241
}
1923419242
function etcDefaultProvider(url, network) {
19235-
return function (providers, options) {
19243+
const func = function (providers, options) {
1923619244
if (providers.JsonRpcProvider) {
1923719245
return new providers.JsonRpcProvider(url, network);
1923819246
}
1923919247
return null;
1924019248
};
19249+
func.renetwork = function (network) {
19250+
return etcDefaultProvider(url, network);
19251+
};
19252+
return func;
1924119253
}
1924219254
const homestead = {
1924319255
chainId: 1,
@@ -19356,12 +19368,23 @@ function getNetwork(network) {
1935619368
if (network.chainId !== 0 && network.chainId !== standard.chainId) {
1935719369
logger$o.throwArgumentError("network chainId mismatch", "network", network);
1935819370
}
19371+
// @TODO: In the next major version add an attach function to a defaultProvider
19372+
// class and move the _defaultProvider internal to this file (extend Network)
19373+
let defaultProvider = network._defaultProvider || null;
19374+
if (defaultProvider == null && standard._defaultProvider) {
19375+
if (isRenetworkable(standard._defaultProvider)) {
19376+
defaultProvider = standard._defaultProvider.renetwork(network);
19377+
}
19378+
else {
19379+
defaultProvider = standard._defaultProvider;
19380+
}
19381+
}
1935919382
// Standard Network (allow overriding the ENS address)
1936019383
return {
1936119384
name: network.name,
1936219385
chainId: standard.chainId,
1936319386
ensAddress: (network.ensAddress || standard.ensAddress || null),
19364-
_defaultProvider: (network._defaultProvider || standard._defaultProvider || null)
19387+
_defaultProvider: defaultProvider
1936519388
};
1936619389
}
1936719390

@@ -22306,6 +22329,7 @@ class EtherscanProvider extends BaseProvider {
2230622329
});
2230722330
const connection = {
2230822331
url: url,
22332+
throttleSlotInterval: 1000,
2230922333
throttleCallback: (attempt, url) => {
2231022334
if (this.apiKey === defaultApiKey$1) {
2231122335
showThrottleMessage();
@@ -22492,6 +22516,7 @@ class EtherscanProvider extends BaseProvider {
2249222516
});
2249322517
const connection = {
2249422518
url: url,
22519+
throttleSlotInterval: 1000,
2249522520
throttleCallback: (attempt, url) => {
2249622521
if (this.apiKey === defaultApiKey$1) {
2249722522
showThrottleMessage();

packages/ethers/dist/ethers.esm.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/ethers/dist/ethers.umd.js

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20943,8 +20943,12 @@
2094320943

2094420944

2094520945
var logger = new lib.Logger(_version$E.version);
20946+
;
20947+
function isRenetworkable(value) {
20948+
return (value && typeof (value.renetwork) === "function");
20949+
}
2094620950
function ethDefaultProvider(network) {
20947-
return function (providers, options) {
20951+
var func = function (providers, options) {
2094820952
if (options == null) {
2094920953
options = {};
2095020954
}
@@ -20988,14 +20992,22 @@
2098820992
}
2098920993
return providerList[0];
2099020994
};
20995+
func.renetwork = function (network) {
20996+
return ethDefaultProvider(network);
20997+
};
20998+
return func;
2099120999
}
2099221000
function etcDefaultProvider(url, network) {
20993-
return function (providers, options) {
21001+
var func = function (providers, options) {
2099421002
if (providers.JsonRpcProvider) {
2099521003
return new providers.JsonRpcProvider(url, network);
2099621004
}
2099721005
return null;
2099821006
};
21007+
func.renetwork = function (network) {
21008+
return etcDefaultProvider(url, network);
21009+
};
21010+
return func;
2099921011
}
2100021012
var homestead = {
2100121013
chainId: 1,
@@ -21114,12 +21126,23 @@
2111421126
if (network.chainId !== 0 && network.chainId !== standard.chainId) {
2111521127
logger.throwArgumentError("network chainId mismatch", "network", network);
2111621128
}
21129+
// @TODO: In the next major version add an attach function to a defaultProvider
21130+
// class and move the _defaultProvider internal to this file (extend Network)
21131+
var defaultProvider = network._defaultProvider || null;
21132+
if (defaultProvider == null && standard._defaultProvider) {
21133+
if (isRenetworkable(standard._defaultProvider)) {
21134+
defaultProvider = standard._defaultProvider.renetwork(network);
21135+
}
21136+
else {
21137+
defaultProvider = standard._defaultProvider;
21138+
}
21139+
}
2111721140
// Standard Network (allow overriding the ENS address)
2111821141
return {
2111921142
name: network.name,
2112021143
chainId: standard.chainId,
2112121144
ensAddress: (network.ensAddress || standard.ensAddress || null),
21122-
_defaultProvider: (network._defaultProvider || standard._defaultProvider || null)
21145+
_defaultProvider: defaultProvider
2112321146
};
2112421147
}
2112521148
exports.getNetwork = getNetwork;
@@ -25042,6 +25065,7 @@
2504225065
});
2504325066
connection = {
2504425067
url: url,
25068+
throttleSlotInterval: 1000,
2504525069
throttleCallback: function (attempt, url) {
2504625070
if (_this.apiKey === defaultApiKey) {
2504725071
formatter.showThrottleMessage();
@@ -25264,6 +25288,7 @@
2526425288
});
2526525289
var connection = {
2526625290
url: url,
25291+
throttleSlotInterval: 1000,
2526725292
throttleCallback: function (attempt, url) {
2526825293
if (_this.apiKey === defaultApiKey) {
2526925294
formatter.showThrottleMessage();

packages/ethers/dist/ethers.umd.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/ethers/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"scripts": {
5050
"test": "echo \"Error: no test specified\" && exit 1"
5151
},
52-
"tarballHash": "0x0c02e224b11fb85cf79b867a703cb5a721b5eb908c09090ecf09e8ca74fccae7",
52+
"tarballHash": "0x5cbf72bd9673e75ea995c21e8f0bd9acf2173e13d38417206b955c146581fc5d",
5353
"types": "./lib/index.d.ts",
5454
"version": "5.0.6"
5555
}

packages/networks/lib.esm/index.js

Lines changed: 26 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/networks/lib.esm/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)