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

Fix: Reseed Whitelist #1067

Merged
merged 9 commits into from
Sep 11, 2024
Merged

Fix: Reseed Whitelist #1067

merged 9 commits into from
Sep 11, 2024

Conversation

nickkatsios
Copy link
Contributor

This pr addresses the BeanstalkPrice contract failing along with whitelist data errors in the reseed.

  • Update ReseedWhitelist.sol to set the oracle implementation for the non bean token in the well instead of the well lp token.
  • Fix oracle settings in the whitelisted tokens json and add mocks.
  • Perform a small swap in addLiquidity and transfer to avoid pump NotInitialized() error.
  • Extract the newly added evaluation parameters and append them in the globals json.

@nickkatsios nickkatsios changed the title Reseed Whitelist Fix Fix: Reseed Whitelist Sep 5, 2024
@Brean0
Copy link
Contributor

Brean0 commented Sep 9, 2024

lgtm!

Copy link
Contributor

@Brean0 Brean0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small comment, otherwise lgtm!

await well
.connect(account)
.addLiquidity([beanAmounts[i], nonBeanAmounts[i]], 0, L2Beanstalk, MAX_UINT256);
// perform a swap to update the well pumps and avoid "NotInitialized" error.
await well.connect(account).swapFrom(bean.address, token.address, to6("1"), 0, account.address, MAX_UINT256);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

apologies, instead of swapping 1 bean here, I think we should call it with 0 beans instead (which should initialize the pump as well)

I would do this with addLiquidity(with 0) as thats what was done in the past.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed here and it worked: 92a65bb. Merging this now.

@nickkatsios nickkatsios merged commit 8b240c2 into dr-t-remediations Sep 11, 2024
1 check passed
@nickkatsios nickkatsios deleted the reseed-whitelist-fix branch September 11, 2024 07:52
@nickkatsios nickkatsios mentioned this pull request Sep 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants