Skip to content

Commit

Permalink
archived spell
Browse files Browse the repository at this point in the history
  • Loading branch information
SidestreamIcedMango committed Sep 3, 2024
1 parent 68a0ea1 commit 24f8b34
Show file tree
Hide file tree
Showing 9 changed files with 6,583 additions and 0 deletions.
86 changes: 86 additions & 0 deletions archive/2024-09-05-DssSpell/DssSpell.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
// SPDX-FileCopyrightText: © 2020 Dai Foundation <www.daifoundation.org>
// SPDX-License-Identifier: AGPL-3.0-or-later
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program. If not, see <https://www.gnu.org/licenses/>.

pragma solidity 0.8.16;

import "dss-exec-lib/DssExec.sol";
import "dss-exec-lib/DssAction.sol";

import { GemAbstract } from "dss-interfaces/ERC/GemAbstract.sol";

interface ProxyLike {
function exec(address target, bytes calldata args) external payable returns (bytes memory out);
}

contract DssSpellAction is DssAction {
// Provides a descriptive tag for bot consumption
// This should be modified weekly to provide a summary of the actions
// Hash: cast keccak -- "$(wget 'https://raw.githubusercontent.com/makerdao/community/3c1ea8b373f3fc30885619ddcc8ee7aa2be0030a/governance/votes/Executive%20vote%20-%20September%205%2C%202024.md' -q -O - 2>/dev/null)"
string public constant override description =
"2024-09-05 MakerDAO Executive Spell | Hash: 0xf387f3329537d6495861cd05b824ef1e5d6d2c15e5e8f0ae68e0928d88b01f37";

// Set office hours according to the summary
function officeHours() public pure override returns (bool) {
return true;
}

// ---------- Rates ----------
// Many of the settings that change weekly rely on the rate accumulator
// described at https://docs.makerdao.com/smart-contract-modules/rates-module
// To check this yourself, use the following rate calculation (example 8%):
//
// $ bc -l <<< 'scale=27; e( l(1.08)/(60 * 60 * 24 * 365) )'
//
// A table of rates can be found at
// https://ipfs.io/ipfs/QmVp4mhhbwWGTfbh2BzwQB9eiBrQBKiqcPRZCaAxNUaar6
//
// uint256 internal constant X_PCT_RATE = ;

// ---------- Launch Project Funding ----------
address internal constant LAUNCH_PROJECT_FUNDING = 0x3C5142F28567E6a0F172fd0BaaF1f2847f49D02F;

// ---------- Contracts ----------
GemAbstract internal immutable MKR = GemAbstract(DssExecLib.mkr());

// ---------- Spark Proxy Spell ----------
// Spark Proxy: https://github.com/marsfoundation/sparklend-deployments/blob/bba4c57d54deb6a14490b897c12a949aa035a99b/script/output/1/primary-sce-latest.json#L2
address internal constant SPARK_PROXY = 0x3300f198988e4C9C63F75dF86De36421f06af8c4;
address internal constant SPARK_SPELL = 0x668C84584Ef8EeEd6BFb4FFB2a4Fa03231F8b241;

function actions() public override {
// ---------- Launch Project Funding ----------
// Forum: https://forum.makerdao.com/t/utilization-of-the-launch-project-under-the-accessibility-scope/21468/22
// MIP: https://mips.makerdao.com/mips/details/MIP108#9-1-launch-project-budget

// Launch Project - 9535993 DAI - 0x3C5142F28567E6a0F172fd0BaaF1f2847f49D02F
DssExecLib.sendPaymentFromSurplusBuffer(LAUNCH_PROJECT_FUNDING, 9_535_993);

// Launch Project - 2630.00 MKR - 0x3C5142F28567E6a0F172fd0BaaF1f2847f49D02F
MKR.transfer(LAUNCH_PROJECT_FUNDING, 2630.00 ether); // Note: 'ether' is a keyword helper, only MKR is transferred here

// ---------- Spark Proxy Spell ----------
// Forum: https://forum.makerdao.com/t/aug-23-2024-proposal-changes-to-spark-for-upcoming-spell/24940
// Poll: https://vote.makerdao.com/polling/QmW55juU
// Poll: https://vote.makerdao.com/polling/QmQa73Cc

// Trigger Spark Proxy Spell at 0x668C84584Ef8EeEd6BFb4FFB2a4Fa03231F8b241
ProxyLike(SPARK_PROXY).exec(SPARK_SPELL, abi.encodeWithSignature("execute()"));
}
}

contract DssSpell is DssExec {
constructor() DssExec(block.timestamp + 30 days, address(new DssSpellAction())) {}
}
Loading

0 comments on commit 24f8b34

Please sign in to comment.