diff --git a/contracts/data/WitnetBoardData.sol b/contracts/data/WitnetBoardData.sol index c24664377..ce9e7ff8f 100644 --- a/contracts/data/WitnetBoardData.sol +++ b/contracts/data/WitnetBoardData.sol @@ -39,6 +39,11 @@ abstract contract WitnetBoardData { _; } + modifier onlyRequester(uint256 _queryId) { + require(__query(_queryId).from == msg.sender, "WitnetRequestBoard: only the requester"); + _; + } + /// Asserts the give query was actually posted before calling this method. modifier wasPosted(uint256 _queryId) { require(_queryId > 0 && _queryId <= __storage().numQueries, "WitnetRequestBoard: not yet posted"); diff --git a/contracts/impls/apps/WitnetPriceFeedsUpgradable.sol b/contracts/impls/apps/WitnetPriceFeedsUpgradable.sol index 515a640c9..52332442b 100644 --- a/contracts/impls/apps/WitnetPriceFeedsUpgradable.sol +++ b/contracts/impls/apps/WitnetPriceFeedsUpgradable.sol @@ -90,8 +90,8 @@ contract WitnetPriceFeedsUpgradable if (__storage().defaultSlaHash == 0) { settleDefaultRadonSLA(WitnetV2.RadonSLA({ numWitnesses: 5, - witnessCollateral: 15 * 10 ** 9, - witnessReward: 15 * 10 ** 7, + witnessCollateral: 20 * 10 ** 9, + witnessReward: 2 * 10 ** 8, minerCommitRevealFee: 10 ** 7, minConsensusPercentage: 51 })); diff --git a/contracts/impls/apps/WitnetRandomnessProxiable.sol b/contracts/impls/apps/WitnetRandomnessProxiable.sol index 678c3dd8c..eb6c68279 100644 --- a/contracts/impls/apps/WitnetRandomnessProxiable.sol +++ b/contracts/impls/apps/WitnetRandomnessProxiable.sol @@ -490,8 +490,8 @@ contract WitnetRandomnessProxiable settleWitnetRandomnessSLA(WitnetV2.RadonSLA({ numWitnesses: 5, minConsensusPercentage: 51, - witnessReward: 10 ** 8, - witnessCollateral: 10 ** 9, + witnessReward: 2 * 10 ** 8, + witnessCollateral: 2 * 10 ** 9, minerCommitRevealFee: 10 ** 7 })); } diff --git a/contracts/impls/core/customs/WitnetRequestBoardTrustableBase.sol b/contracts/impls/core/customs/WitnetRequestBoardTrustableBase.sol index 4a992376f..b70391bc3 100644 --- a/contracts/impls/core/customs/WitnetRequestBoardTrustableBase.sol +++ b/contracts/impls/core/customs/WitnetRequestBoardTrustableBase.sol @@ -620,8 +620,8 @@ abstract contract WitnetRequestBoardTrustableBase /// @dev or deleted. /// @param _queryId The unique identifier of a previously posted query. function readRequest(uint256 _queryId) - external view - override + public view + virtual override inStatus(_queryId, Witnet.QueryStatus.Posted) returns (Witnet.Request memory _request) { @@ -684,8 +684,8 @@ abstract contract WitnetRequestBoardTrustableBase /// @dev Fails if the `_queryId` is not in 'Reported' status. /// @param _queryId The unique query identifier function readResponse(uint256 _queryId) - external view - override + public view + virtual override inStatus(_queryId, Witnet.QueryStatus.Reported) returns (Witnet.Response memory _response) { @@ -720,8 +720,8 @@ abstract contract WitnetRequestBoardTrustableBase /// @dev Fails if the `_queryId` is not in 'Reported' status. /// @param _queryId The unique query identifier function readResponseResult(uint256 _queryId) - external view - override + public view + virtual override inStatus(_queryId, Witnet.QueryStatus.Reported) returns (Witnet.Result memory) { diff --git a/contracts/impls/core/customs/WitnetRequestBoardTrustableObscuro.sol b/contracts/impls/core/customs/WitnetRequestBoardTrustableObscuro.sol new file mode 100644 index 000000000..6164bac8c --- /dev/null +++ b/contracts/impls/core/customs/WitnetRequestBoardTrustableObscuro.sol @@ -0,0 +1,73 @@ +// SPDX-License-Identifier: MIT + +/* solhint-disable var-name-mixedcase */ + +pragma solidity >=0.7.0 <0.9.0; +pragma experimental ABIEncoderV2; + +import "../WitnetRequestBoardTrustableDefault.sol"; + +/// @title Witnet Request Board "trustable" implementation contract. +/// @notice Contract to bridge requests to Witnet Decentralized Oracle Network. +/// @dev This contract enables posting requests that Witnet bridges will insert into the Witnet network. +/// The result of the requests will be posted back to this contract by the bridge nodes too. +/// @author The Witnet Foundation +contract WitnetRequestBoardTrustableObscuro + is + WitnetRequestBoardTrustableDefault +{ + constructor( + WitnetRequestFactory _factory, + bool _upgradable, + bytes32 _versionTag, + uint256 _reportResultGasLimit + ) + WitnetRequestBoardTrustableDefault( + _factory, + _upgradable, + _versionTag, + _reportResultGasLimit + ) + {} + + // ================================================================================================================ + // --- Overrides implementation of 'IWitnetRequestBoardView' ------------------------------------------------------ + + /// @notice Retrieves the whole Request record posted to the Witnet Request Board. + /// @dev Fails if the `_queryId` is not valid or, if it has already been reported + /// @dev or deleted, or if `msg.sender` is not the actual requester. + /// @param _queryId The unique identifier of a previously posted query. + function readRequest(uint256 _queryId) + public view + virtual override + onlyRequester(_queryId) + returns (Witnet.Request memory) + { + return WitnetRequestBoardTrustableBase.readRequest(_queryId); + } + + /// Retrieves the Witnet-provided result, and metadata, to a previously posted request. + /// @dev Fails if the `_queryId` is not in 'Reported' status, or if `msg.sender` is not the actual requester. + /// @param _queryId The unique query identifier + function readResponse(uint256 _queryId) + public view + virtual override + onlyRequester(_queryId) + returns (Witnet.Response memory _response) + { + return WitnetRequestBoardTrustableBase.readResponse(_queryId); + } + + /// Retrieves the Witnet-provided CBOR-bytes result of a previously posted request. + /// @dev Fails if the `_queryId` is not in 'Reported' status, or if `msg.sender` is not the actual requester. + /// @param _queryId The unique query identifier + function readResponseResult(uint256 _queryId) + public view + virtual override + onlyRequester(_queryId) + returns (Witnet.Result memory) + { + return WitnetRequestBoardTrustableBase.readResponseResult(_queryId); + } + +} diff --git a/contracts/requests/WitnetRequestMalleableBase.sol b/contracts/requests/WitnetRequestMalleableBase.sol new file mode 100644 index 000000000..241f05ca9 --- /dev/null +++ b/contracts/requests/WitnetRequestMalleableBase.sol @@ -0,0 +1,375 @@ +// SPDX-License-Identifier: MIT + +pragma solidity >=0.7.0 <0.9.0; + +import "../libs/Witnet.sol"; +import "../patterns/Clonable.sol"; +import "../patterns/Ownable.sol"; +import "../patterns/Proxiable.sol"; + +abstract contract WitnetRequestMalleableBase + is + IWitnetRequest, + Clonable, + Ownable, + Proxiable +{ + using Witnet for *; + + event WitnessingParamsChanged( + address indexed by, + uint8 numWitnesses, + uint8 minWitnessingConsensus, + uint64 witnssingCollateral, + uint64 witnessingReward, + uint64 witnessingUnitaryFee + ); + + struct WitnetRequestMalleableBaseContext { + /// Contract owner address. + address owner; + /// Immutable bytecode template. + bytes template; + /// Current request bytecode. + bytes bytecode; + /// Current request hash. + bytes32 hash; + /// Current request witnessing params. + WitnetRequestWitnessingParams params; + } + + struct WitnetRequestWitnessingParams { + /// Number of witnesses required to be involved for solving this Witnet Data Request. + uint8 numWitnesses; + + /// Threshold percentage for aborting resolution of a request if the witnessing nodes did not arrive to a broad consensus. + uint8 minWitnessingConsensus; + + /// Amount of nanowits that a witness solving the request will be required to collateralize in the commitment transaction. + uint64 witnessingCollateral; + + /// Amount of nanowits that every request-solving witness will be rewarded with. + uint64 witnessingReward; + + /// Amount of nanowits that will be earned by Witnet miners for each each valid commit/reveal transaction they include in a block. + uint64 witnessingUnitaryFee; + } + + /// Returns current Witnet Data Request bytecode, encoded using Protocol Buffers. + function bytecode() external view override returns (bytes memory) { + return _request().bytecode; + } + + /// Returns SHA256 hash of current Witnet Data Request bytecode. + function hash() external view override returns (bytes32) { + return _request().hash; + } + + /// Sets amount of nanowits that a witness solving the request will be required to collateralize in the commitment transaction. + function setWitnessingCollateral(uint64 _witnessingCollateral) + public + virtual + onlyOwner + { + WitnetRequestWitnessingParams storage _params = _request().params; + _params.witnessingCollateral = _witnessingCollateral; + _malleateBytecode( + _params.numWitnesses, + _params.minWitnessingConsensus, + _witnessingCollateral, + _params.witnessingReward, + _params.witnessingUnitaryFee + ); + } + + /// Specifies how much you want to pay for rewarding each of the Witnet nodes. + /// @param _witnessingReward Amount of nanowits that every request-solving witness will be rewarded with. + /// @param _witnessingUnitaryFee Amount of nanowits that will be earned by Witnet miners for each each valid + /// commit/reveal transaction they include in a block. + function setWitnessingFees(uint64 _witnessingReward, uint64 _witnessingUnitaryFee) + public + virtual + onlyOwner + { + WitnetRequestWitnessingParams storage _params = _request().params; + _params.witnessingReward = _witnessingReward; + _params.witnessingUnitaryFee = _witnessingUnitaryFee; + _malleateBytecode( + _params.numWitnesses, + _params.minWitnessingConsensus, + _params.witnessingCollateral, + _witnessingReward, + _witnessingUnitaryFee + ); + } + + /// Sets how many Witnet nodes will be "hired" for resolving the request. + /// @param _numWitnesses Number of witnesses required to be involved for solving this Witnet Data Request. + /// @param _minWitnessingConsensus Threshold percentage for aborting resolution of a request if the witnessing + /// nodes did not arrive to a broad consensus. + function setWitnessingQuorum(uint8 _numWitnesses, uint8 _minWitnessingConsensus) + public + virtual + onlyOwner + { + WitnetRequestWitnessingParams storage _params = _request().params; + _params.numWitnesses = _numWitnesses; + _params.minWitnessingConsensus = _minWitnessingConsensus; + _malleateBytecode( + _numWitnesses, + _minWitnessingConsensus, + _params.witnessingCollateral, + _params.witnessingReward, + _params.witnessingUnitaryFee + ); + } + + /// Returns immutable template bytecode: actual CBOR-encoded data request at the Witnet protocol + /// level, including no witnessing parameters at all. + function template() + external view + returns (bytes memory) + { + return _request().template; + } + + /// Returns total amount of nanowits that witnessing nodes will need to collateralize all together. + function totalWitnessingCollateral() + external view + returns (uint128) + { + WitnetRequestWitnessingParams storage _params = _request().params; + return _params.numWitnesses * _params.witnessingCollateral; + } + + /// Returns total amount of nanowits that will have to be paid in total for this request to be solved. + function totalWitnessingFee() + external view + returns (uint128) + { + WitnetRequestWitnessingParams storage _params = _request().params; + return _params.numWitnesses * (2 * _params.witnessingUnitaryFee + _params.witnessingReward); + } + + /// Returns witnessing parameters of current Witnet Data Request. + function witnessingParams() + external view + returns (WitnetRequestWitnessingParams memory) + { + return _request().params; + } + + + // ================================================================================================================ + // --- 'Clonable' overriden functions ----------------------------------------------------------------------------- + + /// Deploys and returns the address of a minimal proxy clone that replicates contract + /// behaviour while using its own EVM storage. + /// @dev This function should always provide a new address, no matter how many times + /// @dev is actually called from the same `msg.sender`. + function clone() + virtual public + returns (WitnetRequestMalleableBase _instance) + { + _instance = WitnetRequestMalleableBase(_clone()); + _instance.initialize(_request().template); + Ownable(address(_instance)).transferOwnership(msg.sender); + } + + /// Deploys and returns the address of a minimal proxy clone that replicates contract + /// behaviour while using its own EVM storage. + /// @dev This function uses the CREATE2 opcode and a `_salt` to deterministically deploy + /// @dev the clone. Using the same `_salt` multiple time will revert, since + /// @dev no contract can be deployed more than once at the same address. + function cloneDeterministic(bytes32 _salt) + virtual public + returns (WitnetRequestMalleableBase _instance) + { + _instance = WitnetRequestMalleableBase(_cloneDeterministic(_salt)); + _instance.initialize(_request().template); + Ownable(address(_instance)).transferOwnership(msg.sender); + } + + function initialized() virtual override public view returns (bool) { + return _request().template.length != 0; + } + + + // ================================================================================================================ + // --- 'Initializable' overriden functions ------------------------------------------------------------------------ + + /// @dev Initializes contract's storage context. + function initialize(bytes memory _template) + virtual public + { + require(_request().template.length == 0, "WitnetRequestMalleableBase: already initialized"); + _initialize(_template); + _transferOwnership(_msgSender()); + } + + // ================================================================================================================ + // --- 'Ownable' overriden functions ------------------------------------------------------------------------------ + + /// Returns the address of the current owner. + function owner() + public view + virtual override + returns (address) + { + return _request().owner; + } + + /// @dev Transfers ownership of the contract to a new account (`newOwner`). + function _transferOwnership(address newOwner) + internal + virtual override + { + address oldOwner = _request().owner; + _request().owner = newOwner; + emit OwnershipTransferred(oldOwner, newOwner); + } + + // ================================================================================================================ + // --- 'Proxiable 'overriden functions ---------------------------------------------------------------------------- + + /// @dev Complying with EIP-1822: Universal Upgradable Proxy Standard (UUPS) + /// @dev See https://eips.ethereum.org/EIPS/eip-1822. + function proxiableUUID() + external pure + virtual override + returns (bytes32) + { + return ( + /* keccak256("io.witnet.requests.malleable") */ + 0x851d0a92a3ad30295bef33afc69d6874779826b7789386b336e22621365ed2c2 + ); + } + + + // ================================================================================================================ + // --- INTERNAL FUNCTIONS ----------------------------------------------------------------------------------------- + + /// @dev Initializes witnessing params and template bytecode. + function _initialize(bytes memory _template) + internal + { + assert(_template.length > 0); + _request().template = _template; + + WitnetRequestWitnessingParams storage _params = _request().params; + _params.numWitnesses = 2; + _params.minWitnessingConsensus = 51; + _params.witnessingCollateral = 10 ** 9; // 1 WIT + _params.witnessingReward = 5 * 10 ** 5; // 0.5 milliWITs + _params.witnessingUnitaryFee = 25 * 10 ** 4; // 0.25 milliWITs + + _malleateBytecode( + _params.numWitnesses, + _params.minWitnessingConsensus, + _params.witnessingCollateral, + _params.witnessingReward, + _params.witnessingUnitaryFee + ); + } + + /// @dev Serializes new `bytecode` by combining immutable template with given parameters. + function _malleateBytecode( + uint8 _numWitnesses, + uint8 _minWitnessingConsensus, + uint64 _witnessingCollateral, + uint64 _witnessingReward, + uint64 _witnessingUnitaryFee + ) + internal + virtual + { + require( + _witnessingReward > 0, + "WitnetRequestMalleableBase: no reward" + ); + require( + _numWitnesses >= 1 && _numWitnesses <= 127, + "WitnetRequestMalleableBase: number of witnesses out of range" + ); + require( + _minWitnessingConsensus >= 51 && _minWitnessingConsensus <= 99, + "WitnetRequestMalleableBase: witnessing consensus out of range" + ); + require( + _witnessingCollateral >= 10 ** 9, + "WitnetRequestMalleableBase: witnessing collateral below 1 WIT" + ); + + _request().bytecode = abi.encodePacked( + _request().template, + _uint64varint(bytes1(0x10), _witnessingReward), + _uint8varint(bytes1(0x18), _numWitnesses), + _uint64varint(0x20, _witnessingUnitaryFee), + _uint8varint(0x28, _minWitnessingConsensus), + _uint64varint(0x30, _witnessingCollateral) + ); + _request().hash = sha256(_request().bytecode); + emit WitnessingParamsChanged( + msg.sender, + _numWitnesses, + _minWitnessingConsensus, + _witnessingCollateral, + _witnessingReward, + _witnessingUnitaryFee + ); + } + + /// @dev Returns pointer to storage slot where State struct is located. + function _request() + internal pure + virtual + returns (WitnetRequestMalleableBaseContext storage _ptr) + { + assembly { + _ptr.slot := + /* keccak256("io.witnet.requests.malleable.context") */ + 0x375930152e1d0d102998be6e496b0cee86c9ecd0efef01014ecff169b17dfba7 + } + } + + /// @dev Encode uint64 into tagged varint. + /// @dev See https://developers.google.com/protocol-buffers/docs/encoding#varints. + /// @param t Tag + /// @param n Number + /// @return Marshaled bytes + function _uint64varint(bytes1 t, uint64 n) + internal pure + returns (bytes memory) + { + // Count the number of groups of 7 bits + // We need this pre-processing step since Solidity doesn't allow dynamic memory resizing + uint64 tmp = n; + uint64 numBytes = 2; + while (tmp > 0x7F) { + tmp = tmp >> 7; + numBytes += 1; + } + bytes memory buf = new bytes(numBytes); + tmp = n; + buf[0] = t; + for (uint64 i = 1; i < numBytes; i++) { + // Set the first bit in the byte for each group of 7 bits + buf[i] = bytes1(0x80 | uint8(tmp & 0x7F)); + tmp = tmp >> 7; + } + // Unset the first bit of the last byte + buf[numBytes - 1] &= 0x7F; + return buf; + } + + /// @dev Encode uint8 into tagged varint. + /// @param t Tag + /// @param n Number + /// @return Marshaled bytes + function _uint8varint(bytes1 t, uint8 n) + internal pure + returns (bytes memory) + { + return _uint64varint(t, uint64(n)); + } +} diff --git a/contracts/requests/WitnetRequestRandomness.sol b/contracts/requests/WitnetRequestRandomness.sol new file mode 100644 index 000000000..6a3e96888 --- /dev/null +++ b/contracts/requests/WitnetRequestRandomness.sol @@ -0,0 +1,20 @@ +// SPDX-License-Identifier: MIT + +pragma solidity >=0.7.0 <0.9.0; + +import "./WitnetRequestMalleableBase.sol"; + +contract WitnetRequestRandomness is WitnetRequestMalleableBase { + bytes internal constant _WITNET_RANDOMNESS_BYTECODE_TEMPLATE = hex"0a0f120508021a01801a0210022202100b"; + + constructor() { + initialize(bytes("")); + } + + function initialize(bytes memory) + public + virtual override + { + super.initialize(_WITNET_RANDOMNESS_BYTECODE_TEMPLATE); + } +} diff --git a/migrations/scripts/1_Create2Factory.js b/migrations/scripts/1_Create2Factory.js index 461307ab9..e93ed1fa5 100644 --- a/migrations/scripts/1_Create2Factory.js +++ b/migrations/scripts/1_Create2Factory.js @@ -13,47 +13,49 @@ module.exports = async function (deployer, network, [, from,,,,, master]) { if (!addresses[ecosystem]) addresses[ecosystem] = {} if (!addresses[ecosystem][network]) addresses[ecosystem][network] = {} - let factory - if (utils.isNullAddress(addresses[ecosystem][network]?.Create2Factory)) { - await deployer.deploy(Create2Factory, { from: master }) - factory = await Create2Factory.deployed() - addresses[ecosystem][network].Create2Factory = factory.address - if (!isDryRun) { - utils.saveAddresses(addresses) + if (addresses[ecosystem][network]?.Create2Factory !== undefined) { + let factory + if (addresses[ecosystem][network].Create2Factory === "") { + await deployer.deploy(Create2Factory, { from: master }) + factory = await Create2Factory.deployed() + addresses[ecosystem][network].Create2Factory = factory.address + if (!isDryRun) { + utils.saveAddresses(addresses) + } + } else { + factory = await Create2Factory.at(addresses[ecosystem][network].Create2Factory) + Create2Factory.address = factory.address + utils.traceHeader("Skipping 'Create2Factory'") + console.info(" > Contract address:", factory.address) + console.info() } - } else { - factory = await Create2Factory.at(addresses[ecosystem][network].Create2Factory) - Create2Factory.address = factory.address - utils.traceHeader("Skipping 'Create2Factory'") - console.info(" > Contract address:", factory.address) - console.info() - } - // Settle WitnetProxy bytecode and source code as to guarantee - // salted addresses remain as expected no matter if the solc version - // is changed in migrations/witnet.settings.js - utils.traceHeader("Defrosting 'WitnetProxy' artifact") - fs.writeFileSync( - `build/${ecosystem}/contracts/WitnetProxy.json`, - fs.readFileSync("migrations/abis/WitnetProxy.json"), - { encoding: "utf8", flag: "w" } - ) - const WitnetProxy = artifacts.require("WitnetProxy") - const metadata = JSON.parse(WitnetProxy.metadata) - console.info(" ", "> compiler: ", metadata.compiler.version) - console.info(" ", "> compilation target:", metadata.settings.compilationTarget) - console.info(" ", "> evmVersion: ", metadata.settings.evmVersion) - console.info(" ", "> optimizer: ", JSON.stringify(metadata.settings.optimizer)) + // Settle WitnetProxy bytecode and source code as to guarantee + // salted addresses remain as expected no matter if the solc version + // is changed in migrations/witnet.settings.js + utils.traceHeader("Defrosting 'WitnetProxy' artifact") + fs.writeFileSync( + `build/${ecosystem}/contracts/WitnetProxy.json`, + fs.readFileSync("migrations/abis/WitnetProxy.json"), + { encoding: "utf8", flag: "w" } + ) + const WitnetProxy = artifacts.require("WitnetProxy") + const metadata = JSON.parse(WitnetProxy.metadata) + console.info(" ", "> compiler: ", metadata.compiler.version) + console.info(" ", "> compilation target:", metadata.settings.compilationTarget) + console.info(" ", "> evmVersion: ", metadata.settings.evmVersion) + console.info(" ", "> optimizer: ", JSON.stringify(metadata.settings.optimizer)) - if (addresses[ecosystem][network]?.WitnetProxy === "") { - await deployer.deploy(WitnetProxy, { from }) - addresses[ecosystem][network].WitnetProxy = WitnetProxy.address - } else { - if (addresses[ecosystem][network]?.WitnetProxy) { - WitnetProxy.address = addresses[ecosystem][network]?.WitnetProxy + if (addresses[ecosystem][network]?.WitnetProxy === "") { + await deployer.deploy(WitnetProxy, { from }) + addresses[ecosystem][network].WitnetProxy = WitnetProxy.address + } else { + if (addresses[ecosystem][network]?.WitnetProxy) { + WitnetProxy.address = addresses[ecosystem][network]?.WitnetProxy + } + } + if (!isDryRun) { + utils.saveAddresses(addresses) } - } - if (!isDryRun) { - utils.saveAddresses(addresses) } } diff --git a/migrations/scripts/3_WitnetBytecodes.js b/migrations/scripts/3_WitnetBytecodes.js index dccaff2a2..a3100a74e 100644 --- a/migrations/scripts/3_WitnetBytecodes.js +++ b/migrations/scripts/3_WitnetBytecodes.js @@ -26,15 +26,13 @@ module.exports = async function (deployer, network, [, from]) { const artifactNames = merge(settings.artifacts.default, settings.artifacts[ecosystem], settings.artifacts[network]) const WitnetBytecodesImplementation = artifacts.require(artifactNames.WitnetBytecodes) + const create2FactoryAddr = addresses[ecosystem][network]?.Create2Factory let proxy if (utils.isNullAddress(addresses[ecosystem][network]?.WitnetBytecodes)) { - const factory = await Create2Factory.deployed() - if ( - factory && !utils.isNullAddress(factory.address) && - singletons?.WitnetBytecodes - ) { + if (!utils.isNullAddress(create2FactoryAddr) && singletons?.WitnetBytecodes) { // Deploy the proxy via a singleton factory and a salt... + const create2Factory = await Create2Factory.at(create2FactoryAddr) const bytecode = WitnetProxy.toJSON().bytecode const salt = singletons.WitnetBytecodes?.salt ? "0x" + ethUtils.setLengthLeft( @@ -44,13 +42,13 @@ module.exports = async function (deployer, network, [, from]) { ).toString("hex") : "0x0" - const proxyAddr = await factory.determineAddr.call(bytecode, salt, { from }) + const proxyAddr = await create2Factory.determineAddr.call(bytecode, salt, { from }) if ((await web3.eth.getCode(proxyAddr)).length <= 3) { // deploy instance only if not found in current network: utils.traceHeader("Singleton inception of 'WitnetBytecodes':") const balance = await web3.eth.getBalance(from) const gas = singletons.WitnetBytecodes.gas - const tx = await factory.deploy(bytecode, salt, { from, gas }) + const tx = await create2Factory.deploy(bytecode, salt, { from, gas }) utils.traceTx( tx.receipt, web3.utils.fromWei((balance - await web3.eth.getBalance(from)).toString()) diff --git a/migrations/scripts/4_WitnetRequestFactory.js b/migrations/scripts/4_WitnetRequestFactory.js index db5102a15..370fa24c5 100644 --- a/migrations/scripts/4_WitnetRequestFactory.js +++ b/migrations/scripts/4_WitnetRequestFactory.js @@ -27,15 +27,13 @@ module.exports = async function (deployer, network, [, from]) { const artifactNames = merge(settings.artifacts.default, settings.artifacts[ecosystem], settings.artifacts[network]) const WitnetRequestFactoryImplementation = artifacts.require(artifactNames.WitnetRequestFactory) + const create2FactoryAddr = addresses[ecosystem][network]?.Create2Factory let proxy if (utils.isNullAddress(addresses[ecosystem][network]?.WitnetRequestFactory)) { - const create2Factory = await Create2Factory.deployed() - if ( - create2Factory && !utils.isNullAddress(create2Factory.address) && - singletons?.WitnetRequestFactory - ) { + if (!utils.isNullAddress(create2FactoryAddr) && singletons?.WitnetRequestFactory) { // Deploy the proxy via a singleton factory and a salt... + const create2Factory = await Create2Factory.at(create2FactoryAddr) const bytecode = WitnetProxy.toJSON().bytecode const salt = singletons.WitnetRequestFactory?.salt ? "0x" + ethUtils.setLengthLeft( diff --git a/migrations/scripts/5_WitnetRequestBoard.js b/migrations/scripts/5_WitnetRequestBoard.js index 9f180baab..a7d6c1151 100644 --- a/migrations/scripts/5_WitnetRequestBoard.js +++ b/migrations/scripts/5_WitnetRequestBoard.js @@ -28,15 +28,13 @@ module.exports = async function (deployer, network, [, from, reporter]) { const artifactsName = merge(settings.artifacts.default, settings.artifacts[ecosystem], settings.artifacts[network]) const WitnetRequestBoardImplementation = artifacts.require(artifactsName.WitnetRequestBoard) + const create2FactoryAddr = addresses[ecosystem][network]?.Create2Factory let proxy - const factory = await Create2Factory.deployed() if (utils.isNullAddress(addresses[ecosystem][network]?.WitnetRequestBoard)) { - if ( - factory && !utils.isNullAddress(factory.address) && - singletons?.WitnetRequestBoard - ) { + if (!utils.isNullAddress(create2FactoryAddr) && singletons?.WitnetPriceFeeds) { // Deploy the proxy via a singleton factory and a salt... + const create2Factory = await Create2Factory.at(create2FactoryAddr) const bytecode = WitnetProxy.toJSON().bytecode const salt = singletons.WitnetRequestBoard?.salt ? "0x" + ethUtils.setLengthLeft( @@ -46,13 +44,13 @@ module.exports = async function (deployer, network, [, from, reporter]) { ).toString("hex") : "0x0" - const proxyAddr = await factory.determineAddr.call(bytecode, salt, { from }) + const proxyAddr = await create2Factory.determineAddr.call(bytecode, salt, { from }) if ((await web3.eth.getCode(proxyAddr)).length <= 3) { // deploy instance only if not found in current network: utils.traceHeader("Singleton inception of 'WitnetRequestBoard':") const balance = await web3.eth.getBalance(from) const gas = singletons.WitnetRequestBoard.gas - const tx = await factory.deploy(bytecode, salt, { from, gas }) + const tx = await create2Factory.deploy(bytecode, salt, { from, gas }) utils.traceTx( tx.receipt, web3.utils.fromWei((balance - await web3.eth.getBalance(from)).toString()) diff --git a/migrations/scripts/7_WitnetPriceFeeds.js b/migrations/scripts/7_WitnetPriceFeeds.js index 3c10eacb7..9e891e8e1 100644 --- a/migrations/scripts/7_WitnetPriceFeeds.js +++ b/migrations/scripts/7_WitnetPriceFeeds.js @@ -25,6 +25,7 @@ module.exports = async function (deployer, network, [, from]) { if (!addresses[ecosystem]) addresses[ecosystem] = {} if (!addresses[ecosystem][network]) addresses[ecosystem][network] = {} + const create2FactoryAddr = addresses[ecosystem][network]?.Create2Factory console.info() if (!isDryRun && addresses[ecosystem][network].WitnetPriceFeeds === undefined) { @@ -54,12 +55,9 @@ module.exports = async function (deployer, network, [, from]) { if (addresses[ecosystem][network]?.WitnetPriceFeedsImplementation !== undefined || isDryRun) { let proxy if (utils.isNullAddress(addresses[ecosystem][network]?.WitnetPriceFeeds)) { - const create2Factory = await Create2Factory.deployed() - if ( - create2Factory && !utils.isNullAddress(create2Factory.address) && - singletons?.WitnetPriceFeeds - ) { + if (!utils.isNullAddress(create2FactoryAddr) && singletons?.WitnetPriceFeeds) { // Deploy the proxy via a singleton factory and a salt... + const create2Factory = await Create2Factory.at(create2FactoryAddr) const bytecode = WitnetProxy.toJSON().bytecode const salt = singletons.WitnetPriceFeeds?.salt ? "0x" + ethUtils.setLengthLeft( @@ -99,7 +97,6 @@ module.exports = async function (deployer, network, [, from]) { proxy = await WitnetProxy.at(addresses[ecosystem][network].WitnetPriceFeeds) console.info(` Skipped: 'WitnetPriceFeeds' deployed at ${proxy.address}`) } - let router if (utils.isNullAddress(addresses[ecosystem][network]?.WitnetPriceFeedsImplementation)) { await deployer.deploy( diff --git a/migrations/witnet.addresses.json b/migrations/witnet.addresses.json index 0c8ffa9cc..c03fb0506 100644 --- a/migrations/witnet.addresses.json +++ b/migrations/witnet.addresses.json @@ -10,9 +10,9 @@ "WitnetRequestBoard": "0xb58D05247d16b3F1BD6B59c52f7f61fFef02BeC8", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xc71A87657b13A370594967A04b4301a3AcEAF007", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x1f35F6d6BE5Bd574b2B00Ac2Dc0BeCAfcc04Ed51", "WitnetPriceFeedsLib": "0x7A6C2Aad6b4b08De09477D0F663b8f90b0db9662", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xA9cC3101735b248964e90fA8506219A9CF0b1091", "WitnetPriceFeedsImplementation": "0xBfFA2ec6225390C517A1bEB83b27a171C6734294", "WitnetRandomnessImplementation": "0x685528FA605c31aE076e1ee1707041B7Cb356573", "WitnetRandomnessImplementationV061": "0x6Eb87EcCe6218Cd0e97299331D2aa5d2e53da5cD", @@ -60,8 +60,8 @@ "WitnetRequestBoard": "0xa6a6b2cBE9Ce5B8fF94729F1eC402efc5042AbBF", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xf6d52770453166de85B6B6260Cf22196bC460E88", - "WitnetEncodingLib": "", - "WitnetBytecodesImplementation": "", + "WitnetEncodingLib": "0x69891cE36F6dFbef4A7BdD0E95A15CBA916f206b", + "WitnetBytecodesImplementation": "0xd8875D7D3087DEec0103d47d4cE0C4a5414874E1", "WitnetPriceFeedsImplementation": "0x620e20d91C9b0e11ecAE439E7b85138DA2a1003F", "WitnetRandomnessImplementation": "0x078EE90E16e2e5332EDaA87da19d2743cD8C64DD", "WitnetRandomnessImplementationV061": "0xB0C5d40A7658b2ab28360aFa6eB5bAeb2fFe86c3", @@ -79,13 +79,14 @@ "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetRequestRandomness": "0xF1Aba51c5097487a62DA9c72fb9Aa7B0c98676C1", - "WitnetErrorsLib": "", - "WitnetEncodingLib": "", - "WitnetBytecodesImplementation": "", - "WitnetPriceFeedsImplementation": "", + "WitnetErrorsLib": "0x56E44A9f86C2e3a53e816335cBE6deaE440b0856", + "WitnetEncodingLib": "0xB68c0127e74dC705d18162621035f9782b23D609", + "WitnetBytecodesImplementation": "0xE794D90AfaAC834DBaC58A7A283548C09aB266aE", + "WitnetPriceFeedsImplementation": "0x6020665A4F6dcEFfBDb9655C8bF904C51CB94951", "WitnetRandomnessImplementation": "0xa239729c399c9eBae7fdc188A1Dbb2c4a06Cd4Bb", - "WitnetRequestBoardImplementation": "", - "WitnetRequestFactoryImplementation": "0xc42656C501623859565C6d080a7Feb1f2B72b55a" + "WitnetRequestBoardImplementation": "0xf85A3B52D306B1F4Bb5B63A84D2C4D190F45f068", + "WitnetRequestFactoryImplementation": "0x9a83a23066766991E6cA113eB425fFe806f62ecF", + "WitnetPriceFeedsLib": "0xB1D870ce58D6521A17BDBB2D209558bc605e78D6" } }, "avalanche": { @@ -99,9 +100,9 @@ "WitnetRequestBoard": "0xD9465D38f50f364b3263Cb219e58d4dB2D584530", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xf6d52770453166de85B6B6260Cf22196bC460E88", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x0e86a89D9Ae5D6182a853375F19dB23e5c600268", "WitnetPriceFeedsLib": "0xBfFA2ec6225390C517A1bEB83b27a171C6734294", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xE490b89AfADE571d8Afa158446C603D530608ceA", "WitnetPriceFeedsImplementation": "0x8762508A67e71Df04212B256E19faB1771F9a2F4", "WitnetRandomnessImplementation": "0x685528FA605c31aE076e1ee1707041B7Cb356573", "WitnetRandomnessImplementationV061": "0xD47fc24C99fD94f33bD2f33FE373b1447bB10724", @@ -190,9 +191,9 @@ "WitnetRequestBoard": "0x99a0B5eb260Fe3BfcF9d658850e3dD6d6B69183A", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0x364E2b91a4C7563288C3ccF7256BA172935CC550", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x9ebaCbe3B5b03e164E9dfd15Ad8e86697f6d5bF6", "WitnetPriceFeedsLib": "0x50AA08187D2F648Dd428784AF6489c3F12e942CC", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x71D5D7F2ed2436062946727DB84E44588F765D02", "WitnetPriceFeedsImplementation": "0x654B79823f244c2476907F21EBD20cFebC04D0A5", "WitnetRandomnessImplementation": "0xFB36b14df6D319A5A7F418C80b0700664A4f9e6a", "WitnetRandomnessImplementationV061": "0xbD804467270bCD832b4948242453CA66972860F5", @@ -209,9 +210,9 @@ "WitnetRequestBoard": "0x03E709E6422E30C033456FCde38C70A12553E468", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0x92a68143Ee3C2527C2B07e4354efAF89fd75a359", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x88e7Ab71cC18B9f6Fb091fc53Fe3Be467808E0F6", "WitnetPriceFeedsLib": "0x760C146699B76c84Cc8050f57728F2Dc374cbf25", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x2573D4d998117b3c2a5a4Ea3c216b6Ebc0039780", "WitnetPriceFeedsImplementation": "0x76ffF94D527504e90DaCB12d710590ba8227299E", "WitnetRandomnessImplementation": "0x6Af31B632A20185ff96FC47a8576a6980Cd99FEC", "WitnetRandomnessImplementationV061": "0x6023fF93A3b37791a94B15D6AEaD488933b01Db3", @@ -230,8 +231,8 @@ "WitnetRequestBoard": "0x8aB653B73a0e0552dDdce8c76F97c6AA826EFbD4", "WitnetRequestFactory": "0x83eFF90a51D7da324AE1580eab6Ee0c9D45ad509", "WitnetErrorsLib": "0x8d5Fda8c48dF35f321301e69c3c605AABCA474b1", - "WitnetEncodingLib": "", - "WitnetBytecodesImplementation": "", + "WitnetEncodingLib": "0x8B84cba430E98E3DfD18D24823B1E327188b01F3", + "WitnetBytecodesImplementation": "0x8B71361a331513023534d6A64Ce65123aa1E7B79", "WitnetPriceFeedsImplementation": "0x81f3EB9a7853F8e1357f6BB61E7BB610F73605F1", "WitnetRandomnessImplementationV061": "0x887bC8Db7D91413D1575071925Ee8d77fE2CBc81", "WitnetRequestBoardImplementation": "0x8d19a968CeAA0d31cD9E0434574C8dC5710ddBac", @@ -254,9 +255,9 @@ "WitnetRequestBoard": "0x0C4be6AA667df48de54BA174bE7948875fdf152B", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xf6d52770453166de85B6B6260Cf22196bC460E88", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x2163DBCBdbBeC066EF8d8Adab75Af8b0B9A5cfAA", "WitnetPriceFeedsLib": "0x7A6C2Aad6b4b08De09477D0F663b8f90b0db9662", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x87cB87b649A75c608402Cb9F030129510e201BB4", "WitnetPriceFeedsImplementation": "0x6bF6F65Ad0859e9Ee869DAD252a29c9daAa27449", "WitnetRandomnessImplementation": "0x0b75886DeB58F80A75E5cAF10702C5d15FA54437", "WitnetRandomnessImplementationV061": "0xa784093826e2894Ab3Db315f4e05F0F26407BBfF", @@ -281,9 +282,9 @@ "WitnetRequestBoard": "0x58D8ECe142c60f5707594a7C1D90e46eAE5AF431", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0x4874cb1732eE1167A006E0Ab047D940ACF04D771", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x3280539A77C578C3eF698f53f29CDba00eC9B72E", "WitnetPriceFeedsLib": "0xB1Ee13a85B2593D5191f3a2A08f175b1c918B9bb", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x5256D112d446Ba1d904b6BF3B2812B17336766f5", "WitnetPriceFeedsImplementation": "0x7538f6Bff94B0F7F0A0802376238Aab0D2528521", "WitnetRandomnessImplementation": "0xe145A4D3335D5F78d7e9cB6a3C1832155cB4Be01", "WitnetRandomnessImplementationV061": "0x0017A464A86f48B342Cae3b8Fe29cFCDaA7b0643", @@ -362,9 +363,9 @@ "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xEdb5535994bF19d56c30F5BEa0937232E198F671", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x632147c657743906F332EB05E5C775B738254e1b", "WitnetPriceFeedsLib": "0xC1266fA3D24f5d63E2e34633b3F829E9156be0d6", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x556eeaf0860De4Acf550Ced5D915a71673042466", "WitnetPriceFeedsImplementation": "0xdA489690BDfd6e4d76DE3b937f40342bAd281bc9", "WitnetRandomnessImplementation": "0x83587BcfD1f75B5D08c4e27F098F99783cc693cb", "WitnetRandomnessImplementationV079": "0x9597b5708CDB58fF057ca494574951Fc3d9163f7", @@ -380,12 +381,12 @@ "WitnetRandomness": "0x88888885966F8F77cC6E797aE263C4d091e44A55", "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", - "WitnetErrorsLib": "", - "WitnetEncodingLib": "", - "WitnetBytecodesImplementation": "", + "WitnetErrorsLib": "0xEb9293996Da011D95720fC791C57CE1647065b44", + "WitnetEncodingLib": "0x226633F2b74E043Ef46D22D747005cb616263629", + "WitnetBytecodesImplementation": "0x1d0203958ad87A28cecF43614A029adAb6aBf3df", "WitnetPriceFeedsImplementation": "0x79c27c0555C95DBfd38e97023c3257376aaa154d", "WitnetRandomnessImplementation": "0x92a68143Ee3C2527C2B07e4354efAF89fd75a359", - "WitnetRequestBoardImplementation": "", + "WitnetRequestBoardImplementation": "0x88e7Ab71cC18B9f6Fb091fc53Fe3Be467808E0F6", "WitnetRequestFactoryImplementation": "0x7AA219C444f68eDBD5789d89076efA8A3f09996b", "WitnetRequestRandomness": "0x217C32Cf5755aB281809f29F21c107cD0E4652B3", "WitnetPriceFeedsLib": "0x62a1b1D6E5bA031846894FC5C3609f586c78D23D" @@ -402,9 +403,9 @@ "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0x123a7AcE0879C4645b19A69c2ba8B3E4d01fBfD6", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x9bcD148e7933312240959CABA0F3ff943A8116C3", "WitnetPriceFeedsLib": "0xEeA1423D8cAf1e9440495842613Ec042046065aC", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xf66DCA7C473707EdFB50eAd488EEc15e882B59cE", "WitnetPriceFeedsImplementation": "0x3280539A77C578C3eF698f53f29CDba00eC9B72E", "WitnetRandomnessImplementation": "0x1e7e21B4b1102cf3b8bD5e110bbBdc80D43A9dEa", "WitnetRandomnessImplementationV079": "0x7A6C2Aad6b4b08De09477D0F663b8f90b0db9662", @@ -423,9 +424,9 @@ "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0x9F026F081b5E1f60d583CE380f30A0a4eF0AB97a", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0xA9cC3101735b248964e90fA8506219A9CF0b1091", "WitnetPriceFeedsLib": "0x69891cE36F6dFbef4A7BdD0E95A15CBA916f206b", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x2163DBCBdbBeC066EF8d8Adab75Af8b0B9A5cfAA", "WitnetPriceFeedsImplementation": "0xd8875D7D3087DEec0103d47d4cE0C4a5414874E1", "WitnetRandomnessImplementation": "0x9597b5708CDB58fF057ca494574951Fc3d9163f7", "WitnetRandomnessImplementationv079": "0x4874cb1732eE1167A006E0Ab047D940ACF04D771", @@ -444,9 +445,9 @@ "WitnetRequestBoard": "0x58D8ECe142c60f5707594a7C1D90e46eAE5AF431", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xa45206cC3Ae76630Cc4D47A730590Ff9B6d8Ee54", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x98DbB216138aA6a0b3ff2ae9bBdeC254398E5B2E", "WitnetPriceFeedsLib": "0xBfFA2ec6225390C517A1bEB83b27a171C6734294", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x6395d83C9Aa803498980A5ab78217785d4db7bE7", "WitnetPriceFeedsImplementation": "0x6bF6F65Ad0859e9Ee869DAD252a29c9daAa27449", "WitnetRandomnessImplementation": "0xA9cC3101735b248964e90fA8506219A9CF0b1091", "WitnetRandomnessImplementationV061": "0xeD074DA2A76FD2Ca90C1508930b4FB4420e413B0", @@ -454,10 +455,22 @@ "WitnetRequestFactoryImplementation": "0x60768ce66aF2f3957e7280c6CfC4ab9c575a7FCF" }, "kava.mainnet": { - "WitnetLib": "0x1D9c4a8f8B7b5F9B8e2641D81927f8F8Cc7fF079", + "WitnetProxy": "0xf71a184108Db1B6E7B449B88934F8a757E094353", + "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", + "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", + "WitnetPriceFeeds": "0x9999999d139bdBFbF25923ba39F63bBFc7593400", "WitnetPriceRouter": "0xD39D4d972C7E166856c4eb29E54D3548B4597F53", - "WitnetRandomness": "0x1ebD93231a7fE551E1d6405404Df34909eff4c2C", - "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a" + "WitnetRandomness": "0x51F16EF702a13fA75a0d9971e6C15f4c7a622238", + "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a", + "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", + "WitnetErrorsLib": "0x49dbaA6eE184Da1bCAba0764B5Daa363d49b3fe5", + "WitnetEncodingLib": "0xc42656C501623859565C6d080a7Feb1f2B72b55a", + "WitnetPriceFeedsLib": "0xe33bD10fb2f1C5F4c6eF4259aAd4cE8A5868c222", + "WitnetBytecodesImplementation": "0x0fa3a073f48c985151875A0979A7222615F642E4", + "WitnetPriceFeedsImplementation": "0x0Aa147F25CE8BfaA4E6B4B2CCa91f595bD732CD4", + "WitnetRandomnessImplementationV06": "0x1ebd93231a7fe551e1d6405404df34909eff4c2c", + "WitnetRequestBoardImplementation": "0xa239729c399c9eBae7fdc188A1Dbb2c4a06Cd4Bb", + "WitnetRequestFactoryImplementation": "0xF1Aba51c5097487a62DA9c72fb9Aa7B0c98676C1" } }, "kcc": { @@ -471,9 +484,9 @@ "WitnetRequestBoard": "0x58D8ECe142c60f5707594a7C1D90e46eAE5AF431", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xB5447342cA17A40e59d410b340ba412E22e36201", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x71D5D7F2ed2436062946727DB84E44588F765D02", "WitnetPriceFeedsLib": "0x65772461641A4A6E8B10c81bae1a132E04e77262", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x2Ce7843C1c2fce51DE54a06dB3516103fbde0F6D", "WitnetPriceFeedsImplementation": "0x4874cb1732eE1167A006E0Ab047D940ACF04D771", "WitnetRandomnessImplementation": "0x98DbB216138aA6a0b3ff2ae9bBdeC254398E5B2E", "WitnetRandomnessImplementationV061": "0x76c72518060952FAec3f90666F047e39E3333f7E", @@ -481,10 +494,22 @@ "WitnetRequestFactoryImplementation": "0x4374a050f808d1FF18bCcf73270daE3EdF8D0865" }, "kcc.mainnet": { - "WitnetLib": "0x1D9c4a8f8B7b5F9B8e2641D81927f8F8Cc7fF079", + "WitnetProxy": "0xe936a946FA591eCed937996Ef3df5c89d59f4dbb", + "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", + "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", + "WitnetPriceFeeds": "0x9999999d139bdBFbF25923ba39F63bBFc7593400", "WitnetPriceRouter": "0xD39D4d972C7E166856c4eb29E54D3548B4597F53", - "WitnetRandomness": "0x1ebd93231a7fe551e1d6405404df34909eff4c2c", - "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a" + "WitnetRandomness": "0x907B2481B98796786E6A9028f32ae2357a79D8Fb", + "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a", + "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", + "WitnetErrorsLib": "0xA99B485363DBAe90D17B10F988C4e1Ae895048e0", + "WitnetEncodingLib": "0xb99FA0430C73E7B82604Aa99d351d6aFdCe46A16", + "WitnetPriceFeedsLib": "0xE8487FDd172D551319A8b030c5c9C7cE5FFb7f5d", + "WitnetBytecodesImplementation": "0x6Af31B632A20185ff96FC47a8576a6980Cd99FEC", + "WitnetPriceFeedsImplementation": "0x9890ef27B5d0e5b191ee355013Dd37E221c50A9C", + "WitnetRandomnessImplementationV061": "0x1ebd93231a7fe551e1d6405404df34909eff4c2c", + "WitnetRequestBoardImplementation": "0x62a1b1D6E5bA031846894FC5C3609f586c78D23D", + "WitnetRequestFactoryImplementation": "0xc45c93083F7B97Cdb700D4D2ADE6a727E04793ff" } }, "klaytn": { @@ -498,9 +523,9 @@ "WitnetRequestBoard": "0x58D8ECe142c60f5707594a7C1D90e46eAE5AF431", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xc71A87657b13A370594967A04b4301a3AcEAF007", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x49d3f1C57C320f833FF96bd9786Ae7DB8854B680", "WitnetPriceFeedsLib": "0x65772461641A4A6E8B10c81bae1a132E04e77262", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x17189FaFd8Dda06ccc2086e12A11693ee552B807", "WitnetPriceFeedsImplementation": "0xBfFA2ec6225390C517A1bEB83b27a171C6734294", "WitnetRandomnessImplementation": "0xd6d4B24219751A7725ce972E68B1067Ee57CC85a", "WitnetRandomnessImplementationV061": "0xB4B2E2e00e9d6E5490d55623E4F403EC84c6D33f", @@ -508,10 +533,21 @@ "WitnetRequestFactoryImplementation": "0xeDA4f244FEe1D6a3EA0fB2c0Fc6b7D1c49fEF01D" }, "klaytn.mainnet": { - "WitnetLib": "0x1D9c4a8f8B7b5F9B8e2641D81927f8F8Cc7fF079", + "WitnetProxy": "0x0fa3a073f48c985151875A0979A7222615F642E4", + "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", + "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", + "WitnetPriceFeeds": "0xA99B485363DBAe90D17B10F988C4e1Ae895048e0", "WitnetPriceRouter": "0xD39D4d972C7E166856c4eb29E54D3548B4597F53", - "WitnetRandomness": "0x1ebD93231a7fE551E1d6405404Df34909eff4c2C", - "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a" + "WitnetRandomness": "0xD111C0ef9A8FA71a66E37255d255abd8879D143C", + "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a", + "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", + "WitnetErrorsLib": "0x0e4F5763f417BB13AF759da4d36af50d13F02730", + "WitnetEncodingLib": "0x217C32Cf5755aB281809f29F21c107cD0E4652B3", + "WitnetPriceFeedsLib": "0xe936a946FA591eCed937996Ef3df5c89d59f4dbb", + "WitnetBytecodesImplementation": "0x92a68143Ee3C2527C2B07e4354efAF89fd75a359", + "WitnetRandomnessImplementationV061": "0x1ebD93231a7fE551E1d6405404Df34909eff4c2C", + "WitnetRequestBoardImplementation": "0x0Aa147F25CE8BfaA4E6B4B2CCa91f595bD732CD4", + "WitnetRequestFactoryImplementation": "0xf56E739C436EA6e65A17DBfaC9D7E57062D19422" } }, "mantle": { @@ -519,7 +555,7 @@ "WitnetProxy": "0xBfFA2ec6225390C517A1bEB83b27a171C6734294", "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", "WitnetErrorsLib": "0x1b91eAB33362f10A5F803Fe3f0d181F42caFaac3", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0xF58115533e681295CC1F07A135539E72c5116855", "WitnetPriceFeedsLib": "0x6bF6F65Ad0859e9Ee869DAD252a29c9daAa27449", "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", "WitnetPriceFeeds": "0x9999999d139bdBFbF25923ba39F63bBFc7593400", @@ -527,7 +563,7 @@ "WitnetRandomness": "0x0123456fbBC59E181D76B6Fe8771953d1953B51a", "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x1f35F6d6BE5Bd574b2B00Ac2Dc0BeCAfcc04Ed51", "WitnetPriceFeedsImplementation": "0xB4f1f8E27799256ec95C5b5A8d2A5722Bd542E69", "WitnetRandomnessImplementation": "0x620e20d91C9b0e11ecAE439E7b85138DA2a1003F", "WitnetRequestBoardImplementation": "0xAa3BE012baab697c1AEAC34A96bb16aa381FA7F7", @@ -537,7 +573,7 @@ "WitnetProxy": "0x0Dd81412825b9C3960195ab47F14dFa9Fd70e36e", "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", "WitnetErrorsLib": "0x1225A47bC743199dFef9FEEf065b3B76695AaaaC", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x6469d3180f3D59424544AeC6d3CdBE72939a85aB", "WitnetPriceFeedsLib": "0xe33bD10fb2f1C5F4c6eF4259aAd4cE8A5868c222", "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", "WitnetPriceFeeds": "0x9999999d139bdBFbF25923ba39F63bBFc7593400", @@ -545,7 +581,7 @@ "WitnetRandomness": "0x0123456fbBC59E181D76B6Fe8771953d1953B51a", "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xE794D90AfaAC834DBaC58A7A283548C09aB266aE", "WitnetPriceFeedsImplementation": "0x4756097b9184327713D07b3ac4C2a898468220B1", "WitnetRandomnessImplementation": "0x92a68143Ee3C2527C2B07e4354efAF89fd75a359", "WitnetRequestBoardImplementation": "0x3eA2fa27D997A938925299f91e49215218Ec4f7d", @@ -563,9 +599,9 @@ "WitnetRequestBoard": "0xF99883aa51Fb76E37De6aC37854230d2337D2752", "WitnetRequestFactory": "0x693cC8829Cb9AC14F75E6EbE5878652817C9e6a4", "WitnetErrorsLib": "0x34AD22616E4FfED3EB1e9580C9D7156E1bF8ea7C", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x3EE6CbceEa1837737F86ce1D597fDd9390065Bdc", "WitnetPriceFeedsLib": "0xaB7FEec38465EA6E1Cf216E188F3Bd11355824dc", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x0C53d1765E4E866B468Af8A816eCD051Cf228abb", "WitnetPriceFeedsImplementation": "0xD62848a74c0d08BA233D625d8691ea5Fee7d7719", "WitnetRandomnessImplementation": "0xde9988f1397C0a7D4887707ec8A2Ea265D4E0572", "WitnetRandomnessImplementationV061": "0xa254632ae454bae18ff0221c2040aa387f044f0e", @@ -573,10 +609,21 @@ "WitnetRequestFactoryImplementation": "0xf1fb7170cB8832213Fb4C506f883bca0a910861D" }, "meter.mainnet": { - "WitnetLib": "0x60507Ef497EC61d407cD6Fa1c65FE820620bfA88", + "WitnetProxy": "0x649ceb7cDdaD7D5DAE6494F234c3D14efF5a9908", + "Create2Factory": "0x6Cf3F0249983d8B45F73a8b1d0483319a94Cb663", + "WitnetBytecodes": "0x9da8EB78393d008a9460F5e61883F1516365388A", + "WitnetPriceFeeds": "0xD69CE1eC9EC1871ECB4A14644ce0eA9E4c10b765", "WitnetPriceRouter": "0xA0Ea8C99159843afdAE9eD092E8eaec0368e8A20", "WitnetRandomness": "0xE189B1D26dAAB45cd344452f29Db8E93B5C7FaF1", - "WitnetRequestBoard": "0x4e645446799776B9670D18E1ecBCad059987eaCa" + "WitnetRequestBoard": "0x4e645446799776B9670D18E1ecBCad059987eaCa", + "WitnetRequestFactory": "0x2ab9B6FcC1A4A9Cc9b73f0299F0D071FD8fd6700", + "WitnetErrorsLib": "0x5cFa7a99b291A5A9A1B4E37584895EA7bB6e7dB3", + "WitnetEncodingLib": "0xADAD6b7e9A1B13b4eca5C629bfdD159B92B82adE", + "WitnetPriceFeedsLib": "0x4A4caCaFAA7c9dFF377e784FEA5a02B3F0bb7022", + "WitnetBytecodesImplementation": "0xB0032e41bD6628443e81Ac06039104b911ef465c", + "WitnetPriceFeedsImplementation": "0x0ebE395aD5052F6Cea7b7Ee7773Bc95F5086D57c", + "WitnetRequestBoardImplementation": "0xF2699144feE0c2Df40199b4Bc3107f43f95337D8", + "WitnetRequestFactoryImplementation": "0xb698F75F432C40eD658ed500FF8feFC2794f5eC5" } }, "metis": { @@ -590,9 +637,9 @@ "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xc229345B9B95515C69A64842182e37cAdB52A00d", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0xCFf84e16db3c705aD3C6e96b5575ab9111C874B9", "WitnetPriceFeedsLib": "0x4a0264714E368A6888c5D755F47Bd924549Fd625", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xd3E293c5Be8a742A94F7E3092Ce9F297E651De02", "WitnetPriceFeedsImplementation": "0x88a456C0Bd557DDA942FBc1DB86C0E35c529A6AE", "WitnetRandomnessImplementation": "0x4326d5b067EC4Bb5c2F71909E278Def8e4906B19", "WitnetRandomnessImplementationV079": "0x7A6C2Aad6b4b08De09477D0F663b8f90b0db9662", @@ -617,9 +664,9 @@ "WitnetRequestBoard": "0x02Cd4089679EAA9431a88170fd784e7dE78A2425", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0x2163DBCBdbBeC066EF8d8Adab75Af8b0B9A5cfAA", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0xA7952bc98AB11b95aa51E52ae61d017D0F084eB8", "WitnetPriceFeedsLib": "0x6f0da7F65Aaa090C48B371ADEfA1997e4e3cE39a", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xe145A4D3335D5F78d7e9cB6a3C1832155cB4Be01", "WitnetPriceFeedsImplementation": "0x2F0912fa566B5B3215e746Dc108d85fDd4A8113A", "WitnetRandomnessImplementation": "0xcf9F6DD90221d5A23a6c4E2252bF690acdf6eedC", "WitnetRandomnessImplementationv079": "0x65772461641A4A6E8B10c81bae1a132E04e77262", @@ -633,14 +680,26 @@ "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a" }, "moonbeam.mainnet": { - "WitnetLib": "0x1D9c4a8f8B7b5F9B8e2641D81927f8F8Cc7fF079", + "WitnetProxy": "0xD111C0ef9A8FA71a66E37255d255abd8879D143C", + "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", + "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", + "WitnetPriceFeeds": "0x9999999d139bdBFbF25923ba39F63bBFc7593400", "WitnetPriceRouter": "0xD39D4d972C7E166856c4eb29E54D3548B4597F53", - "WitnetRandomness": "0x1ebD93231a7fE551E1d6405404Df34909eff4c2C", - "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a" + "WitnetRandomness": "0xc2e45B0Cd46d5069a76ea387b76A5D25d1f2b31B", + "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a", + "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", + "WitnetErrorsLib": "0xe936a946FA591eCed937996Ef3df5c89d59f4dbb", + "WitnetEncodingLib": "0xA99B485363DBAe90D17B10F988C4e1Ae895048e0", + "WitnetPriceFeedsLib": "0xE8487FDd172D551319A8b030c5c9C7cE5FFb7f5d", + "WitnetBytecodesImplementation": "0xC467B6E0F700D3E044C9F20BB76957eEC0B33c8C", + "WitnetPriceFeedsImplementation": "0x5545EFE72ACfB823d4B7059bB9BfB2CC639759D6", + "WitnetRandomnessImplementationV061": "0x1ebD93231a7fE551E1d6405404Df34909eff4c2C", + "WitnetRequestBoardImplementation": "0x79c27c0555C95DBfd38e97023c3257376aaa154d", + "WitnetRequestFactoryImplementation": "0x760C146699B76c84Cc8050f57728F2Dc374cbf25" } }, - "okxchain": { - "okxchain.testnet": { + "okx": { + "okx.okxchain.testnet": { "WitnetProxy": "0x1b91eAB33362f10A5F803Fe3f0d181F42caFaac3", "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", @@ -650,20 +709,37 @@ "WitnetRequestBoard": "0x58D8ECe142c60f5707594a7C1D90e46eAE5AF431", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xf6d52770453166de85B6B6260Cf22196bC460E88", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0xd8875D7D3087DEec0103d47d4cE0C4a5414874E1", "WitnetPriceFeedsLib": "0x6dc0E2AC80550F901cd4d5F5a4C48333A0ca97Ee", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x12E5FBdaB02cC2336114353CA7BE9e2cc8E4Cc25", "WitnetPriceFeedsImplementation": "0x7A6C2Aad6b4b08De09477D0F663b8f90b0db9662", "WitnetRandomnessImplementation": "0x078EE90E16e2e5332EDaA87da19d2743cD8C64DD", "WitnetRandomnessImplementationV061": "0xeD074DA2A76FD2Ca90C1508930b4FB4420e413B0", "WitnetRequestBoardImplementation": "0x20f4B1793bb81FFa357E1705AD954BdC232Edc00", "WitnetRequestFactoryImplementation": "0x364E2b91a4C7563288C3ccF7256BA172935CC550" }, - "okxchain.mainnet": { + "okx.okxchain.mainnet": { "WitnetLib": "0x1D9c4a8f8B7b5F9B8e2641D81927f8F8Cc7fF079", "WitnetPriceRouter": "0xD39D4d972C7E166856c4eb29E54D3548B4597F53", "WitnetRandomness": "0x1ebD93231a7fE551E1d6405404Df34909eff4c2C", "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a" + }, + "okx.x1.sepolia": { + "WitnetProxy": "0x078EE90E16e2e5332EDaA87da19d2743cD8C64DD", + "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", + "WitnetErrorsLib": "0x1b91eAB33362f10A5F803Fe3f0d181F42caFaac3", + "WitnetEncodingLib": "", + "WitnetPriceFeedsLib": "0x65772461641A4A6E8B10c81bae1a132E04e77262", + "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", + "WitnetPriceFeeds": "0x9999999d139bdBFbF25923ba39F63bBFc7593400", + "WitnetPriceRouter": "0x6dc0E2AC80550F901cd4d5F5a4C48333A0ca97Ee", + "WitnetRandomness": "0x60768ce66aF2f3957e7280c6CfC4ab9c575a7FCF", + "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", + "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", + "WitnetBytecodesImplementation": "0xc71A87657b13A370594967A04b4301a3AcEAF007", + "WitnetPriceFeedsImplementation": "0x7A6C2Aad6b4b08De09477D0F663b8f90b0db9662", + "WitnetRequestBoardImplementation": "0xeDA4f244FEe1D6a3EA0fB2c0Fc6b7D1c49fEF01D", + "WitnetRequestFactoryImplementation": "" } }, "optimism": { @@ -704,9 +780,9 @@ "WitnetRequestBoard": "0x58D8ECe142c60f5707594a7C1D90e46eAE5AF431", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xA7389B84D6ABC46b40e88aAD2bbDAf9921649E9E", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x8774D2EC1dC061e1ea35f15B0B06bA9FDd9914f1", "WitnetPriceFeedsLib": "0xA149B0ED1D7d506AAB4B48275B9F761336aD916A", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xD4548Ea3Ee0625E135d9534c1B075050B319Be82", "WitnetPriceFeedsImplementation": "0x632147c657743906F332EB05E5C775B738254e1b", "WitnetRandomnessImplementation": "0xD7C67eA4BFB2e85b5a8a07E295c640F2d1811e41", "WitnetRandomnessImplementationv079": "0x24Cc52D0603F161E16c3DB29Da4c2bCc07d17C4b", @@ -723,9 +799,9 @@ "WitnetRequestBoard": "0xd653fbd7c736838289262F0F41A458f35393C88a", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0x1225A47bC743199dFef9FEEf065b3B76695AaaaC", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0x6c3FD0dD07dd67c4FFfDE297453CB5A4E316f439", "WitnetPriceFeedsLib": "0xa239729c399c9eBae7fdc188A1Dbb2c4a06Cd4Bb", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0x5211De36aC1756742B4520466604bCab34781866", "WitnetPriceFeedsImplementation": "0xf56E739C436EA6e65A17DBfaC9D7E57062D19422", "WitnetRandomnessImplementation": "0xF1Aba51c5097487a62DA9c72fb9Aa7B0c98676C1", "WitnetRandomnessImplementationv061": "0xc8c0d4dB2D7801D6E2A863934597cFD31689f7D5", @@ -878,6 +954,23 @@ "WitnetRequestFactoryImplementation": "0x4743325168af9195Aa5b25e491E9bE87d87E7F93" } }, + "ten": { + "ten.testnet": { + "Create2Factory": "0xDe312a6f7fA35320E8DD109c8ea42e82806DC45b", + "WitnetBytecodes": "0x0000000e3a3d22d7510B36BdC88994dab11eadc8", + "WitnetPriceFeeds": "0x9999999d139bdBFbF25923ba39F63bBFc7593400", + "WitnetPriceRouter": "0xE490b89AfADE571d8Afa158446C603D530608ceA", + "WitnetRequestBoard": "0x777777772C24e6CD34B464D1d71616C444254537", + "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", + "WitnetErrorsLib": "0x6bF6F65Ad0859e9Ee869DAD252a29c9daAa27449", + "WitnetEncodingLib": "0xB4f1f8E27799256ec95C5b5A8d2A5722Bd542E69", + "WitnetPriceFeedsLib": "0x9597b5708CDB58fF057ca494574951Fc3d9163f7", + "WitnetBytecodesImplementation": "0xdC101573cB42EB7006Ad6C7E08ce8C91fEAcB62C", + "WitnetPriceFeedsImplementation": "0x8684d396366C21AA01B120F69df2070f840aC134", + "WitnetRequestBoardImplementation": "0xA9cC3101735b248964e90fA8506219A9CF0b1091", + "WitnetRequestFactoryImplementation": "0xF58115533e681295CC1F07A135539E72c5116855" + } + }, "ultron": { "ultron.testnet": { "WitnetProxy": "0x4374a050f808d1FF18bCcf73270daE3EdF8D0865", @@ -889,9 +982,9 @@ "WitnetRequestBoard": "0x58D8ECe142c60f5707594a7C1D90e46eAE5AF431", "WitnetRequestFactory": "0x1111111FDE7dC956E3d7922Bc779D9E2349Afb63", "WitnetErrorsLib": "0xeDA4f244FEe1D6a3EA0fB2c0Fc6b7D1c49fEF01D", - "WitnetEncodingLib": "", + "WitnetEncodingLib": "0xA14a1fD9b1C6023f87f3A7E97DbdFdf1a9413D0A", "WitnetPriceFeedsLib": "0x9f9bAB64229680E170835BC9cC1c96F2C63f7d16", - "WitnetBytecodesImplementation": "", + "WitnetBytecodesImplementation": "0xcf9F6DD90221d5A23a6c4E2252bF690acdf6eedC", "WitnetPriceFeedsImplementation": "0x50AA08187D2F648Dd428784AF6489c3F12e942CC", "WitnetRandomnessImplementation": "0x07024BBdFbE0b7560A0f5B49745A372e15954d08", "WitnetRandomnessImplementationV061": "0xeD074DA2A76FD2Ca90C1508930b4FB4420e413B0", diff --git a/migrations/witnet.settings.js b/migrations/witnet.settings.js index 8ff8e66cf..1f73fa444 100644 --- a/migrations/witnet.settings.js +++ b/migrations/witnet.settings.js @@ -16,6 +16,9 @@ module.exports = { mantle: { WitnetRequestBoard: "WitnetRequestBoardTrustableOvm2", }, + "okx.x1.sepolia": { + WitnetBytecodes: "WitnetBytecodesNoSha256", + }, optimism: { WitnetRequestBoard: "WitnetRequestBoardTrustableOvm2", }, @@ -34,6 +37,9 @@ module.exports = { "syscoin.rollux.testnet": { WitnetRequestBoard: "WitnetRequestBoardTrustableOvm2", }, + ten: { + WitnetRequestBoard: "WitnetRequestBoardTrustableObscuro", + }, }, compilers: { default: { @@ -124,7 +130,7 @@ module.exports = { /* _reportResultGasLimit */ 115000, ], }, - okxchain: { + okx: { WitnetRequestBoard: [ /* _reportResultGasLimit */ 145000, ], @@ -475,6 +481,11 @@ module.exports = { port: 9526, network_id: 2222, skipDryRun: true, + verify: { + apiKey: "MY_API_KEY", + apiUrl: "https://kavascan.com/api", + browserURL: "https://kavascan.com/", + }, }, }, kcc: { @@ -496,6 +507,11 @@ module.exports = { network_id: 321, gasPrice: 10 ** 10, skipDryRun: true, + verify: { + apiKey: "MY_API_KEY", + apiUrl: "https://scan.kcc.io/api", + browserURL: "https://scan.kcc.io/", + }, }, }, klaytn: { @@ -592,19 +608,25 @@ module.exports = { gasPrice: 3 * 10 ** 9, }, }, - okxchain: { - "okxchain.testnet": { + okx: { + "okx.okxchain.testnet": { host: "localhost", port: 8528, network_id: 65, skipDryRun: true, }, - "okxchain.mainnet": { + "okx.okxchain.mainnet": { host: "localhost", port: 9528, network_id: 66, skipDryRun: true, }, + "okx.x1.sepolia": { + host: "localhost", + port: 8505, + network_id: 195, + skipDryRun: true, + }, }, optimism: { "optimism.goerli": { @@ -734,6 +756,16 @@ module.exports = { }, }, }, + ten: { + "ten.testnet": { + host: "localhost", + port: 8504, + network_id: 443, + skipDryRun: true, + gas: 6000000, + gasPrice: 10, + }, + }, ultron: { "ultron.testnet": { host: "localhost", diff --git a/package.json b/package.json index fb87efad1..51a67e72c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "witnet-solidity-bridge", - "version": "0.7.16", + "version": "0.7.17", "description": "Witnet Solidity Bridge contracts for EVM-compatible chains", "main": "", "scripts": {