Skip to content
This repository has been archived by the owner on Aug 12, 2024. It is now read-only.

Chore/x1.sepolia #340

Merged
merged 9 commits into from
May 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
61 changes: 45 additions & 16 deletions migrations/addresses.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
"EthUsdPriceFeed": "0x94E4851bdb089Af8D4b2D2f3528A24f36D3E8d7D",
"WitnetPriceFeedBypass": "0xA8767A6EA3099De344499B35f725A38E3cD15562"
},
"ethereum.sepolia": {
"EthUsdPriceFeed": "0x50f7cECd06b6377F952b6c2B5a891624F4C7b5b0",
"WitnetPriceFeedBypass": "0xd6d4B24219751A7725ce972E68B1067Ee57CC85a"
},
"ethereum.mainnet": {
"EthUsdPriceFeed": "0x0Dd81412825b9C3960195ab47F14dFa9Fd70e36e"
}
Expand Down Expand Up @@ -245,7 +249,6 @@
"DaiUsdPriceFeed": "0x1834f2e32B06f5D3F06bA0219E76FBb7Cc6F9609",
"EthUsdPriceFeed": "0xCBF7E1FC3C44b1fC0B273E6F1a15b261e1b989CA",
"KcsUsdtPriceFeed": "0xB586E0A26DB6b0eabbB63e2437Bec2e4DCE15aF2",
"KswUsdPriceFeed": "0x7cB64F086a288F5871C8E154eA15F72E5097d09b",
"MjtKcsPriceFeed": "0x98E254ee8835e1612Fcbe85a27c65828cdD0Eccd",
"SaxUsdtPriceFeed": "0xD93538Ff593250acA675C8821E5d3e8a92a0D247",
"UsdcUsdPriceFeed": "0xB158e29727C2E7cF16fC1ccf0fd4Fc883aFF0C0b",
Expand All @@ -257,10 +260,9 @@
"BtcUsdPriceFeed": "0x30e7D86b3DcdC0CC90509b1F7C27eA8e5481FAc5",
"DaiUsdPriceFeed": "0x5832e99368877a63dd1c2cea941C2b43E1F6b16A",
"EthUsdPriceFeed": "0x49dbaA6eE184Da1bCAba0764B5Daa363d49b3fe5",
"KcsUsdtPriceFeed": "0x5FB499336aee67EC1183F49A8265CC3E2599C2ae",
"KswUsdPriceFeed": "0x0e4F5763f417BB13AF759da4d36af50d13F02730",
"MjtKcsPriceFeed": "0xF1Aba51c5097487a62DA9c72fb9Aa7B0c98676C1",
"SaxUsdtPriceFeed": "0xa239729c399c9eBae7fdc188A1Dbb2c4a06Cd4Bb",
"KcsUsdtPriceFeed": "",
"MjtKcsPriceFeed": "",
"SaxUsdtPriceFeed": "",
"UsdcUsdPriceFeed": "0xf56E739C436EA6e65A17DBfaC9D7E57062D19422",
"UsdtUsdPriceFeed": "0x0Aa147F25CE8BfaA4E6B4B2CCa91f595bD732CD4"
}
Expand Down Expand Up @@ -304,13 +306,24 @@
},
"meter": {
"meter.testnet": {
"BtcUsdPriceFeed": "0x6D071177F2399Ee362f56B52e130abB1679a5D41",
"EthUsdPriceFeed": "0x86790eBE0960A11B8dFF195a1CC2e9A0861cE176",
"MtrgUsdPriceFeed": "0x49498A382c7B15681D092487Aa85338f7C9C2C48",
"MtrgUsdtPriceFeed": "0x68529970B6055998d9911320E3dBB29dD9406849",
"MtrUsdtPriceFeed": "0x94ECbA85dcE3679a1FD737964e974e63E2db91AF",
"UsdcUsdPriceFeed": "0xDB0dE4980627e958813fEFA5746C75a43da462Bb",
"UsdtUsdPriceFeed": "0xa98CB2940352d677a914C230212bc1bE7AF0D884",
"WitnetPriceFeedBypass": "0x7D0c8Fc63104B33d26F5734Ebc986E630DC7e004"
},
"meter.mainnet": {
"MtrgUsdtPriceFeed": "0x3f9e2631F94503dCFaB269D3E50A0C57e0EC31DC",
"MtrUsdtPriceFeed": "0x76802C755E89E2B33f8d0e5A877A68dCFE5cf5f2"
"BtcUsdPriceFeed": "0x015451c15A513cAEb73AA48765Aee27F72e58450",
"EthUsdPriceFeed": "0x129F4A4C4d2a45163357057E089C9d5d0F2e59b0",
"MtrgUsdPriceFeed": "0x51dd746D7DEa5623675Ae6521B8E5eeB7c556B88",
"MtrgUsdtPriceFeed": "0x01CDAdA341f905FE96468c5A57e2891a5653eD1c",
"MtrUsdtPriceFeed": "0x3bE447FF48e3bF11B15020F9D1ad4a54FBC4787f",
"UsdcUsdPriceFeed": "0xBf7ce305a505817aA6D7bbf4511cFB00F27d3CE4",
"UsdtUsdPriceFeed": "0x39C851Ca0FB448761408B1e71742106D9652b19E",
"WitnetPriceFeedBypass": "0xDb4595e22bb826236cd88740fB075133a2De035E"
}
},
"metis": {
Expand Down Expand Up @@ -355,11 +368,20 @@
"UsdtUsdPriceFeed": "0xa239729c399c9eBae7fdc188A1Dbb2c4a06Cd4Bb"
}
},
"okxchain": {
"okxchain.testnet": {
"okx": {
"okx.okxchain.testnet": {
"OktUsdtPriceFeed": "0xA86b7C50F1ad9bC43af34eFd505d4a059E67e56f",
"UsdtUsdPriceFeed": "0xa0E13F98D009d4976d1cE2f8E03228B656596c69",
"WitnetPriceFeedBypass": "0xB4f1f8E27799256ec95C5b5A8d2A5722Bd542E69"
},
"okx.x1.sepolia": {
"OkbUsdtPriceFeed": "0x758A15C3b32AD8353176014BC41fC7401650261D",
"BtcUsdPriceFeed": "0xcB8E58A8878a2d86B299064536119148B7B735cd",
"EthUsdPriceFeed": "0xCb17069BF40B1d80a7e4F1Ff2AfA9D3Ee4a3190d",
"UsdcUsdPriceFeed": "0x8Eb174752c99A70Fe0022e06fB35DA15608FF548",
"UsdtUsdPriceFeed": "0x67D5F7574F81B8923F15b8F3838AAf341D722239",
"WbtcUsdPriceFeed": "0x64aC13c925d268cA90653DBA96Ec342950eF3293",
"WitnetPriceFeedBypass": "0x2ef492c5300Ba8002ECC1ee44fD758be1d3B6e89"
}
},
"optimism": {
Expand All @@ -368,7 +390,7 @@
"WitnetPriceFeedBypass": "0xe04408124498F5812Ad341Df6038f11f18dC538e"
},
"optimism.mainnet": {
"OpUsdtPriceFeed": "0x0Dd81412825b9C3960195ab47F14dFa9Fd70e36e"
"OpUsdtPriceFeed": ""
}
},
"polygon": {
Expand Down Expand Up @@ -429,12 +451,19 @@
}
},
"scroll": {
"scroll.goerli": {
"BtcUsdPriceFeed": "0x8bb3DDbA9a6A0647C9287166AFAc6b589a05314d",
"EthUsdPriceFeed": "0xf45eEd6a7cB76a415050D17592D90A6eB707D962",
"UniUsdPriceFeed": "0x8d0af33230C1d28bc8f4fB579F3726E0362bad66",
"UsdcUsdPriceFeed": "0x420dCE64119700948586d48cF06401faF76789bD",
"WitnetPriceFeedBypass": "0x0fab02a4E2fE4976c2c89470622bc63a46A9096a"
"scroll.sepolia": {
"BtcUsdPriceFeed": "0xe184Bd4f4A2A9AF38642E3595Aa004b071934B58",
"EthUsdPriceFeed": "0x08A30c218fB4E0357639E1984caec232a7108411",
"UniUsdPriceFeed": "0x27190703F0b64F8fAfcf3c0e76649040afBE26C6",
"UsdcUsdPriceFeed": "0x830a48FEf29e155A38238E7cF5728336Bd87c533",
"WitnetPriceFeedBypass": "0xB772f86004330738C1529cC1b0327D24aeF8c370"
},
"scroll.mainnet": {
"BtcUsdPriceFeed": "0x2FBA3Aad4F2e2BBC562b4fdA76D82e8036dbEd3c",
"EthUsdPriceFeed": "0x6C74Aa59D58c0C2A26B07845dC607CD3fECF6B90",
"UniUsdPriceFeed": "0x96a215587C06EeAADDc51feDF8C5918a59970CE3",
"UsdcUsdPriceFeed": "0x0dAc06Ca814b6238524FcB2044108fa112aDf199",
"WitnetPriceFeedBypass": "0xC467B6E0F700D3E044C9F20BB76957eEC0B33c8C"
}
},
"smartbch": {
Expand Down
20 changes: 15 additions & 5 deletions migrations/witnet-queries.json
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,7 @@
"path": "witnet/prices/k/KavaUsdtPrice.js"
},
"KcsUsdtPrice": {
"bytecode": "0x0a9104125f0801123b68747470733a2f2f617363656e6465782e636f6d2f6170692f70726f2f76312f73706f742f7469636b65723f73796d626f6c3d4b43532f555344541a1e851877821866646461746182186465636c6f73658218571a000f4240185b12690801124568747470733a2f2f6170692e6b75636f696e2e636f6d2f6170692f76312f6d61726b65742f6f72646572626f6f6b2f6c6576656c313f73796d626f6c3d4b43532d555344541a1e85187782186664646174618218646570726963658218571a000f4240185b12650801123e68747470733a2f2f7777772e6d6578632e636f6d2f6f70656e2f6170692f76322f6d61726b65742f7469636b65723f73796d626f6c3d4b43535f555344541a21861877821861646461746182181800821864646c6173748218571a000f4240185b12bd010803123768747470733a2f2f74686567726170682e6b63632e6e6574776f726b2f7375626772617068732f6e616d652f6d6f6a69746f2f737761701a2c861877821866646461746182186664706169728218646b746f6b656e3050726963658218571a000f4240185b22527b227175657279223a227b706169722869643a5c223078623362393264366232363536663963656234613338313731383336316132316266396238326264395c22297b746f6b656e3050726963657d7d227d1a0d0a0908051205fa3fc000001003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"bytecode": "0x0ab304125f0801123b68747470733a2f2f617363656e6465782e636f6d2f6170692f70726f2f76312f73706f742f7469636b65723f73796d626f6c3d4b43532f555344541a1e851877821866646461746182186465636c6f73658218571a000f4240185b12690801124568747470733a2f2f6170692e6b75636f696e2e636f6d2f6170692f76312f6d61726b65742f6f72646572626f6f6b2f6c6576656c313f73796d626f6c3d4b43532d555344541a1e85187782186664646174618218646570726963658218571a000f4240185b12650801123e68747470733a2f2f7777772e6d6578632e636f6d2f6f70656e2f6170692f76322f6d61726b65742f7469636b65723f73796d626f6c3d4b43535f555344541a21861877821861646461746182181800821864646c6173748218571a000f4240185b12df010803123768747470733a2f2f74686567726170682e6b63632e6e6574776f726b2f7375626772617068732f6e616d652f6d6f6a69746f2f737761701a2c861877821866646461746182186664706169728218646b746f6b656e3050726963658218571a000f4240185b22527b227175657279223a227b706169722869643a5c223078623362393264366232363536663963656234613338313731383336316132316266396238326264395c22297b746f6b656e3050726963657d7d227d2a200a0c436f6e74656e742d5479706512106170706c69636174696f6e2f6a736f6e1a0d0a0908051205fa3fc000001003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"base": "KCS",
"quote": "USDT",
"decimals": 6,
Expand Down Expand Up @@ -363,7 +363,7 @@
"path": "witnet/prices/m/MetisUsdtPrice.js"
},
"MjtKcsPrice": {
"bytecode": "0x0acc0212680801124468747470733a2f2f6170692e6b75636f696e2e636f6d2f6170692f76312f6d61726b65742f6f72646572626f6f6b2f6c6576656c313f73796d626f6c3d4d4a542d4b43531a1e85187782186664646174618218646570726963658218571a3b9aca00185b12bd010803123768747470733a2f2f74686567726170682e6b63632e6e6574776f726b2f7375626772617068732f6e616d652f6d6f6a69746f2f737761701a2c861877821866646461746182186664706169728218646b746f6b656e3150726963658218571a3b9aca00185b22527b227175657279223a227b706169722869643a5c223078613064376338616137383933363263646634666161653234623964313532386564356133373737665c22297b746f6b656e3150726963657d7d227d1a110a0d08051209fb3ff66666666666661003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"bytecode": "0x0aee0212680801124468747470733a2f2f6170692e6b75636f696e2e636f6d2f6170692f76312f6d61726b65742f6f72646572626f6f6b2f6c6576656c313f73796d626f6c3d4d4a542d4b43531a1e85187782186664646174618218646570726963658218571a3b9aca00185b12df010803123768747470733a2f2f74686567726170682e6b63632e6e6574776f726b2f7375626772617068732f6e616d652f6d6f6a69746f2f737761701a2c861877821866646461746182186664706169728218646b746f6b656e3150726963658218571a3b9aca00185b22527b227175657279223a227b706169722869643a5c223078613064376338616137383933363263646634666161653234623964313532386564356133373737665c22297b746f6b656e3150726963657d7d227d2a200a0c436f6e74656e742d5479706512106170706c69636174696f6e2f6a736f6e1a110a0d08051209fb3ff66666666666661003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"base": "MJT",
"quote": "KCS",
"decimals": 9,
Expand All @@ -381,6 +381,11 @@
"decimals": 6,
"path": "witnet/prices/m/MovrUsdtPrice.js"
},
"MtrgUsdPrice": {
"base": "MTRG",
"quote": "USD",
"decimals": 6
},
"MtrgUsdtPrice": {
"bytecode": "0x0ac202124a0801122f68747470733a2f2f646174612e676174656170692e696f2f617069322f312f7469636b65722f6d7472675f757364741a15841877821864646c6173748218571a000f4240185b126a0801124668747470733a2f2f6170692e6b75636f696e2e636f6d2f6170692f76312f6d61726b65742f6f72646572626f6f6b2f6c6576656c313f73796d626f6c3d4d5452472d555344541a1e85187782186664646174618218646570726963658218571a000f4240185b12660801123f68747470733a2f2f7777772e6d6578632e636f6d2f6f70656e2f6170692f76322f6d61726b65742f7469636b65723f73796d626f6c3d4d5452475f555344541a21861877821861646461746182181800821864646c6173748218571a000f4240185b1a110a0d08051209fb3ff66666666666661003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"base": "MTRG",
Expand Down Expand Up @@ -414,6 +419,11 @@
"quote": "USD",
"decimals": 6
},
"OkbUsdtPrice": {
"base": "OKB",
"quote": "USDT",
"decimals": 6
},
"OktUsdtPrice": {
"bytecode": "0x0ab70212490801122e68747470733a2f2f646174612e676174656170692e696f2f617069322f312f7469636b65722f6f6b745f757364741a15841877821864646c6173748218571a000f4240185b125f0801123868747470733a2f2f7777772e6f6b782e636f6d2f6170692f76352f6d61726b65742f7469636b65723f696e737449643d4f4b542d555344541a21861877821861646461746182181800821864646c6173748218571a000f4240185b12670801123e68747470733a2f2f7777772e6d6578632e636f6d2f6f70656e2f6170692f76322f6d61726b65742f7469636b65723f73796d626f6c3d4f4b545f555344541a23871877821861646461746182181800821867646c61737418728218571a000f4240185b1a110a0d08051209fb3ff66666666666661003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"base": "OKT",
Expand Down Expand Up @@ -490,7 +500,7 @@
"path": "witnet/prices/r/ReefUsdtPrice.js"
},
"SaxUsdtPrice": {
"bytecode": "0x0ae20112bd010803123768747470733a2f2f74686567726170682e6b63632e6e6574776f726b2f7375626772617068732f6e616d652f6d6f6a69746f2f737761701a2c861877821866646461746182186664706169728218646b746f6b656e3050726963658218571a000f4240185b22527b227175657279223a227b706169722869643a5c223078313136323133316236336439353231306163663562333431396433386336383439326639393863635c22297b746f6b656e3050726963657d7d227d1a110a0d08051209fb3ff66666666666661003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"bytecode": "0x0a840212df010803123768747470733a2f2f74686567726170682e6b63632e6e6574776f726b2f7375626772617068732f6e616d652f6d6f6a69746f2f737761701a2c861877821866646461746182186664706169728218646b746f6b656e3050726963658218571a000f4240185b22527b227175657279223a227b706169722869643a5c223078313136323133316236336439353231306163663562333431396433386336383439326639393863635c22297b746f6b656e3050726963657d7d227d2a200a0c436f6e74656e742d5479706512106170706c69636174696f6e2f6a736f6e1a110a0d08051209fb3ff66666666666661003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"base": "SAX",
"quote": "USDT",
"decimals": 6,
Expand Down Expand Up @@ -571,12 +581,12 @@
"decimals": 6,
"path": "witnet/prices/v/VsqDaiPrice.js"
},
"WbtcUsd": {
"WbtcUsdPrice": {
"bytecode": "0x0af00112670801123768747470733a2f2f6170692e636f696e626173652e636f6d2f76322f65786368616e67652d72617465733f63757272656e63793d5553441a2a87187782186664646174618218666572617465738218646457425443821859208218571a000f4240185b12630801123368747470733a2f2f6170692e6b72616b656e2e636f6d2f302f7075626c69632f5469636b65723f706169723d574254435553441a2a87187782186666726573756c74821866675742544355534482186161618216008218571a000f4240185b1a110a0d08051209fb3ff66666666666661003220d0a0908051205fa4020000010031080a3c347180a2080ade20428333080acc7f037",
"base": "WBTC",
"quote": "USD",
"decimals": 6,
"path": "witnet/prices/w/WbtcUsd.js"
"path": "witnet/prices/w/WbtcUsdPrice.js"
},
"WbtcWulxPrice": {
"bytecode": "0x0ac70112b1010801123668747470733a2f2f65786368616e67652d696e666f2e756c74726f6e2d6465762e6e65742f6170692f76312f756c74726f6e737761701a7585187782186678553078336134663036343331343537646538373362353838383436643133396563306438363237356435345f3078643262383661383061386633306238333834336532343761353065636463386438343364383764648218646a6c6173745f70726963658218571a000f4240185b1a021002220d0a0908051205fa4020000010051080a3c347180a2080ade20428333080acc7f037",
Expand Down
4 changes: 2 additions & 2 deletions migrations/witnet-slas.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
module.exports = {
numWitnesses: 10, // 10 witnesses
witnessCollateral: 15 * 10 ** 9, // 15 wit
witnessCollateral: 20 * 10 ** 9, // 20 wit
witnessCommitFee: 0.01 * 10 ** 9, // 0.01 wit
witnessReward: 0.15 * 10 ** 9, // 0.15 wit
witnessReward: 0.20 * 10 ** 9, // 0.20 wit
witnessingQuorum: 51, // 51% quorum
};
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"ado-contracts": "^1.0.0",
"lodash": "^4.17.21",
"openzeppelin-solidity": "^2.4.0",
"witnet-solidity-bridge": "https://github.com/guidiaz/witnet-solidity-bridge#8f45b2999ec7c8b318b79dfcbf9e97510a0e1fb1"
"witnet-solidity-bridge": "https://github.com/guidiaz/witnet-solidity-bridge#5b7aa234219d734b8b4d5bc28b3e93e45ada3bb0"
},
"devDependencies": {
"@babel/cli": "^7.5.5",
Expand Down
1 change: 1 addition & 0 deletions truffle-config.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,5 +43,6 @@ module.exports = {
elastos: "",
etherscan: process.env.ETHERSCAN_API_KEY,
polygonscan: process.env.POLYGONSCAN_API_KEY,
scrollscan: process.env.SCROLLSCAN_API_KEY,
},
}
3 changes: 3 additions & 0 deletions witnet/prices/k/KcsUsdtPrice.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ const mojito = new Witnet.GraphQLSource(
token0Price
}
}`,
{
"Content-Type": "application/json"
},
)
.parseJSONMap()
.getMap("data")
Expand Down
3 changes: 3 additions & 0 deletions witnet/prices/m/MjtKcsPrice.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ const mojito = new Witnet.GraphQLSource(
token1Price
}
}`,
{
"Content-Type": "application/json"
},
)
.parseJSONMap()
.getMap("data")
Expand Down
3 changes: 3 additions & 0 deletions witnet/prices/s/SaxUsdtPrice.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ const mojito = new Witnet.GraphQLSource(
token0Price
}
}`,
{
"Content-Type": "application/json"
},
)
.parseJSONMap()
.getMap("data")
Expand Down
Loading