-
Notifications
You must be signed in to change notification settings - Fork 505
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
Replace implementation+etch pattern with Create2Deployer #59
Comments
Cool! I think I like this overall. Some thoughts:
tagging @ewilz to see if she has any more thoughts? |
Wrote a script to check all the ~major chains. Looks like most chains do have Arachnid's deployer proxy at You are correct that this issue is more about testing patterns and infra. Naming the utility library
|
given hook flags are now 14 bits, mining is too slow for tests reference PR for deployCodeTo |
Component
General design optimization (improving efficiency, cleanliness, or developer experience)
Describe the suggested feature and problem it solves.
Arachnid's create2 deployer proxy is now available on anvil and forge test by default
This allows us to deterministically mine + deploy arbitrary contracts without the need for a factory or Implementation wrapper that overrides
validateHookAddress
.A minor change but it reduces repo clutter+boilerplate by adding consistent abstractions around hook development and testing
Describe the desired implementation.
Currently you need to define an Implementation which overrides the flag checks, and then etch the bytecode to a correctly-flagged address:
Abstracting the create2 deployer proxy, we get a much cleaner devex:
Describe alternatives.
N/A
Additional context.
Already works and is available here:
https://github.com/saucepoint/v4-template/blob/main/test/Counter.t.sol#L30-L37
and
https://github.com/saucepoint/v4-template/blob/main/test/utils/HookDeployer.sol
I'm happy to PR and update all the tests to the new pattern!
The text was updated successfully, but these errors were encountered: