Skip to content

Comments

feat: fund delegate#335

Open
Yolley wants to merge 4 commits intomasterfrom
feat/fund_delegate
Open

feat: fund delegate#335
Yolley wants to merge 4 commits intomasterfrom
feat/fund_delegate

Conversation

@Yolley
Copy link
Collaborator

@Yolley Yolley commented Feb 16, 2026

  • feat: export createFundDelegate - allows periodical automated top ups for reward pools with Dynamic APY;
  • chore: update README to outline auto-unstake and fund-delegate features;

@github-actions
Copy link

github-actions bot commented Feb 16, 2026

Alpha versions of packages are published 📦

PR: #335
Version: 11.1.0-alpha.p335.775cce7
NPM: https://www.npmjs.com/package/@streamflow/common/v/11.1.0-alpha.p335.775cce7

Copy link
Contributor

@dperdic-streamflow dperdic-streamflow left a comment

Choose a reason for hiding this comment

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

Lgtm, just fix the comment

};
}

async prepareCreateFundDelegateInstructions(
Copy link
Contributor

Choose a reason for hiding this comment

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

since it's publicly accessible add an explicit return type

Copy link
Contributor

Choose a reason for hiding this comment

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

one more thing, some checks would be nice here since the protocol has these

startTs must not be in the past
period must be >= 1 day and <= expiry duration
expiryTs must be after startTs

Copy link
Collaborator Author

@Yolley Yolley Feb 16, 2026

Choose a reason for hiding this comment

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

But all these checks are done on the protocol side. And we have some error extraction.

Copy link
Contributor

Choose a reason for hiding this comment

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

I was thinking to make it more dev friendly since this is public so we don't get unnecessary questions

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

And with typing the prepare it would probably require a full refactoring - we never typed prepare... method. 🌚

I've added the interface, only for this method now tho.

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