v0.7.0
This is the very first release of the OpenZeppelin Contracts for Cairo 1+, and the result of ~10 months of very hard work.
It’s been a long way, and now the end of the transition feels near. A new stage of maturity is ahead 🌺🚀.
Usage
Install the library as a scarb dependency:
[dependencies]
openzeppelin = { git = "https://github.com/OpenZeppelin/cairo-contracts.git", tag = "v0.7.0" }
It requires scarb 0.7.0 and supports Cairo 2.2.0.
What has changed?
Most things! This is a brand new library written in a new language with a new type system. It exposes a new API and usage model (no more extensibility pattern), which will be continually improved.
The feature set is pretty much the same as previous versions with few notable differences:
ERC1155
andUniversalDeployer
(UDC) are still in development- no
EthAccount
library (yet) - almost no presets like
ERC20Upgradeable
,ERC721Mintable
, etc. (yet) - upgrades are now based on the
replace_class
syscall- no
Proxy
module either (can’t be implemented in Cairo 1+)
- no
This library also:
- uses SRC5 instead of ERC165 for contract introspection
- follows the great interface migration plan implementing dual interfaces (snake and camel case ones), while also providing dual-case dispatchers to interface with contracts implementing either standard
- is distributed as a scarb package
What’s in it?
This release candidate includes a revamped docsite along with the following modules:
- Account
- Upgrades
- Introspection module (SRC5)
- Dual interface ABI dispatchers
- Tokens
- ERC20
- ERC721
- Access
- AccessControl
- Ownable
- Security
- Pausable
- Initializable
- Reentrancy guard
Acknowledgements
by @martriay
The main heroes of this story are @ericnordelo and @andrew-fleming. Over 10 months of relentless work, design, discussions, reviews back and forth, hitting the wall many times with the tooling, language, bugs, missing features. None of that stopped them. And here's the result, for the entire ecosystem to build and enjoy. Thank you.
Also thank you very much to our community of contributors, with special mention for recent contributions to @milancermak who contributed not only code but also ideas, @Amxx, @frangio, @maciektr and the scarb team, and @bal7hazar. This is thanks to you too.