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

Harmonize callbacks interfaces (250) #250

Merged
merged 3 commits into from
Aug 11, 2023

Conversation

MathisGD
Copy link
Contributor

@MathisGD MathisGD commented Aug 9, 2023

Attempt to fix #245, with the following rationale:

  • we should not pass data that can be known by the user at low cost
  • we put amount everywhere because it is mandatory in repay and liquidate, for harmonization

@MathisGD MathisGD self-assigned this Aug 9, 2023
@MathisGD MathisGD requested review from a team, Rubilmax, MerlinEgalite, pakim249CAL, Jean-Grimal, makcandrov and QGarchery and removed request for a team August 9, 2023 13:04
@MathisGD MathisGD marked this pull request as ready for review August 9, 2023 13:04
Copy link
Collaborator

@Rubilmax Rubilmax left a comment

Choose a reason for hiding this comment

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

I believe we're removing callback parameters that cost 100s of gas passing while it can greatly improve some (but not all, perhaps not even the majority of) integrators' lives... I really don't get where we're going

test/forge/Blue.t.sol Show resolved Hide resolved
src/interfaces/IBlueCallbacks.sol Outdated Show resolved Hide resolved
@MathisGD
Copy link
Contributor Author

Closing as Rubilmax, still one of the biggest Blue's integrator, is against

@MathisGD MathisGD closed this Aug 10, 2023
@MathisGD MathisGD deleted the refactor/callbacks-interface branch August 10, 2023 11:46
@MathisGD MathisGD restored the refactor/callbacks-interface branch August 10, 2023 16:20
@MathisGD MathisGD reopened this Aug 10, 2023
@MathisGD MathisGD changed the title refactor callbacks interfaces Harmonize callbacks interfaces (250) Aug 10, 2023
@MathisGD MathisGD requested a review from Rubilmax August 11, 2023 07:21
Copy link
Collaborator

@Rubilmax Rubilmax left a comment

Choose a reason for hiding this comment

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

This code works, but I didn't change my mind:

we're removing callback parameters that cost 100s of gas passing while it can greatly improve some (but not all, perhaps not even the majority of) integrators' lives

EDIT: it's not a big deal

@MerlinEgalite MerlinEgalite merged commit 827096e into main Aug 11, 2023
4 checks passed
@MerlinEgalite MerlinEgalite deleted the refactor/callbacks-interface branch August 11, 2023 08:09
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.

Should we pass the token address to the callback functions ?
5 participants