@metamask/network-controller
Advanced tools
Comparing version 14.0.0 to 15.0.0
@@ -9,2 +9,11 @@ # Changelog | ||
## [15.0.0] | ||
### Changed | ||
- **BREAKING:** Bump dependency on `@metamask/eth-json-rpc-infura` to ^9.0.0 ([#1653](https://github.com/MetaMask/core/pull/1653)) | ||
- **BREAKING:** Bump dependency on `@metamask/eth-json-rpc-middleware` to ^12.0.0 ([#1653](https://github.com/MetaMask/core/pull/1653)) | ||
- **BREAKING:** Move from `json-rpc-engine` ^7.1.1 to `@metamask/json-rpc-engine` ^8.0.0 ([#1653](https://github.com/MetaMask/core/pull/1653)) | ||
- **BREAKING:** Bump dependency on `eth-block-tracker` to ^8.0.0 ([#1653](https://github.com/MetaMask/core/pull/1653)) | ||
- Bump dependency on `@metamask/eth-json-rpc-provider` to ^2.1.0 ([#1653](https://github.com/MetaMask/core/pull/1653)) | ||
- Move from `eth-rpc-errors` ^4.0.2 to `@metamask/rpc-errors` ^6.1.0 ([#1653](https://github.com/MetaMask/core/pull/1653)) | ||
## [14.0.0] | ||
@@ -282,3 +291,4 @@ ### Added | ||
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/network-controller@14.0.0...HEAD | ||
[Unreleased]: https://github.com/MetaMask/core/compare/@metamask/network-controller@15.0.0...HEAD | ||
[15.0.0]: https://github.com/MetaMask/core/compare/@metamask/network-controller@14.0.0...@metamask/network-controller@15.0.0 | ||
[14.0.0]: https://github.com/MetaMask/core/compare/@metamask/network-controller@13.0.1...@metamask/network-controller@14.0.0 | ||
@@ -285,0 +295,0 @@ [13.0.1]: https://github.com/MetaMask/core/compare/@metamask/network-controller@13.0.0...@metamask/network-controller@13.0.1 |
@@ -17,4 +17,4 @@ "use strict"; | ||
const eth_json_rpc_provider_1 = require("@metamask/eth-json-rpc-provider"); | ||
const json_rpc_engine_1 = require("@metamask/json-rpc-engine"); | ||
const eth_block_tracker_1 = require("eth-block-tracker"); | ||
const json_rpc_engine_1 = require("json-rpc-engine"); | ||
const types_1 = require("./types"); | ||
@@ -21,0 +21,0 @@ const SECOND = 1000; |
@@ -31,6 +31,6 @@ "use strict"; | ||
const eth_query_1 = __importDefault(require("@metamask/eth-query")); | ||
const rpc_errors_1 = require("@metamask/rpc-errors"); | ||
const swappable_obj_proxy_1 = require("@metamask/swappable-obj-proxy"); | ||
const utils_1 = require("@metamask/utils"); | ||
const assert_1 = require("assert"); | ||
const eth_rpc_errors_1 = require("eth-rpc-errors"); | ||
const uuid_1 = require("uuid"); | ||
@@ -338,3 +338,3 @@ const constants_1 = require("./constants"); | ||
} | ||
else if (error.code === eth_rpc_errors_1.errorCodes.rpc.internal) { | ||
else if (error.code === rpc_errors_1.errorCodes.rpc.internal) { | ||
updatedNetworkStatus = constants_1.NetworkStatus.Unknown; | ||
@@ -428,3 +428,3 @@ } | ||
} | ||
else if (error.code === eth_rpc_errors_1.errorCodes.rpc.internal) { | ||
else if (error.code === rpc_errors_1.errorCodes.rpc.internal) { | ||
updatedNetworkStatus = constants_1.NetworkStatus.Unknown; | ||
@@ -759,2 +759,3 @@ } | ||
const networkClient = this.getNetworkClientById(networkClientId); | ||
// @ts-expect-error TODO: Provider type alignment | ||
const ethQuery = new eth_query_1.default(networkClient.provider); | ||
@@ -908,4 +909,5 @@ return new Promise((resolve, reject) => { | ||
} | ||
// @ts-expect-error TODO: Provider type alignment | ||
__classPrivateFieldSet(this, _NetworkController_ethQuery, new eth_query_1.default(__classPrivateFieldGet(this, _NetworkController_providerProxy, "f")), "f"); | ||
}; | ||
//# sourceMappingURL=NetworkController.js.map |
import type { InfuraNetworkType } from '@metamask/controller-utils'; | ||
import type { SafeEventEmitterProvider } from '@metamask/eth-json-rpc-provider'; | ||
import type { Hex } from '@metamask/utils'; | ||
import type { PollingBlockTracker } from 'eth-block-tracker'; | ||
import type { BlockTracker as BaseBlockTracker } from 'eth-block-tracker'; | ||
export declare type Provider = SafeEventEmitterProvider; | ||
export declare type BlockTracker = PollingBlockTracker; | ||
export declare type BlockTracker = BaseBlockTracker & { | ||
checkForLatestBlock(): Promise<string>; | ||
}; | ||
/** | ||
@@ -8,0 +10,0 @@ * The type of network client that can be created. |
{ | ||
"name": "@metamask/network-controller", | ||
"version": "14.0.0", | ||
"version": "15.0.0", | ||
"description": "Provides an interface to the currently selected network via a MetaMask-compatible provider object", | ||
@@ -34,13 +34,13 @@ "keywords": [ | ||
"@metamask/controller-utils": "^5.0.2", | ||
"@metamask/eth-json-rpc-infura": "^8.1.1", | ||
"@metamask/eth-json-rpc-middleware": "^11.0.2", | ||
"@metamask/eth-json-rpc-provider": "^1.0.0", | ||
"@metamask/eth-json-rpc-infura": "^9.0.0", | ||
"@metamask/eth-json-rpc-middleware": "^12.0.0", | ||
"@metamask/eth-json-rpc-provider": "^2.1.0", | ||
"@metamask/eth-query": "^3.0.1", | ||
"@metamask/json-rpc-engine": "^7.1.1", | ||
"@metamask/rpc-errors": "^6.1.0", | ||
"@metamask/swappable-obj-proxy": "^2.1.0", | ||
"@metamask/utils": "^8.1.0", | ||
"async-mutex": "^0.2.6", | ||
"eth-block-tracker": "^7.0.1", | ||
"eth-rpc-errors": "^4.0.2", | ||
"eth-block-tracker": "^8.0.0", | ||
"immer": "^9.0.6", | ||
"json-rpc-engine": "^6.1.0", | ||
"uuid": "^8.3.2" | ||
@@ -47,0 +47,0 @@ }, |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
220594
1764
+ Added@metamask/rpc-errors@^6.1.0
+ Added@metamask/abi-utils@2.0.4(transitive)
+ Added@metamask/eth-block-tracker@9.0.3(transitive)
+ Added@metamask/eth-json-rpc-infura@9.1.0(transitive)
+ Added@metamask/eth-json-rpc-middleware@12.1.2(transitive)
+ Added@metamask/eth-json-rpc-provider@2.3.23.0.2(transitive)
+ Added@metamask/eth-sig-util@7.0.3(transitive)
+ Added@metamask/json-rpc-engine@8.0.2(transitive)
+ Added@noble/hashes@1.6.1(transitive)
+ Added@types/node@22.10.0(transitive)
+ Addedeth-block-tracker@8.1.0(transitive)
+ Addedklona@2.0.6(transitive)
+ Addedpify@5.0.0(transitive)
+ Addedundici-types@6.20.0(transitive)
- Removedeth-rpc-errors@^4.0.2
- Removedjson-rpc-engine@^6.1.0
- Removed@metamask/abi-utils@1.2.0(transitive)
- Removed@metamask/eth-json-rpc-infura@8.1.1(transitive)
- Removed@metamask/eth-json-rpc-middleware@11.0.2(transitive)
- Removed@metamask/eth-json-rpc-provider@1.0.1(transitive)
- Removed@metamask/eth-sig-util@6.0.2(transitive)
- Removed@metamask/utils@3.6.04.0.05.0.2(transitive)
- Removed@noble/hashes@1.6.0(transitive)
- Removed@scure/base@1.2.0(transitive)
- Removed@types/node@22.9.2(transitive)
- Removedclone@2.1.2(transitive)
- Removedeth-block-tracker@7.1.0(transitive)
- Removedeth-rpc-errors@4.0.3(transitive)
- Removedethjs-util@0.1.6(transitive)
- Removedjson-rpc-engine@6.1.0(transitive)
- Removedpify@3.0.0(transitive)
- Removedsuperstruct@1.0.4(transitive)
- Removedtweetnacl-util@0.15.1(transitive)
- Removedundici-types@6.19.8(transitive)
Updatedeth-block-tracker@^8.0.0