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

Liquidity being incorrectly mapped to volume in the Pairs API #335

Open
zmanian opened this issue Jan 29, 2025 · 1 comment
Open

Liquidity being incorrectly mapped to volume in the Pairs API #335

zmanian opened this issue Jan 29, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@zmanian
Copy link
Contributor

zmanian commented Jan 29, 2025

Here Liquidity is being incorrectly mapped to the volume variable.

      // TODO: should this be `direct_volume_over_window`?
      let volume = toValueView({
        amount: summary.liquidity,
        metadata: quoteAsset,
      });

https://github.com/penumbra-zone/dex-explorer/blob/main/src/shared/api/server/summary/pairs.ts#L55-L58

this manifest as the Selector widget showing liquidity but referring to it as volume.

I'm not clear if we want to fix the API or just change volume -> liquidity everywhere.

Thoughts?

@github-project-automation github-project-automation bot moved this to 🗄️ Backlog in Penumbra web Jan 29, 2025
@erwanor erwanor moved this from 🗄️ Backlog to 📝 Todo in Penumbra web Jan 29, 2025
@erwanor
Copy link
Member

erwanor commented Jan 29, 2025

Thanks for the helpful bug/experience report. I think we want to:

  • keep volume
  • replace liquidity with a notion of market depth at different intervals

So the actionable item for this bug report is to use the right input for the volume rendering.

@TalDerei TalDerei added the bug Something isn't working label Feb 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 📝 Todo
Development

No branches or pull requests

3 participants