Skip to content

Commit

Permalink
include proceeds recipient during deploy
Browse files Browse the repository at this point in the history
  • Loading branch information
okwme committed Sep 26, 2024
1 parent 5b24318 commit 072be54
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions scripts/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { exportCallDataGroth16 } from './circuits.js'
const __dirname = path.resolve()

const correctPrice = ethers.utils.parseEther('0.0025')
const proceedsRecipient = '0x6421b5Dd0872a23f952cA43d18e79A9690B2bD53' // Safe on Base

const proverTickIndex = {
2: 250,
Expand Down Expand Up @@ -211,6 +212,10 @@ const deployAnybodyProblemV1 = async (options) => {
` with speedrunsAddress ${Speedruns.address} and externalMetdataAddress ${ExternalMetadata.address} and verifiers ${verifiers} and verifiersTicks ${verifiersTicks} and verifiersBodies ${verifiersBodies} and anybodyProblemV0Address ${AnybodyProblemV0.address}`
)

// update AnybodyProblemV1 with proceedsRecipient
await anybodyProblem.updateProceedsRecipient(proceedsRecipient)
log(`AnybodyProblem ProceedsRecipient updated to ${proceedsRecipient}`)

// update Speedruns
await Speedruns.updateAnybodyProblemAddress(anybodyProblem.address)
log(
Expand Down Expand Up @@ -504,6 +509,10 @@ const deployContractsV0 = async (options) => {
` with speedrunsAddress ${speedruns.address} and externalMetdataAddress ${externalMetadata.address} and verifiers ${verifiers} and verifiersTicks ${verifiersTicks} and verifiersBodies ${verifiersBodies}`
)

// update AnybodyProblemV1 with proceedsRecipient
await anybodyProblemV0.updateProceedsRecipient(proceedsRecipient)
log(`AnybodyProblemV0 ProceedsRecipient updated to ${proceedsRecipient}`)

// update Speedruns
await speedruns.updateAnybodyProblemAddress(anybodyProblemV0.address)
log('AnybodyProblemV0 address updated in Speedruns')
Expand Down

0 comments on commit 072be54

Please sign in to comment.