Hi,
I want to deploy a simple counter:
// SPDX-License-Identifier: SEE LICENSE IN LICENSE
pragma solidity 0.8.20;
contract Counter {
uint public count;
function inc() external {
count += 1;
}
function get() external view returns (uint) {
return count;
}
}
Hardhat deploy script:
async function main() {
const [deployer] = await ethers.getSigners();
console.log("Deploying contracts with the account:", deployer.address);
const counter = await ethers.deployContract("Counter");
console.log("Counter address:", await counter.getAddress());
}
main()
.then(() => process.exit(0))
.catch((error) => {
console.error(error);
process.exit(1);
});
hardhat.config.js is set to compiler verion 0.8.20.
During deploy i receive following error: ProviderError: stack-underflow
This only happens with solidity version above ^0.8.19, any ideas ?