-
Notifications
You must be signed in to change notification settings - Fork 7
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
Op Farms #1
base: master
Are you sure you want to change the base?
Conversation
v1.9.1
No need for farm check, minor changes Co-authored-by: telome <[email protected]>
Co-authored-by: sunbreak1211 <[email protected]>
assertEq(dss.chainlog.getAddress("FARM_PROXY_TKA_TKB_BASE"), address(l1Proxy)); | ||
assertEq(dss.chainlog.getAddress("REWARDS_DIST_TKA_TKB_BASE"), cfg.vestedRewardsDistribution); | ||
|
||
l2Domain.relayFromHost(true); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just consider this relayFromHost
would also be executing the L2 side of the spell for the Bridge set up. Nothing really wrong with that but doesn't get isolated in the setupGateways
function as was probably the intention.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This code is the same as in arbitrum-farms
.
For some reason when adding l2Domain.relayFromHost(false);
at the end of setupGateways
the test fails with a message of "revert: CrossDomainMessenger: message has already been relayed".
I think @telome saw something similar, but not sure.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok yeah let's leave this open for now. It doesn't affect the audit as not in the scope anyway.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still not sure what exactly is the root cause of the issue but there seems to be some bug in foundry that causes the exit from setUp()
to incorrectly restore the storage of OptimismDomain
. For now a simple workaround could be to avoid using setUp()
. For example, renaming setUp()
to setUpFarm()
and calling setUpFarm()
at the beginning of distribute()
avoids the issue.
Minor changes Co-authored-by: sunbreak1211 <[email protected]>
Co-authored-by: telome <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to send to audit (minor note that op-token-bridge can be updated again to its most recent commit).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
* Remove <= type(uint224).max check * stakingToken => l2StakingToken * Update lib/op-token-bridge
--------- Co-authored-by: telome <[email protected]>
No description provided.