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

Provide feesAccrued to subscriber.notifyModifyLiquidity #282

Merged
merged 3 commits into from
Aug 6, 2024

Conversation

saucepoint
Copy link
Collaborator

@saucepoint saucepoint commented Aug 6, 2024

Related Issue

Provide feesAccrued to subscribers. Considering subscribers are staking modules, this will be may be valuable information

Description of changes

  • Pass feesAccrued to subscribers in notifyModifyLiquidity

Resolved Question:

  • Do we need to provide liquidityChange AND liquidityDelta, it's possible to convert between the two via LiquidityAmounts
  • liquidityChange and liquidityDelta are interchangeable assuming the hook did not adjust deltas. Regardless, we believe liquidityChange to be the more valuable information for staking modules

@saucepoint saucepoint added the posm position manager label Aug 6, 2024
Copy link
Member

@snreynolds snreynolds left a comment

Choose a reason for hiding this comment

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

i think looks good to me, i am thinking we dont need to pass the liquidityDelta but either way Im ok with

@@ -345,7 +346,7 @@ contract PositionManager is
);

if (positionConfigs.hasSubscriber(uint256(salt))) {
_notifyModifyLiquidity(uint256(salt), config, liquidityChange);
_notifyModifyLiquidity(uint256(salt), config, liquidityChange, liquidityDelta, feesAccrued);
Copy link
Member

Choose a reason for hiding this comment

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

I am leaning on taking out liquidityDelta?

@saucepoint saucepoint changed the title Provided liquidityDelta and feesAccrued to subscriber.notifyModifyLiquidity Provide feesAccrued to subscriber.notifyModifyLiquidity Aug 6, 2024
@snreynolds snreynolds merged commit bf3b8ad into main Aug 6, 2024
3 checks passed
@snreynolds snreynolds deleted the posm-notifyModifyLiquidity-feesAccrued branch August 6, 2024 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
posm position manager
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants