Skip to content
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

Support open-zeppelin upgrades validations #358

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

fullkomnun
Copy link
Contributor

@fullkomnun fullkomnun commented Aug 1, 2022

Fixes: #65
Fixes: #355

Builds on top of previous efforts

  • Overrides solc compile tasks to inject open-zeppelin's validations as part of compilation pipeline
  • Avoids adding @openzeppelin/hardhat-upgrades hardhat plugin as a dependency as suggested here and instead copies-over minimal amount of glue code
  • Adds a dependency on @openzeppelin/upgrades-core and @types/proper-lockfile (used to lock cache file while writing validations)
  • Does not rely on open-zeppelin's ".openzeppelin" manifest files and instead uses hardhat-deploy APIs and deployment files as suggested here

TODO

  • Check how to handle layout versioning
  • Check with complex storage variable types (structs)
  • Check with complex hierarchical (multiple inheritance) storage changes

Possible Enhancements

  • Letting users opt-out of validation entirely or on a per-contract basis
  • Give users more fine-grained control over which validation rules are enforced
    (Users may currently disable some checks)

@RoseRompkxm
Copy link

why is this still not merged? I think it's very useful

@noyyyy
Copy link

noyyyy commented Nov 10, 2022

Any update on this? @wighawag

@0xlucian
Copy link

Hey any update on that? Wold be really useful

@fullkomnun
Copy link
Contributor Author

@wighawag I can rebase or re-create it on top of the latest 'main' branch it that helps..

@waynehoover
Copy link

@wighawag This is essential to upgrading contracts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants