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

Update appconfig generation script to use new reward system #1741

Merged
merged 6 commits into from
Jan 28, 2025

Conversation

DannyDelott
Copy link
Contributor

@DannyDelott DannyDelott commented Jan 28, 2025

This PR removes the rewardFn field from YieldSourceConfig, as the frontend and appconfig now fully rely on the new reward system. 🎉

For example, adding liquidity to the KelpDAO rseth pool earns both Linea points and Hypervue miles, as defined in appconfig:

rewards: {
   "hyperdrive:add-liquidity:59144:0xB56e0Bf37c4747AbbC3aA9B8084B0d9b9A336777":
      ["lineaRewards", "hypervueMilesRewards"],
}

And to get the resolver function for this you can do:

import { getRewardConfig } from '@delvtech/hyperdrive-appconfig';

const { resolver } = getRewardConfig({ rewardConfigId: "lineaRewards" });

const rewards = await resolver({ publicClient });

Copy link

changeset-bot bot commented Jan 28, 2025

⚠️ No Changeset found

Latest commit: f6ea5d3

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

Copy link

vercel bot commented Jan 28, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
hyperdrive-mainnet-staging ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 28, 2025 6:00am
hyperdrive-sepolia-staging ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jan 28, 2025 6:00am
6 Skipped Deployments
Name Status Preview Comments Updated (UTC)
hyperdrive-js ⬜️ Ignored (Inspect) Jan 28, 2025 6:00am
hyperdrive-mainnet-production ⬜️ Ignored (Inspect) Jan 28, 2025 6:00am
hyperdrive-sepolia-production ⬜️ Ignored (Inspect) Jan 28, 2025 6:00am
testnet-v1 ⬜️ Ignored (Inspect) Jan 28, 2025 6:00am
testnet-v1.0.6 ⬜️ Ignored (Inspect) Jan 28, 2025 6:00am
trading-competition ⬜️ Ignored (Inspect) Jan 28, 2025 6:00am

@DannyDelott DannyDelott merged commit 9cd5ab0 into main Jan 28, 2025
15 checks passed
@DannyDelott DannyDelott deleted the danny-appconfig branch January 28, 2025 16:04
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