Skip to content

Refac adataptor config #1823

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

Merged
merged 35 commits into from
Apr 22, 2025
Merged

Refac adataptor config #1823

merged 35 commits into from
Apr 22, 2025

Conversation

0x-minato
Copy link
Contributor

No description provided.

@llamatester
Copy link

Error while running strkfarm adapter:

Test Suites: 1 failed, 1 total
Tests: 1 failed, 15 passed, 16 total
Snapshots: 0 total
Time: 0.273 s
Ran all test suites.

Nb of pools: 2
 

Sample pools:
┌─────────┬───────────────────┬────────────┬────────────┬────────┬─────────────────────────────────────────────────────────────────────────┬───────────────────┬────────────────────┬──────────────────┬─────────────────────────────────────────────────────┬───────────────────┐
│ (index) │ pool              │ chain      │ project    │ symbol │ underlyingTokens                                                        │ tvlUsd            │ apyBase            │ apyReward        │ url                                                 │ poolMeta          │
├─────────┼───────────────────┼────────────┼────────────┼────────┼─────────────────────────────────────────────────────────────────────────┼───────────────────┼────────────────────┼──────────────────┼─────────────────────────────────────────────────────┼───────────────────┤
│ 0       │ 'vesu_fusion_eth' │ 'Starknet' │ 'strkfarm' │ 'ETH'  │ [ '0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7' ] │ 58869.67307722525 │ 4.292539484075173  │ 46.5842433820401 │ 'https://app.strkfarm.com/strategy/vesu_fusion_eth' │ 'Vesu Fusion ETH' │
│ 1       │ 'xstrk_sensei'    │ 'Starknet' │ 'strkfarm' │ 'STRK' │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ] │ 48092.5598579972  │ 26.373762670465645 │ 0                │ 'https://app.strkfarm.com/strategy/xstrk_sensei'    │ 'xSTRK Sensei'    │
└─────────┴───────────────────┴────────────┴────────────┴────────┴─────────────────────────────────────────────────────────────────────────┴───────────────────┴────────────────────┴──────────────────┴─────────────────────────────────────────────────────┴───────────────────┘
}

@slasher125
Copy link
Collaborator

@0x-minato

  • u need to add rewardTokens array, see the test output
  • pls remove this:
apy().then((strategies) => {
  strategies.forEach((strategy) => {
    console.log(strategy);
    console.log('-----------------------------');
  });
}).catch((error) => {
  console.error('Error fetching strategies:', error);
});

@llamatester
Copy link

Error while running strkfarm adapter:

Test Suites: 1 failed, 1 total
Tests: 1 failed, 15 passed, 16 total
Snapshots: 0 total
Time: 0.28 s
Ran all test suites.

Nb of pools: 2
 

Sample pools:
┌─────────┬───────────────────┬────────────┬────────────┬────────┬─────────────────────────────────────────────────────────────────────────┬───────────────────┬────────────────────┬───────────────────┬─────────────────────────────────────────────────────┬───────────────────┐
│ (index) │ pool              │ chain      │ project    │ symbol │ underlyingTokens                                                        │ tvlUsd            │ apyBase            │ apyReward         │ url                                                 │ poolMeta          │
├─────────┼───────────────────┼────────────┼────────────┼────────┼─────────────────────────────────────────────────────────────────────────┼───────────────────┼────────────────────┼───────────────────┼─────────────────────────────────────────────────────┼───────────────────┤
│ 0       │ 'xstrk_sensei'    │ 'Starknet' │ 'strkfarm' │ 'STRK' │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ] │ 52222.05934340364 │ 28.036466005769967 │ 0                 │ 'https://app.strkfarm.com/strategy/xstrk_sensei'    │ 'xSTRK Sensei'    │
│ 1       │ 'vesu_fusion_eth' │ 'Starknet' │ 'strkfarm' │ 'ETH'  │ [ '0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7' ] │ 41506.97576373345 │ 4.733441243782242  │ 67.69047528678676 │ 'https://app.strkfarm.com/strategy/vesu_fusion_eth' │ 'Vesu Fusion ETH' │
└─────────┴───────────────────┴────────────┴────────────┴────────┴─────────────────────────────────────────────────────────────────────────┴───────────────────┴────────────────────┴───────────────────┴─────────────────────────────────────────────────────┴───────────────────┘
}

@llamatester
Copy link

The strkfarm adapter exports pools:

Test Suites: 1 passed, 1 total
Tests: 46 passed, 46 total
Snapshots: 0 total
Time: 0.282 s
Ran all test suites.

Nb of pools: 6
 

