OpenZeppelin / openzeppelin-contracts

OpenZeppelin Contracts is a library for secure smart contract development.
https://openzeppelin.com/contracts
MIT License
24.96k stars 11.79k forks source link

Set EVM to Paris for the release process #4503

Open Amxx opened 1 year ago

Amxx commented 1 year ago

Following https://github.com/OpenZeppelin/openzeppelin-contracts/issues/4489#issuecomment-1662305827

Since 0.8.20, the default EVM target is shanghai, which includes the push0 oppcode. When releasing the package, with artefacts that the upgrades plugin will rely on, we should not target such a recent EVM version, as the produced bytecode will not be supported by many chains.

In hardhat.config.json we should add a target/compilerTarget flag, that by default would be shanghai. When doing the release process, that envvar should be set to paris

Amxx commented 1 year ago

@frangio @ericglau

frangio commented 1 year ago

Let's set up a matrix to run tests on both paris and shanghai. The only one that doesn't need this is the coverage check.