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

Improve _updateStatus scale-down #58

Merged
merged 3 commits into from
Mar 5, 2024
Merged

Improve _updateStatus scale-down #58

merged 3 commits into from
Mar 5, 2024

Conversation

MrToph
Copy link
Collaborator

@MrToph MrToph commented Mar 5, 2024

Changes to _updateStatus:

  • removed the final numerator computation as this variable is never read after it has been written
  • we only need to reduce the new final filled fraction, the numerator fill value becomes irrelevant in this function. This means we can just compute the gcd of filledNumerator and denominator.

@0age
Copy link
Contributor

0age commented Mar 5, 2024

oh interesting, this breaks some of the direct tests; it's possible that we need to review those and update the values as scaleDown is more permissive with this change

@MrToph
Copy link
Collaborator Author

MrToph commented Mar 5, 2024

I see, some of these values are currently hardcoded in tests. I can just update them. 6/10 is the same as 3/5.

@0age 0age merged commit fbb182b into main Mar 5, 2024
4 checks passed
@0age 0age deleted the gas-updateStatus-scaledown branch March 5, 2024 17:13
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