Explorar el Código

upgrade contract fix: artifacts bytecode error resolve

nidhi-singh02 hace 1 mes
padre
commit
f842d44c21

+ 1 - 1
contract_manager/scripts/deploy_evm_contract.ts

@@ -38,7 +38,7 @@ async function main() {
   const address = await chain.deploy(
     toPrivateKey(argv["private-key"]),
     artifact["abi"],
-    artifact["bytecode"],
+    artifact["bytecode"].object, // As per the artifacts generated by forge, bytecode is an object with an 'object' property
     argv["deploy-args"] || [],
   );
 

+ 1 - 1
contract_manager/scripts/upgrade_evm_entropy_contracts.ts

@@ -75,7 +75,7 @@ async function main() {
             return contract.chain.deploy(
               toPrivateKey(argv["private-key"]),
               artifact["abi"],
-              artifact["bytecode"],
+              artifact["bytecode"].object, // As per the artifacts generated by forge, bytecode is an object with an 'object' property
               [],
               2,
             );

+ 1 - 1
contract_manager/scripts/upgrade_evm_pricefeed_contracts.ts

@@ -45,7 +45,7 @@ async function main() {
       return chain.deploy(
         toPrivateKey(argv["private-key"]),
         artifact["abi"],
-        artifact["bytecode"],
+        artifact["bytecode"].object, // As per the artifacts generated by forge, bytecode is an object with an 'object' property
         [],
       );
     });