Sample pools:
┌─────────┬──────────────────────┬────────────┬────────────┬──────────────┬──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┬────────────────────┬────────────────────┬───────────────────┬──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┬────────────────────────────────────────────────────────┬────────────────────┐
│ (index) │ pool                 │ chain      │ project    │ symbol       │ underlyingTokens                                                                                                                             │ tvlUsd             │ apyBase            │ apyReward         │ rewardTokens                                                                                                                                 │ url                                                    │ poolMeta           │
├─────────┼──────────────────────┼────────────┼────────────┼──────────────┼──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────┼────────────────────┼───────────────────┼──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┼────────────────────────────────────────────────────────┼────────────────────┤
│ 0       │ 'xstrk_sensei'       │ 'Starknet' │ 'strkfarm' │ 'STRK'       │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ]                                                                      │ 52222.05934340364  │ 28.036466005769967 │ 0                 │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ]                                                                      │ 'https://app.strkfarm.com/strategy/xstrk_sensei'       │ 'xSTRK Sensei'     │
│ 1       │ 'vesu_fusion_eth'    │ 'Starknet' │ 'strkfarm' │ 'ETH'        │ [ '0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7' ]                                                                      │ 41506.97576373345  │ 4.733441243782242  │ 67.69047528678676 │ [ '0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7' ]                                                                      │ 'https://app.strkfarm.com/strategy/vesu_fusion_eth'    │ 'Vesu Fusion ETH'  │
│ 2       │ 'ekubo_cl_xstrkstrk' │ 'Starknet' │ 'strkfarm' │ 'xSTRK-STRK' │ [ '0x28d709c875c0ceac3dce7065bec5328186dc89fe254527084d1689910954b0a', '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ] │ 3119.7459457430155 │ 7.5142278091981165 │ 0                 │ [ '0x28d709c875c0ceac3dce7065bec5328186dc89fe254527084d1689910954b0a', '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ] │ 'https://app.strkfarm.com/strategy/ekubo_cl_xstrkstrk' │ 'Ekubo xSTRK/STRK' │
│ 3       │ 'vesu_fusion_usdc'   │ 'Starknet' │ 'strkfarm' │ 'USDC'       │ [ '0x53c91253bc9682c04929ca02ed00b3e423f6710d2ee7e0d5ebb06f3ecf368a8' ]                                                                      │ 2049.24022523004   │ 5.64571211008005   │ 0                 │ [ '0x53c91253bc9682c04929ca02ed00b3e423f6710d2ee7e0d5ebb06f3ecf368a8' ]                                                                      │ 'https://app.strkfarm.com/strategy/vesu_fusion_usdc'   │ 'Vesu Fusion USDC' │
│ 4       │ 'vesu_fusion_strk'   │ 'Starknet' │ 'strkfarm' │ 'STRK'       │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ]                                                                      │ 413.94558541087997 │ 8.925317047920068  │ 0                 │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ]                                                                      │ 'https://app.strkfarm.com/strategy/vesu_fusion_strk'   │ 'Vesu Fusion STRK' │
│ 5       │ 'vesu_fusion_usdt'   │ 'Starknet' │ 'strkfarm' │ 'USDT'       │ [ '0x68f5c6a61780768455de69077e07e89787839bf8166decfbf92b645209c0fb8' ]                                                                      │ 3.040006           │ 3.8415600000000008 │ 0                 │ [ '0x68f5c6a61780768455de69077e07e89787839bf8166decfbf92b645209c0fb8' ]                                                                      │ 'https://app.strkfarm.com/strategy/vesu_fusion_usdt'   │ 'Vesu Fusion USDT' │
└─────────┴──────────────────────┴────────────┴────────────┴──────────────┴──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┴────────────────────┴────────────────────┴───────────────────┴──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┴────────────────────────────────────────────────────────┴────────────────────┘
This adapter contains some pools with <10k TVL, these pools won't be shown in DefiLlama

@0x-minato
Copy link
Contributor Author

0x-minato commented Apr 21, 2025

@0x-minato

  • u need to add rewardTokens array, see the test output
  • pls remove this:
apy().then((strategies) => {
  strategies.forEach((strategy) => {
    console.log(strategy);
    console.log('-----------------------------');
  });
}).catch((error) => {
  console.error('Error fetching strategies:', error);
});

hi...fixed these issues..

@llamatester
Copy link

The strkfarm adapter exports pools:

Test Suites: 1 passed, 1 total
Tests: 18 passed, 18 total
Snapshots: 0 total
Time: 0.263 s
Ran all test suites.

Nb of pools: 2
 

Sample pools:
┌─────────┬───────────────────┬────────────┬────────────┬────────┬─────────────────────────────────────────────────────────────────────────┬───────────────────┬────────────────────┬───────────────────┬─────────────────────────────────────────────────────────────────────────┬─────────────────────────────────────────────────────┬───────────────────┐
│ (index) │ pool              │ chain      │ project    │ symbol │ underlyingTokens                                                        │ tvlUsd            │ apyBase            │ apyReward         │ rewardTokens                                                            │ url                                                 │ poolMeta          │
├─────────┼───────────────────┼────────────┼────────────┼────────┼─────────────────────────────────────────────────────────────────────────┼───────────────────┼────────────────────┼───────────────────┼─────────────────────────────────────────────────────────────────────────┼─────────────────────────────────────────────────────┼───────────────────┤
│ 0       │ 'xstrk_sensei'    │ 'Starknet' │ 'strkfarm' │ 'STRK' │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ] │ 52222.05934340364 │ 28.036466005769967 │ 0                 │ [ '0x4718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d' ] │ 'https://app.strkfarm.com/strategy/xstrk_sensei'    │ 'xSTRK Sensei'    │
│ 1       │ 'vesu_fusion_eth' │ 'Starknet' │ 'strkfarm' │ 'ETH'  │ [ '0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7' ] │ 41506.97576373345 │ 4.733441243782242  │ 67.69047528678676 │ [ '0x49d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7' ] │ 'https://app.strkfarm.com/strategy/vesu_fusion_eth' │ 'Vesu Fusion ETH' │
└─────────┴───────────────────┴────────────┴────────────┴────────┴─────────────────────────────────────────────────────────────────────────┴───────────────────┴────────────────────┴───────────────────┴─────────────────────────────────────────────────────────────────────────┴─────────────────────────────────────────────────────┴───────────────────┘

@slasher125 slasher125 merged commit 6d22006 into DefiLlama:master Apr 22, 2025
1 check passed
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.

3 participants