Skip to content

Commit 2921c30

Browse files
committed
Upgrade Flapper to rate limited version
1 parent 3750d75 commit 2921c30

File tree

7 files changed

+101
-60
lines changed

7 files changed

+101
-60
lines changed

.dapp.json

+60-60
Original file line numberDiff line numberDiff line change
@@ -182,16 +182,16 @@
182182
"url": "https://github.com/makerdao/ds-weth"
183183
}
184184
},
185-
"dsr-manager_f495973": {
185+
"dsr-manager_0a48c2d": {
186186
"deps": {
187187
"ds-test": "ds-test_0a5da56",
188-
"dss-deploy": "dss-deploy_4963763"
188+
"dss-deploy": "dss-deploy_45985a9"
189189
},
190190
"name": "dsr-manager",
191191
"repo": {
192-
"name": "dsr-manager-f495973",
192+
"name": "dsr-manager-0a48c2d",
193193
"ref": "HEAD",
194-
"rev": "f4959733be3ae561afda5fd2b7108aa10d514299",
194+
"rev": "0a48c2dda418927ab844ec251f24079c0a3ff2bb",
195195
"url": "https://github.com/makerdao/dsr-manager"
196196
}
197197
},
@@ -207,156 +207,156 @@
207207
"url": "https://github.com/makerdao/dss-auto-line"
208208
}
209209
},
210-
"dss-cdp-manager_03f46a0": {
210+
"dss-cdp-manager_306132d": {
211211
"deps": {
212212
"ds-test": "ds-test_0a5da56",
213-
"dss-deploy": "dss-deploy_4963763"
213+
"dss-deploy": "dss-deploy_45985a9"
214214
},
215215
"name": "dss-cdp-manager",
216216
"repo": {
217-
"name": "dss-cdp-manager-03f46a0",
217+
"name": "dss-cdp-manager-306132d",
218218
"ref": "v1.2",
219-
"rev": "03f46a0ec2175be6063621d9bd6003d0e6d58952",
219+
"rev": "306132d6442b3245081a60bc84468c6a0c252fa8",
220220
"url": "https://github.com/makerdao/dss-cdp-manager"
221221
}
222222
},
223-
"dss-chain-log_83e7a01": {
223+
"dss-chain-log_90cf9c0": {
224224
"deps": {
225225
"ds-test": "ds-test_0a5da56"
226226
},
227227
"name": "dss-chain-log",
228228
"repo": {
229-
"name": "dss-chain-log-83e7a01",
229+
"name": "dss-chain-log-90cf9c0",
230230
"ref": "HEAD",
231-
"rev": "83e7a01c5941447271ef9d32232dd4471fe3c851",
231+
"rev": "90cf9c0589d56724b94a0d4f9b4af486a2231385",
232232
"url": "https://github.com/makerdao/dss-chain-log"
233233
}
234234
},
235-
"dss-deploy-pause-proxy-actions_9446eb9": {
235+
"dss-deploy-pause-proxy-actions_9344383": {
236236
"deps": {
237237
"ds-proxy": "ds-proxy_e17a252",
238238
"ds-test": "ds-test_0a5da56",
239-
"dss-deploy": "dss-deploy_4963763"
239+
"dss-deploy": "dss-deploy_45985a9"
240240
},
241241
"name": "dss-deploy-pause-proxy-actions",
242242
"repo": {
243-
"name": "dss-deploy-pause-proxy-actions-9446eb9",
243+
"name": "dss-deploy-pause-proxy-actions-9344383",
244244
"ref": "HEAD",
245-
"rev": "9446eb988c9704b9e41c990898f53c5b27b3f45d",
245+
"rev": "93443831ea4008177bbdc55d9ab8ba8ee069324c",
246246
"url": "https://github.com/makerdao/dss-deploy-pause-proxy-actions"
247247
}
248248
},
249-
"dss-deploy_4963763": {
249+
"dss-deploy_45985a9": {
250250
"deps": {
251251
"ds-auth": "ds-auth_a51e7ca",
252252
"ds-pause": "ds-pause_5e798dd",
253253
"ds-test": "ds-test_0a5da56",
254-
"dss": "dss_fb73e44",
254+
"dss": "dss_38f618c",
255255
"esm": "esm_8fabd86"
256256
},
257257
"name": "dss-deploy",
258258
"repo": {
259-
"name": "dss-deploy-4963763",
259+
"name": "dss-deploy-45985a9",
260260
"ref": "v1.2",
261-
"rev": "49637632f9488eed5639cf434a7c8b413b1eb41a",
261+
"rev": "45985a91024f3bc82cbe15b17dd70990d7f56020",
262262
"url": "https://github.com/makerdao/dss-deploy"
263263
}
264264
},
265-
"dss-deploy_8bdb323": {
265+
"dss-deploy_8b9bd85": {
266266
"deps": {
267267
"ds-auth": "ds-auth_a51e7ca",
268268
"ds-pause": "ds-pause_5e798dd",
269269
"ds-test": "ds-test_0a5da56",
270-
"dss": "dss_c666ab1",
270+
"dss": "dss_17187f7",
271271
"esm": "esm_225ddf2"
272272
},
273273
"name": "dss-deploy",
274274
"repo": {
275-
"name": "dss-deploy-8bdb323",
275+
"name": "dss-deploy-8b9bd85",
276276
"ref": "HEAD",
277-
"rev": "8bdb323a22d0afca8fab9a5094674d04eddb9049",
277+
"rev": "8b9bd85ec16f3da99ef92a05de93c04561eed7bc",
278278
"url": "https://github.com/makerdao/dss-deploy"
279279
}
280280
},
281-
"dss-flash_ae57da2": {
281+
"dss-flash_b8f8fdc": {
282282
"deps": {
283283
"ds-test": "ds-test_0a5da56",
284-
"dss": "dss_c666ab1"
284+
"dss": "dss_17187f7"
285285
},
286286
"name": "dss-flash",
287287
"repo": {
288-
"name": "dss-flash-ae57da2",
288+
"name": "dss-flash-b8f8fdc",
289289
"ref": "HEAD",
290-
"rev": "ae57da25173d1df635a1a23e5300e13d620ea75a",
290+
"rev": "b8f8fdcf22a172bf0c27722d4a9ed8058cc4208c",
291291
"url": "https://github.com/makerdao/dss-flash"
292292
}
293293
},
294-
"dss-gem-joins_b91680b": {
294+
"dss-gem-joins_123d6b7": {
295295
"deps": {
296296
"ds-test": "ds-test_0a5da56",
297-
"dss-deploy": "dss-deploy_4963763"
297+
"dss-deploy": "dss-deploy_45985a9"
298298
},
299299
"name": "dss-gem-joins",
300300
"repo": {
301-
"name": "dss-gem-joins-b91680b",
301+
"name": "dss-gem-joins-123d6b7",
302302
"ref": "v1.2",
303-
"rev": "b91680be9aaeea02ecd05f822dd1ca41410024b3",
303+
"rev": "123d6b7d7210a4dc47cecc405e1deeaa0f28e0c0",
304304
"url": "https://github.com/makerdao/dss-gem-joins"
305305
}
306306
},
307-
"dss-proxy-actions_6d6b293": {
307+
"dss-proxy-actions_5cf4634": {
308308
"deps": {
309309
"ds-test": "ds-test_0a5da56",
310310
"ds-weth": "ds-weth_b23b478",
311-
"dss-cdp-manager": "dss-cdp-manager_03f46a0",
312-
"dss-gem-joins": "dss-gem-joins_b91680b",
311+
"dss-cdp-manager": "dss-cdp-manager_306132d",
312+
"dss-gem-joins": "dss-gem-joins_123d6b7",
313313
"proxy-registry": "proxy-registry_981715a"
314314
},
315315
"name": "dss-proxy-actions",
316316
"repo": {
317-
"name": "dss-proxy-actions-6d6b293",
317+
"name": "dss-proxy-actions-5cf4634",
318318
"ref": "HEAD",
319-
"rev": "6d6b2932a12d5d7885c5dfcd711f991d7642a17f",
319+
"rev": "5cf46344070274ca59882d645bebf15589bdc87d",
320320
"url": "https://github.com/makerdao/dss-proxy-actions"
321321
}
322322
},
323-
"dss-vest_8b10556": {
323+
"dss-vest_50b7140": {
324324
"deps": {
325325
"ds-test": "ds-test_0a5da56"
326326
},
327327
"name": "dss-vest",
328328
"repo": {
329-
"name": "dss-vest-8b10556",
329+
"name": "dss-vest-50b7140",
330330
"ref": "HEAD",
331-
"rev": "8b105562e5c0858dafd80df5a1119c07d048a958",
331+
"rev": "50b71406ba686ffb963a722754cc5ea3a4f21364",
332332
"url": "https://github.com/makerdao/dss-vest"
333333
}
334334
},
335-
"dss_c666ab1": {
335+
"dss_17187f7": {
336336
"deps": {
337337
"ds-test": "ds-test_0a5da56",
338338
"ds-token": "ds-token_a5e709b",
339339
"ds-value": "ds-value_4049ecd"
340340
},
341341
"name": "dss",
342342
"repo": {
343-
"name": "dss-c666ab1",
343+
"name": "dss-17187f7",
344344
"ref": "HEAD",
345-
"rev": "c666ab1fdac4cb3dd8a8b4223f951a9773a64c55",
345+
"rev": "17187f7d47be2f4c71d218785e1155474bbafe8a",
346346
"url": "https://github.com/makerdao/dss"
347347
}
348348
},
349-
"dss_fb73e44": {
349+
"dss_38f618c": {
350350
"deps": {
351351
"ds-test": "ds-test_0a5da56",
352352
"ds-token": "ds-token_a5e709b",
353353
"ds-value": "ds-value_4049ecd"
354354
},
355355
"name": "dss",
356356
"repo": {
357-
"name": "dss-fb73e44",
357+
"name": "dss-38f618c",
358358
"ref": "v1.2",
359-
"rev": "fb73e4480c9d98d85f03c3a0b1d8d43b779f8c72",
359+
"rev": "38f618c54ff27d278eacc58d543e01bd08a88680",
360360
"url": "https://github.com/makerdao/dss"
361361
}
362362
},
@@ -420,17 +420,17 @@
420420
"url": "https://github.com/makerdao/flipper-mom"
421421
}
422422
},
423-
"ilk-registry_81ba973": {
423+
"ilk-registry_8ad3682": {
424424
"deps": {
425425
"ds-test": "ds-test_0a5da56",
426426
"ds-value": "ds-value_4049ecd",
427-
"dss": "dss_c666ab1"
427+
"dss": "dss_17187f7"
428428
},
429429
"name": "ilk-registry",
430430
"repo": {
431-
"name": "ilk-registry-81ba973",
431+
"name": "ilk-registry-8ad3682",
432432
"ref": "HEAD",
433-
"rev": "81ba973eac363ac0395e968144e886c73c1f4e3b",
433+
"rev": "8ad3682b2f3d1c719c3218f4620c0fbb657a800b",
434434
"url": "https://github.com/makerdao/ilk-registry"
435435
}
436436
},
@@ -583,20 +583,20 @@
583583
"ds-token": "ds-token_a5e709b",
584584
"ds-value": "ds-value_4049ecd",
585585
"ds-weth": "ds-weth_b23b478",
586-
"dsr-manager": "dsr-manager_f495973",
586+
"dsr-manager": "dsr-manager_0a48c2d",
587587
"dss-auto-line": "dss-auto-line_bff7e6c",
588-
"dss-cdp-manager": "dss-cdp-manager_03f46a0",
589-
"dss-chain-log": "dss-chain-log_83e7a01",
590-
"dss-deploy": "dss-deploy_8bdb323",
591-
"dss-deploy-1_2": "dss-deploy_4963763",
592-
"dss-deploy-pause-proxy-actions": "dss-deploy-pause-proxy-actions_9446eb9",
593-
"dss-flash": "dss-flash_ae57da2",
594-
"dss-gem-joins": "dss-gem-joins_b91680b",
595-
"dss-proxy-actions": "dss-proxy-actions_6d6b293",
596-
"dss-vest": "dss-vest_8b10556",
588+
"dss-cdp-manager": "dss-cdp-manager_306132d",
589+
"dss-chain-log": "dss-chain-log_90cf9c0",
590+
"dss-deploy": "dss-deploy_8b9bd85",
591+
"dss-deploy-1_2": "dss-deploy_45985a9",
592+
"dss-deploy-pause-proxy-actions": "dss-deploy-pause-proxy-actions_9344383",
593+
"dss-flash": "dss-flash_b8f8fdc",
594+
"dss-gem-joins": "dss-gem-joins_123d6b7",
595+
"dss-proxy-actions": "dss-proxy-actions_5cf4634",
596+
"dss-vest": "dss-vest_50b7140",
597597
"flash-killer": "flash-killer_7027492",
598598
"flipper-mom": "flipper-mom_3a57ea1",
599-
"ilk-registry": "ilk-registry_81ba973",
599+
"ilk-registry": "ilk-registry_8ad3682",
600600
"mkr-authority": "mkr-authority_fc19f8a",
601601
"multicall": "multicall_1e1b443",
602602
"osm": "osm_e36c874",

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ Below is the expected structure of such a config file:
8686
"flop_pad": "<Increase of lot size after `tick` in percentage (e.g. 50)>",
8787
"flop_ttl": "<Max time between bids in seconds>",
8888
"flop_tau": "<Max auction duration in seconds>",
89+
"flap_lid": "<Max amount of DAI that can be put up for sale at the same time in DAI unit (e.g. 1000000)>",
8990
"flash_max": "<Max DAI can be borrowed from flash loan module in DAI unit (e.g. 1000000)>",
9091
"flash_toll": "<Fee being charged from amount being borrow via flash loan module in percentage (e.g 0.1%)>",
9192
import: {

config/goerli.json

+1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
"flap_beg": "4",
1717
"flap_ttl": "1800",
1818
"flap_tau": "259200",
19+
"flap_lid": "150000",
1920
"flop_beg": "3",
2021
"flop_pad": "20",
2122
"flop_ttl": "21600",

config/main.json

+1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
"flap_beg": "2",
1717
"flap_ttl": "1800",
1818
"flap_tau": "259200",
19+
"flap_lid": "150000",
1920
"flop_beg": "3",
2021
"flop_pad": "20",
2122
"flop_ttl": "21600",

config/testchain.json

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
"flap_beg": "5",
1919
"flap_ttl": "10800",
2020
"flap_tau": "172800",
21+
"flap_lid": "150000",
2122
"flop_beg": "5",
2223
"flop_pad": "50",
2324
"flop_ttl": "10800",

libexec/base-deploy

+2
Original file line numberDiff line numberDiff line change
@@ -425,6 +425,8 @@ EOF
425425

426426
"$LIBEXEC_DIR"/setters/set-tau "flap"
427427

428+
"$LIBEXEC_DIR"/setters/set-flap-lid
429+
428430
"$LIBEXEC_DIR"/setters/set-beg "flop"
429431

430432
"$LIBEXEC_DIR"/setters/set-flop-pad

libexec/setters/set-flap-lid

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
#!/usr/bin/env bash
2+
3+
# Copyright (C) 2019-2021 Maker Ecosystem Growth Holdings, INC.
4+
5+
# This program is free software: you can redistribute it and/or modify
6+
# it under the terms of the GNU Affero General Public License as published by
7+
# the Free Software Foundation, either version 3 of the License, or
8+
# (at your option) any later version.
9+
10+
# This program is distributed in the hope that it will be useful,
11+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
12+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13+
# GNU Affero General Public License for more details.
14+
15+
# You should have received a copy of the GNU Affero General Public License
16+
# along with this program. If not, see <https://www.gnu.org/licenses/>.
17+
18+
# shellcheck source=lib/common.sh
19+
. "$LIB_DIR/common.sh"
20+
21+
# Get config variables
22+
CONFIG_FILE="$OUT_DIR/config.json"
23+
# Get addresses
24+
loadAddresses
25+
26+
log "SET FLAP LID:"
27+
28+
# Set general debt ceiling (if defined)
29+
lid=$(jq -r ".flap_lid | values" "$CONFIG_FILE")
30+
if [[ "$lid" != "" ]]; then
31+
lid=$(echo "$lid"*10^45 | bc)
32+
lid=$(seth --to-uint256 "${lid%.*}")
33+
calldata="$(seth calldata 'file(address,address,address,bytes32,uint256)' "$MCD_PAUSE" "$MCD_GOV_ACTIONS" "$MCD_FLAP" "$(seth --to-bytes32 "$(seth --from-ascii "lid")")" "$lid")"
34+
sethSend "$PROXY_DEPLOYER" 'execute(address,bytes memory)' "$PROXY_PAUSE_ACTIONS" "$calldata"
35+
fi

0 commit comments

Comments
 (0)