Skip to content

Commit

Permalink
Merge pull request #25 from BibliothecaDAO/deploy-velords
Browse files Browse the repository at this point in the history
velords mainnet deploy logs
  • Loading branch information
credence0x authored Sep 8, 2024
2 parents 4f00a21 + e936fca commit c6b899c
Show file tree
Hide file tree
Showing 6 changed files with 123 additions and 2 deletions.
65 changes: 65 additions & 0 deletions veLords/mainnet_deploy.ansi
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
Compiling lordship v0.1.0 (/Users/credence/Desktop/StakedRealm/veLords/Scarb.toml)
Finished release target(s) in 9 seconds
/Users/credence/Desktop/StakedRealm/velords/scripts/deployment
____ _
| \ ___ ___| |___ _ _
| | | -_| . | | . | | |
|____/|___| _|_|___|_ |
|_| |___|



Contract is lordship_velords.contract_class.json...



Declaring Lordship veLords...


- Class Hash: 0x1cb93e4706c368e69d996310ab93142f55f8b01b6156d4158099194bd05857c
- Tx Hash: https://voyager.online/tx/0x968e19dc6f87a76624116dd6cace3980dd72e41aa1e567c5dbeb6f982df7fd)

Deploying Lordship veLords ...


Tx hash: https://voyager.online/tx/0x4750c4b96e26ca3c8a9128625cf3f667754c62bb65e8dc4615d7acd99d0539e)
Contract Address: 0x47230028629128ac5bfbb384d32f925e70e329b624fc5d82e9c60f5746795cd


"addresses/prod/Lordship veLords.json" has been saved or overwritten



Contract is lordship_reward_pool.contract_class.json...



Declaring Lordship veLords Reward Pool...


- Class Hash: 0x1f87f12c76e338482d4afd0d8618decc288a318f7fe6e617e522e42895a6bcc
- Tx Hash: https://voyager.online/tx/0x7944416caf677795ef4c99e5f31ce4a9c86366976de7e1922bb19923eb03dc5)

Deploying Lordship veLords Reward Pool ...


Tx hash: https://voyager.online/tx/0x635091b867e9782e6cc3f66497716c7a467e0e56529d94f6eb41c5f3f6f60aa)
Contract Address: 0x91b13b83e5c34112aa066a844d4cbe6af99b3d134293829ca1730ea4869a71


"addresses/prod/Lordship veLords Reward Pool.json" has been saved or overwritten

Setting Reward Pool ...


Tx hash: https://voyager.online/tx/0x10aa65c66091948f5a7b293aab1f289bf38dc8ffeacdef8f06db8334bd7d29d)
Successfully set reward pool in veLords



Setting Final Admin in Reward Pool and VeLords ...


Tx hash: https://voyager.online/tx/0x754446832ba669d6d32dd8d0d3dc2f2657206440606bc1fa84aa91a86605a94)
Successfully set final admin in reward pool and veLords to 270623063481960266090259869745487843733262104959603938883672164036750381395

3 changes: 2 additions & 1 deletion veLords/scripts/deployment/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ export STARKNET_ACCOUNT_PRIVATE_KEY=

export LORDS_TOKEN=0x0
export VELORDS_ADMIN=0x0
export REWARD_POOL_ADMIN=0x0
export REWARD_POOL_ADMIN=0x0
export FINAL_ADMIN=0x00992acf50dba66f87d8cafffbbc3cdbbec5f8f514b5014f6d4d75e6b8789153
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"address": "0x91b13b83e5c34112aa066a844d4cbe6af99b3d134293829ca1730ea4869a71",
"calldata": [
"0x5ae3677da993adf5f613b4c04e4ba6b518a4221a5ef93948aec805e81bda8dc",
"0x47230028629128ac5bfbb384d32f925e70e329b624fc5d82e9c60f5746795cd",
"0x124aeb495b947201f5fac96fd1138e326ad86195b98df6dec9009158a533b49",
1725721120
],
"deployed_at": 1725721144075,
"deployed_at_readable": "Sat, 07 Sep 2024 14:59:04 GMT"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"address": "0x47230028629128ac5bfbb384d32f925e70e329b624fc5d82e9c60f5746795cd",
"calldata": [
"0x124aeb495b947201f5fac96fd1138e326ad86195b98df6dec9009158a533b49",
"0x5ae3677da993adf5f613b4c04e4ba6b518a4221a5ef93948aec805e81bda8dc"
],
"deployed_at": 1725721094745,
"deployed_at_readable": "Sat, 07 Sep 2024 14:58:14 GMT"
}
34 changes: 34 additions & 0 deletions veLords/scripts/deployment/libs/deploy.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,37 @@ export const setRewardPoolInVeLords = async (veLords, rewardPool) => {

console.log("Successfully set reward pool in veLords".green, "\n\n");
};


export const setFinalAdminInRewardPoolAndVeLords = async (veLords, rewardPool) => {
///////////////////////////////////////////////////////////
///// Set Final Admin in Reward Pool and VeLords ////
///////////////////////////////////////////////////////////

const account = getAccount();
console.log(`\n Setting Final Admin in Reward Pool and VeLords ... \n\n`.green);

let FINAL_ADMIN = BigInt(process.env.FINAL_ADMIN);
const contract = await account.execute([
{
contractAddress: veLords,
entrypoint: "transfer_ownership",
calldata: [FINAL_ADMIN],
},
{
contractAddress: rewardPool,
entrypoint: "transfer_ownership",
calldata: [FINAL_ADMIN],
}
]);

// Wait for transaction
let network = getNetwork(process.env.STARKNET_NETWORK);
console.log(
"Tx hash: ".green,
`${network.explorer_url}/tx/${contract.transaction_hash})`
);
await account.waitForTransaction(contract.transaction_hash);

console.log(`Successfully set final admin in reward pool and veLords to ${FINAL_ADMIN}`.green, "\n\n");
};
3 changes: 2 additions & 1 deletion veLords/scripts/deployment/startDeploy.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import colors from "colors";
import { deployRewardPool, deployVeLords, setRewardPoolInVeLords } from "./libs/deploy.js";
import { deployRewardPool, deployVeLords, setFinalAdminInRewardPoolAndVeLords, setRewardPoolInVeLords } from "./libs/deploy.js";

const main = async () => {
console.log(` ____ _ `.red);
Expand All @@ -12,6 +12,7 @@ const main = async () => {
let veLordsAddress = await deployVeLords();
let rewardPoolAddress = await deployRewardPool(veLordsAddress);
await setRewardPoolInVeLords(veLordsAddress, rewardPoolAddress)
await setFinalAdminInRewardPoolAndVeLords(veLordsAddress, rewardPoolAddress)
};

main();

0 comments on commit c6b899c

Please sign in to comment.