-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: could not coalesce error (error={ "code": -32000, "data": { "hash": #6319
Comments
i want fix it too more then 2 days stuck on this section :( |
Any update regarding this? Currently stuck with this issue. |
Dear leave this section level 5 or take this section level 5 only for take rules go to next section level 6 hardhat but change endpoint api of blockchain I think alchemy no longer use for free must purchase try other services and about codes are little change it exp: simpleStorage.address no longer use it try change to simpleStorage.target and deployed wait(1) are change it too |
As solidity 0.8.20 introduced PUSH0 opcode which is supported by Ethereum mainnet only. So better, use solidity version 0.8.7 and solac@0.8.7 and the error will resolved. (Use older version of solidity as well as solac) Reference: https://www.zaryabs.com/push0-opcode/ |
Lesson 05 :
I got this error while running deploy.js
here is the code i'am runing :
`const ethers = require("ethers");
const fs = require("fs-extra"); // to read from other files
async function main() {
// http://192.168.1.73:8545
// the way to connect to our local blockchai
const overrides = {
gasLimit: 6721975, // Adjust the gas limit as needed
gasPrice: ethers.parseUnits("20000000000", "wei"), // Adjust the gas price as needed
};
const provider = new ethers.JsonRpcProvider("http://192.168.1.73:7545");
const wallet = new ethers.Wallet(
"0x--------------------------------------------------------------------------------------", // private key hidden !
provider
);
const abi = fs.readFileSync("./SimpleStorage_sol_SimpleStorage.abi", "utf8");
const binary = fs.readFileSync(
"./SimpleStorage_sol_SimpleStorage.bin",
"utf8"
);
const contractFactory = new ethers.ContractFactory(abi, binary, wallet);
console.log("----------- contract factory -----------------------");
console.log("Deploying, please wait ... ");
const contract = await contractFactory.deploy(overrides);
await contract.deploymentTransaction.wait(1);
const currentFavoriteNumber = await contract.retrieve();
console.log(currentFavoriteNumber);
}
main()
.then(() => process.exit(0))
.catch((error) => {
console.log("error", error);
process.exit(1);
});
`
### Remark :
the deployment transaction is sent correctly and i can see it in Ganache.
But i got this error in the console of VSC.
Does anyone have an idea how to fix this issue ?
The text was updated successfully, but these errors were encountered: