tx · CZxQS9EYmdhF62s7WanLMejjGT24du9nwiE4oyhP3uvT

3N3wgpZuw6MWRgf7XouSYL26EZSHCBYKgd6:  -0.10000000 Waves

2020.04.02 06:13 [935976] smart account 3N3wgpZuw6MWRgf7XouSYL26EZSHCBYKgd6 > SELF 0.00000000 Waves

{ "type": 13, "id": "CZxQS9EYmdhF62s7WanLMejjGT24du9nwiE4oyhP3uvT", "fee": 10000000, "feeAssetId": null, "timestamp": 1585797210780, "version": 1, "sender": "3N3wgpZuw6MWRgf7XouSYL26EZSHCBYKgd6", "senderPublicKey": "9ZPbyU1ZXeXBHtwUPjdeVo3xNdu7TqRN7S81nrZznxs3", "proofs": [ "56GP5ypf2tCLaz6fR4DLVnX69UCtaQjz3udiXLxTKNoawrskusTsTkderbPzSyBM6ELnSTaK1q2xTNz6iqPfGEhs" ], "script": "base64:AAIDAAAAAAAAAB8IARIECgIBARIDCgEIEgcKBQEBAQEBEgASBQoDAQECAAAAGQEAAAAWY29udmVydFdhdmVzVG9OZXV0cmlubwAAAAIAAAAGYW1vdW50AAAABXByaWNlCQAAawAAAAMJAABrAAAAAwUAAAAGYW1vdW50BQAAAAVwcmljZQAAAAAAAAAAZAAAAAAAAA9CQAAAAAAABfXhAAEAAAAOZ2V0U3RyaW5nQnlLZXkAAAABAAAAA2tleQQAAAAHJG1hdGNoMAkABB0AAAACBQAAAAR0aGlzBQAAAANrZXkDCQAAAQAAAAIFAAAAByRtYXRjaDACAAAABlN0cmluZwQAAAABYQUAAAAHJG1hdGNoMAUAAAABYQIAAAAAAQAAABhnZXROdW1iZXJCeUFkZHJlc3NBbmRLZXkAAAACAAAAB2FkZHJlc3MAAAADa2V5BAAAAAckbWF0Y2gwCQAEGgAAAAIJAQAAABxAZXh0clVzZXIoYWRkcmVzc0Zyb21TdHJpbmcpAAAAAQUAAAAHYWRkcmVzcwUAAAADa2V5AwkAAAEAAAACBQAAAAckbWF0Y2gwAgAAAANJbnQEAAAAAWEFAAAAByRtYXRjaDAFAA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AAAACFdyaXRlU2V0AAAAAQkABEwAAAACCQEAAAAJRGF0YUVudHJ5AAAAAgIAAAAFZGF0YTEAAAAAAAAAAGQJAARMAAAAAgkBAAAACURhdGFFbnRyeQAAAAICAAAABnByaWNlXwkAAGgAAAACCQEAAAAOZ2V0TnVtYmVyQnlLZXkAAAABAgAAAAVkYXRhMQAAAAAAAAAAAgUAAAADbmlsAAAAAWkBAAAAFWZpbmFsaXplQ3VycmVudFByaWNlMgAAAAMAAAAGcHJpY2UxAAAAB2hlaWdodDEAAAAFc2lnbjEEAAAAC2FsaWNlUHViS2V5AQAAACB/KaN6XnfEM1o9SbyF/WkVUKkJZluFlhpLSR0x07z4agQAAAALYWxpY2VTaWduZWQDCQAB9AAAAAMJAQAAABJmb3JtYXR0aW5nUHJpY2VNc2cAAAACBQAAAAZwcmljZTEFAAAABmhlaWdodAUAAAAFc2lnbjEFAAAAC2FsaWNlUHViS2V5AAAAAAAAAAABAAAAAAAAAAAACQEAAAAIV3JpdGVTZXQAAAABCQAETAAAAAIJAQAAAAlEYXRhRW50cnkAAAACAgAAAAtzaWduUmVzdWx0XwUAAAALYWxpY2VTaWduZWQFAAAAA25pbAAAAABOt6rQ", "chainId": 84, "height": 935976, "spentComplexity": 0 } View: original | compacted Prev: G89ozM5oMdzQVFmVCeZfciDrGBswoSB3gpk2jssadzfi Next: none Diff:
OldNewDifferences
281281
282282
283283 @Callable(i)
284+func formattingPriceMsg1 (price,height) = {
285+ let a = toBytes((((("WAVESNEUTRINOPREFIX" + "_") + toString(height)) + "_") + toString(price)))
286+ WriteSet([DataEntry("result", a)])
287+ }
288+
289+
290+
291+@Callable(i)
284292 func callEmergencyShutdown (reason) = {
285293 let AutoEmergencyOracleAddress = "3Mwho43kPZa9w1y91NJsAoYxgQpsg3JjGby"
286294 let callerAddress = toString(i.caller)
357365 @Callable(i)
358366 func finalizeCurrentPrice1 () = if ((1 > 4))
359367 then throw("")
360- else {
361- let newPriceIndex = (priceIndex + 1)
362- WriteSet([DataEntry("data1", 100), DataEntry("price_", (getNumberByKey("data1") * 2))])
363- }
368+ else WriteSet([DataEntry("data1", 100), DataEntry("price_", (getNumberByKey("data1") * 2))])
369+
370+
371+
372+@Callable(i)
373+func finalizeCurrentPrice2 (price1,height1,sign1) = {
374+ let alicePubKey = base58'9ZPbyU1ZXeXBHtwUPjdeVo3xNdu7TqRN7S81nrZznxs3'
375+ let aliceSigned = if (sigVerify(formattingPriceMsg(price1, height), sign1, alicePubKey))
376+ then 1
377+ else 0
378+ WriteSet([DataEntry("signResult_", aliceSigned)])
379+ }
364380
365381
Full:
OldNewDifferences
11 {-# STDLIB_VERSION 3 #-}
22 {-# SCRIPT_TYPE ACCOUNT #-}
33 {-# CONTENT_TYPE DAPP #-}
44 func convertWavesToNeutrino (amount,price) = fraction(fraction(amount, price, 100), 1000000, 100000000)
55
66
77 func getStringByKey (key) = match getString(this, key) {
88 case a: String =>
99 a
1010 case _ =>
1111 ""
1212 }
1313
1414
1515 func getNumberByAddressAndKey (address,key) = match getInteger(addressFromStringValue(address), key) {
1616 case a: Int =>
1717 a
1818 case _ =>
1919 0
2020 }
2121
2222
2323 func getOracleProvideHeight (ownerPub,height) = match getInteger(addressFromPublicKey(ownerPub), ("price_" + toString(height))) {
2424 case a: Int =>
2525 a
2626 case _ =>
2727 0
2828 }
2929
3030
3131 func getNumberByKey (key) = match getInteger(this, key) {
3232 case a: Int =>
3333 a
3434 case _ =>
3535 0
3636 }
3737
3838
3939 func getStringByAddressAndKey (address,key) = match getString(address, key) {
4040 case a: String =>
4141 a
4242 case _ =>
4343 ""
4444 }
4545
4646
4747 func dropElementInJsonArray (array,element) = {
4848 let splitedArray = split(array, element)
4949 if ((take(splitedArray[1], 1) == ","))
5050 then (splitedArray[0] + drop(splitedArray[1], 1))
5151 else (dropRight(splitedArray[0], 1) + splitedArray[1])
5252 }
5353
5454
5555 func convertJsonArrayToList (jsonArray) = split(jsonArray, ",")
5656
5757
5858 let price = match getInteger(this, "price") {
5959 case a: Int =>
6060 a
6161 case _ =>
6262 0
6363 }
6464
6565 let priceIndex = match getInteger(this, "price_index") {
6666 case a: Int =>
6767 a
6868 case _ =>
6969 0
7070 }
7171
7272 let isBlocked = match getBoolean(this, "is_blocked") {
7373 case a: Boolean =>
7474 a
7575 case _ =>
7676 false
7777 }
7878
7979 let percentPriceOffset = 7
8080
8181 let pubKeyOracles = getStringByKey("oracles")
8282
8383 let pubKeyOraclesList = convertJsonArrayToList(pubKeyOracles)
8484
8585 let bftCoefficientOracle = 4
8686
8787 let neutrinoAddress = addressFromPublicKey(fromBase58String("J4hU7VqLs2JAJXwFnjicQ97XShyZEqt8REC8fJHkTdKd"))
8888
8989 let liquidationAddress = addressFromPublicKey(fromBase58String("HDqeggkNi96GMzyGv4AQMQms43nwSrvgMjTDznyivt8R"))
9090
9191 let neutrinoAsset = fromBase58String("EyizrdEpB9yuh45Zv3f2UfxKLjcecrmvcq5DSP9fEwum")
9292
9393 let neutrinoLockedBalance = match getInteger(neutrinoAddress, "balance_lock_neutrino") {
9494 case a: Int =>
9595 a
9696 case _ =>
9797 0
9898 }
9999
100100 let wavesLockedBalance = match getInteger(neutrinoAddress, "balance_lock_waves") {
101101 case a: Int =>
102102 a
103103 case _ =>
104104 0
105105 }
106106
107107 let reserve = (wavesBalance(neutrinoAddress) - wavesLockedBalance)
108108
109109 let neutrinoSupply = (((neutrinoLockedBalance + extract(assetInfo(neutrinoAsset)).quantity) - assetBalance(neutrinoAddress, neutrinoAsset)) - assetBalance(liquidationAddress, neutrinoAsset))
110110
111111 let deficit = (neutrinoSupply - convertWavesToNeutrino(reserve, price))
112112
113113 func findPricesInRange (prices) = {
114114 let minPercentBound = 90
115115 let maxPercentBound = 110
116116 let p0 = prices[0]
117117 let check0 = if ((0 >= prices[0]))
118118 then [0]
119119 else {
120120 let p01 = ((prices[1] * 100) / p0)
121121 let p02 = ((prices[2] * 100) / p0)
122122 let p03 = ((prices[3] * 100) / p0)
123123 let p04 = ((prices[4] * 100) / p0)
124124 let array1 = if (if ((maxPercentBound > p01))
125125 then (p01 > minPercentBound)
126126 else false)
127127 then [1, 0]
128128 else [0]
129129 let array2 = if (if ((maxPercentBound > p02))
130130 then (p02 > minPercentBound)
131131 else false)
132132 then 2 :: array1
133133 else array1
134134 let array3 = if (if ((maxPercentBound > p03))
135135 then (p03 > minPercentBound)
136136 else false)
137137 then 3 :: array2
138138 else array2
139139 if (if ((maxPercentBound > p04))
140140 then (p04 > minPercentBound)
141141 else false)
142142 then 4 :: array3
143143 else array3
144144 }
145145 let check1 = if ((size(check0) >= 3))
146146 then check0
147147 else {
148148 let p1 = prices[1]
149149 if ((0 >= p1))
150150 then [1]
151151 else {
152152 let p10 = ((prices[0] * 100) / p1)
153153 let p12 = ((prices[2] * 100) / p1)
154154 let p13 = ((prices[3] * 100) / p1)
155155 let p14 = ((prices[4] * 100) / p1)
156156 let array1 = if (if ((maxPercentBound > p10))
157157 then (p10 > minPercentBound)
158158 else false)
159159 then [0, 1]
160160 else [1]
161161 let array2 = if (if ((maxPercentBound > p12))
162162 then (p12 > minPercentBound)
163163 else false)
164164 then 2 :: array1
165165 else array1
166166 let array3 = if (if ((maxPercentBound > p13))
167167 then (p13 > minPercentBound)
168168 else false)
169169 then 3 :: array2
170170 else array2
171171 if (if ((maxPercentBound > p14))
172172 then (p14 > minPercentBound)
173173 else false)
174174 then 4 :: array3
175175 else array3
176176 }
177177 }
178178 let check2 = if ((size(check1) >= 3))
179179 then check1
180180 else {
181181 let p2 = prices[2]
182182 if ((0 >= p2))
183183 then [2]
184184 else {
185185 let p20 = ((prices[0] * 100) / p2)
186186 let p21 = ((prices[1] * 100) / p2)
187187 let p23 = ((prices[3] * 100) / p2)
188188 let p24 = ((prices[4] * 100) / p2)
189189 let array1 = if (if ((maxPercentBound > p20))
190190 then (p20 > minPercentBound)
191191 else false)
192192 then [0, 2]
193193 else [2]
194194 let array2 = if (if ((maxPercentBound > p21))
195195 then (p21 > minPercentBound)
196196 else false)
197197 then 1 :: array1
198198 else array1
199199 let array3 = if (if ((maxPercentBound > p23))
200200 then (p23 > minPercentBound)
201201 else false)
202202 then 3 :: array2
203203 else array2
204204 if (if ((maxPercentBound > p24))
205205 then (p24 > minPercentBound)
206206 else false)
207207 then 4 :: array3
208208 else array3
209209 }
210210 }
211211 let check3 = if ((size(check2) >= 3))
212212 then check2
213213 else {
214214 let p3 = prices[3]
215215 if ((0 >= p3))
216216 then [3]
217217 else {
218218 let p30 = ((prices[0] * 100) / p3)
219219 let p31 = ((prices[1] * 100) / p3)
220220 let p32 = ((prices[2] * 100) / p3)
221221 let p34 = ((prices[4] * 100) / p3)
222222 let array1 = if (if ((maxPercentBound > p30))
223223 then (p30 > minPercentBound)
224224 else false)
225225 then [0, 3]
226226 else [3]
227227 let array2 = if (if ((maxPercentBound > p31))
228228 then (p31 > minPercentBound)
229229 else false)
230230 then 1 :: array1
231231 else array1
232232 let array3 = if (if ((maxPercentBound > p32))
233233 then (p32 > minPercentBound)
234234 else false)
235235 then 2 :: array2
236236 else array2
237237 if (if ((maxPercentBound > p34))
238238 then (p34 > minPercentBound)
239239 else false)
240240 then 4 :: array3
241241 else array3
242242 }
243243 }
244244 if ((size(check3) >= 3))
245245 then check3
246246 else {
247247 let p4 = prices[4]
248248 if ((0 >= p4))
249249 then [4]
250250 else {
251251 let p40 = ((prices[0] * 100) / p4)
252252 let p41 = ((prices[1] * 100) / p4)
253253 let p42 = ((prices[2] * 100) / p4)
254254 let p43 = ((prices[3] * 100) / p4)
255255 let array1 = if (if ((maxPercentBound > p40))
256256 then (p40 > minPercentBound)
257257 else false)
258258 then [0, 4]
259259 else [4]
260260 let array2 = if (if ((maxPercentBound > p41))
261261 then (p41 > minPercentBound)
262262 else false)
263263 then 1 :: array1
264264 else array1
265265 let array3 = if (if ((maxPercentBound > p42))
266266 then (p42 > minPercentBound)
267267 else false)
268268 then 2 :: array2
269269 else array2
270270 if (if ((maxPercentBound > p43))
271271 then (p43 > minPercentBound)
272272 else false)
273273 then 3 :: array3
274274 else array3
275275 }
276276 }
277277 }
278278
279279
280280 func formattingPriceMsg (price,height) = toBytes((((("WAVESNEUTRINOPREFIX" + "_") + toString(height)) + "_") + toString(price)))
281281
282282
283283 @Callable(i)
284+func formattingPriceMsg1 (price,height) = {
285+ let a = toBytes((((("WAVESNEUTRINOPREFIX" + "_") + toString(height)) + "_") + toString(price)))
286+ WriteSet([DataEntry("result", a)])
287+ }
288+
289+
290+
291+@Callable(i)
284292 func callEmergencyShutdown (reason) = {
285293 let AutoEmergencyOracleAddress = "3Mwho43kPZa9w1y91NJsAoYxgQpsg3JjGby"
286294 let callerAddress = toString(i.caller)
287295 if ((AutoEmergencyOracleAddress != callerAddress))
288296 then throw("caller must be one an emergency oracle")
289297 else WriteSet([DataEntry("is_blocked", true), DataEntry("is_blocked_caller", callerAddress), DataEntry("is_blocked_reason", reason)])
290298 }
291299
292300
293301
294302 @Callable(i)
295303 func finalizeCurrentPrice (price1,price2,price3,price4,price5) = if (isBlocked)
296304 then throw("contract is blocked by EMERGENCY SHUTDOWN actions untill reactivation by emergency oracles")
297305 else if (( match getInteger(this, ("price_" + toString(height))) {
298306 case a: Int =>
299307 a
300308 case _ =>
301309 0
302310 } != 0))
303311 then throw("wait next block")
304312 else {
305313 let prices = [if ((price1 > 0))
306314 then price1
307315 else 0, if ((price2 > 0))
308316 then price2
309317 else 0, if ((price3 > 0))
310318 then price3
311319 else 0, if ((price4 > 0))
312320 then price4
313321 else 0, if ((price5 > 0))
314322 then price5
315323 else 0]
316324 if (((1 + 1) > 3))
317325 then throw("running here!")
318326 else {
319327 let pricesInRange = findPricesInRange(prices)
320328 let priceProvidingCount = size(pricesInRange)
321329 if ((3 > priceProvidingCount))
322330 then throw(((((((((((((((((((((("Could not finalize price because of big variation: height=" + toString(height)) + "
323331 ") + pubKeyOraclesList[0]) + "=") + toString(prices[0])) + "
324332 ") + pubKeyOraclesList[1]) + "=") + toString(prices[1])) + "
325333 ") + pubKeyOraclesList[2]) + "=") + toString(prices[2])) + "
326334 ") + pubKeyOraclesList[3]) + "=") + toString(prices[3])) + "
327335 ") + pubKeyOraclesList[4]) + "=") + toString(prices[4])))
328336 else {
329337 let sum1 = ((prices[pricesInRange[0]] + prices[pricesInRange[1]]) + prices[pricesInRange[2]])
330338 let sum2 = if ((priceProvidingCount >= 4))
331339 then (sum1 + prices[pricesInRange[3]])
332340 else sum1
333341 let priceSum = if ((priceProvidingCount >= 5))
334342 then (sum2 + prices[pricesInRange[4]])
335343 else sum2
336344 if ((priceProvidingCount >= 6))
337345 then throw("Invalid pricesInRange creation")
338346 else {
339347 let newPrice = (priceSum / priceProvidingCount)
340348 if (if ((newPrice >= (price + ((price * percentPriceOffset) / 100))))
341349 then true
342350 else ((price - ((price * percentPriceOffset) / 100)) >= newPrice))
343351 then WriteSet([DataEntry("is_blocked", true), DataEntry((("black_swarm_price" + "_") + toString(height)), newPrice)])
344352 else {
345353 let newPriceIndex = (priceIndex + 1)
346354 WriteSet([DataEntry("price", newPrice), DataEntry(("price_" + toString(height)), newPrice), DataEntry("price_index", newPriceIndex), DataEntry(("price_index_" + toString(newPriceIndex)), height), DataEntry(("deficit_" + toString(height)), deficit), DataEntry(("neutrinoSupply_" + toString(height)), neutrinoSupply), DataEntry(("deficit_percent_" + toString(height)), if ((neutrinoSupply != 0))
347355 then ((deficit * 100) / neutrinoSupply)
348356 else 0)])
349357 }
350358 }
351359 }
352360 }
353361 }
354362
355363
356364
357365 @Callable(i)
358366 func finalizeCurrentPrice1 () = if ((1 > 4))
359367 then throw("")
360- else {
361- let newPriceIndex = (priceIndex + 1)
362- WriteSet([DataEntry("data1", 100), DataEntry("price_", (getNumberByKey("data1") * 2))])
363- }
368+ else WriteSet([DataEntry("data1", 100), DataEntry("price_", (getNumberByKey("data1") * 2))])
369+
370+
371+
372+@Callable(i)
373+func finalizeCurrentPrice2 (price1,height1,sign1) = {
374+ let alicePubKey = base58'9ZPbyU1ZXeXBHtwUPjdeVo3xNdu7TqRN7S81nrZznxs3'
375+ let aliceSigned = if (sigVerify(formattingPriceMsg(price1, height), sign1, alicePubKey))
376+ then 1
377+ else 0
378+ WriteSet([DataEntry("signResult_", aliceSigned)])
379+ }
364380
365381

github/deemru/w8io/169f3d6 
43.84 ms