makerdao / spells-mainnet

Staging repo for MakerDAO weekly executive spells
GNU Affero General Public License v3.0
122 stars 50 forks source link

`cast-on-tenderly` script is not working properly #407

Closed SidestreamStrongStrawberry closed 6 months ago

SidestreamStrongStrawberry commented 6 months ago

Goal

Investigate why cast-on-tenderly script is not working properly & find fix

Context

Currently cast-on-tenderly throws errors on 2 steps. (

  1. in createTenderlyTestnet function it throws
    
    file:///Users/yunda-eun/Sidestream/maker-mainnet-spells/scripts/cast-on-tenderly/index.js:78
        rpcUrlPrivate: rpcEndpointPrivate.uri,
                                          ^

TypeError: Cannot read properties of undefined (reading 'uri') at createTenderlyTestnet (file:///Users/yunda-eun/Sidestream/maker-mainnet-spells/scripts/cast-on-tenderly/index.js:78:43) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async castOnTenderly (file:///Users/yunda-eun/Sidestream/maker-mainnet-spells/scripts/cast-on-tenderly/index.js:168:42)


- post request to `/testnet/container` worked but the return data doesn't seem to match with expectation 

2. in `publishTenderlyTestnet` function it throws 

file:///Users/yunda-eun/Sidestream/maker-mainnet-spells/scripts/cast-on-tenderly/index.js:116 const explorerUrlPublic = https://dashboard.tenderly.co/explorer/vnet/${rpcEndpointPublic.id}; ^

TypeError: Cannot read properties of undefined (reading 'id') at publishTenderlyTestnet (file:///Users/yunda-eun/Sidestream/maker-mainnet-spells/scripts/cast-on-tenderly/index.js:116:96) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async castOnTenderly (file:///Users/yunda-eun/Sidestream/maker-mainnet-spells/scripts/cast-on-tenderly/index.js:210:5)


Also after 

making tenderly testnet "2cb2028f-fa62-4a50-8ac9-6bf36b064058" public... tenderly testnet is now public and discoverable


was printed on console, the testnet setting wasn't updated.

- put request to `/testnet/container/${testnetId}` didn't make page public and the return data doesn't seem to match with expectation