-
Notifications
You must be signed in to change notification settings - Fork 1k
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
feat(dopex): holder and supply side revenue #1277
base: master
Are you sure you want to change the base?
Conversation
The dopex adapter exports:
|
The dopex adapter exports:
|
options/dopex/clamm.ts
Outdated
@@ -74,23 +77,23 @@ async function getChainStats({ graphUrl, timestamp }: IGetChainStatsParams) { | |||
(acc, market) => { | |||
return { | |||
dailyNotionalVolume: acc.dailyNotionalVolume + Number(market.volume), | |||
dailyPremiumVolume: acc.dailyPremiumVolume + Number(market.premium), | |||
dailyFees: acc.dailyFees + Number(market.premium), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for options we can't include premium on fees
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh okay! Can you suggest how can we show premiums as premiums and not as premium volume (which is only visible on a graph). premiums should be shown in the side bars as well along with fees, revenue etc.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, 24h revenue should show as premiums 24h. anyways I've updated the code to show only revenue and not fees since they're the same data :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no fees is only add on fees when user buy option premium is not fees
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, 24h revenue should show as premiums 24h. anyways I've updated the code to show only revenue and not fees since they're the same data :)
if you need update fees/rev plz set at field dailyFees
, dailyRevenue
now current adapter set fees = rev then show fees = rev premiums is show only options page
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If that's the case, no change has to be made and this PR can be closed. Our only concern is premiums not showing in main options page or anywhere except in just the bar graph as premium volume which as you mentioned will be fixed :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes will take look why option is show daily rev instead daily premium
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey! updated the PR to just show more stats as per teams feedback :) please review
The dopex adapter exports:
|
The dopex adapter exports:
|
@@ -88,9 +92,11 @@ async function getChainStats({ graphUrl, timestamp }: IGetChainStatsParams) { | |||
return { | |||
timestamp, | |||
...cumulative, | |||
totalFees: cumulative.totalRevenue, | |||
...daily, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fees is require dailyFees
we can't list without dailyFees
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The first thing that came up |
Current implementation shows same data for daily revenue and daily fees this PR fixes that
current:
with fix: