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: reset lockedQuote even when nothing will be auctioned #8070

Merged
merged 3 commits into from
Jul 25, 2023

Conversation

Chris-Hibbert
Copy link
Contributor

closes: #8041

Description

When there were no vaults to be liquidated, we exited early, and missed the step of reseting the locked quote. This fixes that oversight.

Security Considerations

None

Scaling Considerations

None

Documentation Considerations

None

Testing Considerations

Appropriate tests were sensitive to the change and had to be updated.

@Chris-Hibbert Chris-Hibbert added bug Something isn't working Vaults VaultFactor (née Treasury) labels Jul 19, 2023
@Chris-Hibbert Chris-Hibbert requested a review from turadg July 19, 2023 22:16
@Chris-Hibbert Chris-Hibbert self-assigned this Jul 19, 2023
@@ -1094,6 +1094,7 @@ export const prepareVaultManagerKit = (
state.lockedQuote = undefined;

if (vaultData.getSize() === 0) {
void helper.writeMetrics();
Copy link
Member

Choose a reason for hiding this comment

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

on line 1160 it awaits before returning. Which is correct?

also that one superfluously references facets.

Copy link
Contributor Author

@Chris-Hibbert Chris-Hibbert Jul 19, 2023

Choose a reason for hiding this comment

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

on line 1160 it awaits before returning. Which is correct?

There were more calls that said void than await, so ... No, that's not a good justification.

I don't see any reason that the calling environment wants to respond to the result or wait for it to finish, so I changed them all to void.

also that one superfluously references facets.

fixed

await aethVaultMetrics.assertChange({
lockedQuote: null,
Copy link
Member

Choose a reason for hiding this comment

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

👍

@Chris-Hibbert Chris-Hibbert force-pushed the 8041-resetLockedQuote branch from 9e920c3 to c5b4e33 Compare July 21, 2023 21:47
@Chris-Hibbert Chris-Hibbert added this pull request to the merge queue Jul 25, 2023
Merged via the queue into master with commit 5bd1690 Jul 25, 2023
@Chris-Hibbert Chris-Hibbert deleted the 8041-resetLockedQuote branch July 25, 2023 18:45
mhofman pushed a commit that referenced this pull request Aug 7, 2023
fix: reset lockedQuote even when nothing will be auctioned
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Vaults VaultFactor (née Treasury)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Vaults - lockedQuote not resetting when no vaults to auction
2 participants